News:

Simutrans Chat Room
Where cool people of Simutrans can meet up.

Possible bug in depot

Started by Zeno, May 27, 2013, 07:17:32 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Zeno

Not sure if it's still there, as I found this while playing yesterday with RC 9.0001, maybe it doesn't apply to newest (9.0006) candidate.
An airplane got stuck in a grass taxiway, because was one of the first jets and was too heavy for my old outdated grass airport (67t for a limit of 50t).
So I started making some enhancements to the airport, upgrading it to tarmac version. But, in the middle of the enhancement works, the airplane was automatically sent to its home depot.

Here it came the possible bug. I just hit the "start" button to send the plane out, as the enhancement works were almost finished. Well, the airplane went out of the depot, but was still shown in the depot. Same name, id, etc. I saved game, reloaded, and nothing in the depot. I didn't try to press the "start" again to see what happened, sorry.

jamespetts

Thank you for the report. Can you test to see whether you can reproduce this in the latest version? The teleporting is intentional to prevent blockages in multi-player games, but the subsequent behaviour that you describe is not.
Download Simutrans-Extended.

Want to help with development? See here for things to do for coding, and here for information on how to make graphics/objects.

Follow Simutrans-Extended on Facebook.

Zeno

Well, James... actually I can't check it out, because... a 252 t Airbus A380 is able to land and drive through a grass airport, even though it should be restricted to maximum of 50 t.

I tried also with a Boeing 707-120 (56 t) and I got an orange tooltip over the plane telling "too heavy", and landed with a heavy speed penalty. I still wonder why that didn't happen with the big guy. So, not sure if we got one problem or two! :D

neroden

Oh!  I've had this (first) problem happen.  With buses. Caused some crashes too.  I haven't been able to track it down well enough to figure out exactly what's going on, because it's always caused by me doing something stupid, so I always reload.   ;)

You can reproduce this "depot screwup bug" by (a) getting a train or truck stuck somehow, so that it cannot follow its schedule AND cannot drive back to the depot (perhaps by deleting a crucial piece of roadway or replacing it with something with a very low weight limit), (b) having it teleport to the depot after being stuck for too long, and (c) attempting to start it again out of the depot.

This looks to me like a memory management problem (which also explains the crashes).

So.... Where is the "I can't find a path, I'm teleporting to the depot" code?  Because that's what seems to be triggering this problem.

The second bug appears to be a different one, and I don't know about that.   :)

Zeno

Just let me add I didn't get any crash; I did save/load and the 'clone' just vanished from depot.
About the second, I'm not using any exp pakset, but pak128 standard instead. Not sure if that could lead to unwanted behaviors. Also, I've seen some vehicles with weight = X and weight/axle =X but also others with weight = X and weight/axle = 0. The difference between them might be makeobj version, but they had exactly same dat file, I'm quite sure. Not sure if that can bring some errors too.

Junna

Like Neroden I have had this bug occur with crashes, as well. Also note that any bus and train going out of said depot with this strange behaviour will be running at seemingly twice the speed, and will go around for a while until the game crashes; it can work, however, if you are able to save and reload after crashing. Then the odd behaviours are no longer present.

sdog

Quote from: neroden on May 29, 2013, 01:18:11 AM

You can reproduce this "depot screwup bug" by (a) getting a train or truck stuck somehow, so that it cannot follow its schedule AND cannot drive back to the depot (perhaps by deleting a crucial piece of roadway or replacing it with something with a very low weight limit), (b) having it teleport to the depot after being stuck for too long, and (c) attempting to start it again out of the depot.


there might be an old backtrace of this bug around, i've encountered it one or two years ago.

Might be related to pax/cargo still being assigned to it, unlike regular vehicles who are always emptied when entering a depot.

neroden

I have a proposed set of fixes for this on my emergency-depot-bugfix branch.  There were a lot of little things to clean up here.  I'd appreciate some testing.

jamespetts

Thank you for that - will test when I get home.
Download Simutrans-Extended.

Want to help with development? See here for things to do for coding, and here for information on how to make graphics/objects.

Follow Simutrans-Extended on Facebook.