News:

Simutrans Wiki Manual
The official on-line manual for Simutrans. Read and contribute.

On-line game - Fatal error/game freezes upon using upgrate vehicle tool

Started by asaphxiix, December 26, 2012, 12:04:13 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

asaphxiix

previously I had upgraded all stage coaches to omnibuses, when I did it then the game froze for quite a bit but then recovered somehow - this time I had some 156 or 168 stage coaches left (most are probably in depot), and I hit replace all on one of them that was driving - and the game froze for a while, then I lost sync and the server restarted (no crash on my end). I should have saved at that point, but never mind that.

I can recreate using the server save - try to 'replace all' on one of these convoys and you'll see - I did it now on a convoy in a depot, and got.


I was thinking that autosave can just be turned on in the server, assuming that doesn't require any coding, this could answer an urgent need. It won't be so bad even if autosave happens 5 minutes after someone joined - since rejoining takes so little time.

jamespetts

Asaph,

thank you very much for that report. Since I am not a moderator in this forum, I have asked a moderator to split your post and put it up as new bug report; I am currently away from home for the Christmas holidays without easy access to my development environment. I have taken a copy of the current server saved game, and uploaded it here for reference. Can you remind me which company that you are playing so that I can test this properly?

Thank you very much for testing this, though - that is very helpful.
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.

asaphxiix

It's NLT.

This is not an urgent issue, I'll just replace less convoys at a time :)

jamespetts

Any bug that leads to a crash is urgent to some extent, because there is always a risk that somebody will accidentally trigger it.
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.

ӔO

I think I've seen what causes it.

Occasionally, when after replacing, the rescheduled vehicle does not get a proper schedule and instead gets something like a few hundred stops repeating itself.

Try this save game: http://dl.dropbox.com/u/17111233/autosave01.sve

play as aeolus and for ships, do a 'replace all' with clyde steamer.
It seems to happen with iron paddles and great westerns. When doing great easterns, it will seem like the game froze, but it will run again.

What should show is a ship that enters a depot, but will not start when you tell it to, because it has an improper schedule.

seems to be pretty difficult to reproduce so it may need a few runs.
it might be quicker to reproduce by replacing everyone's ships with clyde steamers

---

by some miracle, this save game reproduces it perfectly
http://dl.dropbox.com/u/17111233/client3-network.sve
My Sketchup open project sources
various projects rolled up: http://dl.dropbox.com/u/17111233/Roll_up.rar

Colour safe chart:

jamespetts

Excellent, thank you for that. I shall look into this when I get home and have access to the code. Thank you!
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.

jamespetts

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.

ӔO

It should be in the ship depot at beaington

take a look at the schedule of the ship.
My Sketchup open project sources
various projects rolled up: http://dl.dropbox.com/u/17111233/Roll_up.rar

Colour safe chart:

jamespetts

Quote from: asaphxiix on December 26, 2012, 12:04:13 PM
previously I had upgraded all stage coaches to omnibuses, when I did it then the game froze for quite a bit but then recovered somehow - this time I had some 156 or 168 stage coaches left (most are probably in depot), and I hit replace all on one of them that was driving - and the game froze for a while, then I lost sync and the server restarted (no crash on my end). I should have saved at that point, but never mind that.

I can recreate using the server save - try to 'replace all' on one of these convoys and you'll see - I did it now on a convoy in a depot, and got.

Hmm - I am trying to reproduce this, so far without success. May I ask - is there a specific line in a specific saved game on which this occurs reliably? I tried to replace all of your clippers on the Nutish to Coatsand route with Clyde steamers, and, after a long period of unresponsiveness whilst it tried to find routes to the depot for all those ships, it continued to work.

AEO - this seems to be a separate issue. When a depot is within the coverage area of a dock, the schedule regards the command to go to the depot as a command to go to that dock instead, because any water tile within the coverage radius of a dock is treated as part of the dock. Because of this, the destination is not recognised as a depot; it is therefore not deleted from the list when the ship enters the depot, and, it seems in consequence, the ship does not leave the depot. The only way that I have been able to reproduce multiple instances of the depot/harbour in the schedule is issuing multiple replace commands - because the depot is not recognised as such, the convoy does not realise that it is going to a depot, and so another instance of the depot (recognised as the harbour) is inserted into the timetable. This does not appear to be connected with crashes in any way, but will need looking into separately.

Edit:

QuoteI can recreate using the server save - try to 'replace all' on one of these convoys and you'll see - I did it now on a convoy in a depot, and got.

May I ask - how were you able to open the replace dialogue of a convoy in a depot? This ought not be possible, and is not in fact possible according to my tests.

Edit 2: I have fixed on my 10.x branch a discrete bug relating to replacing, where the replacing would not complete (vehicles would remain in the depot) when some of the target vehicles were in the depot. This did not cause a crash in my tests, just incorrect behaviour, but there is a possibility that the two are related.

Edit 3: I have produced a fix for the ship depot issue by ensuring that all depot entries are deleted from the schedule when the convoy enters the depot, rather than just one such entry on the 10.x branch.

Edit 4: this looks interesting - this might significantly improve performance for ship routing.
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.