Page 1 of 1

[0.17.21] Crash on loading - WaitCondition.cpp:200: Unknown enum value: 208

Posted: Thu Mar 28, 2019 10:37 pm
by internetuser
While playing on the latest experimental patch (with no mods), the server stopped responding and dropped everyone from the game. When restarting the server it would appear to start normally but would crash with the same message as soon as someone tried to connect. Reinstalling the server and putting the back up save on it resulted in the same crash. The save will load with no issues in single player if you start the game and try to load it without doing anything else first, but in the process of troubleshooting I managed to reproduce the crash in local single player by attempting to connect to the headless server, being dropped immediately after loading as the server crashes, and then trying to load the same backup save in single player without restarting the game. When doing this both the server and single player logs mention something about trains.


Server and single player logs are attached to this post. Save file can be found here because it is over 40 megabytes:
https://drive.google.com/file/d/1pyocgF ... sp=sharing

Re: [0.17.21] Crash on loading - WaitCondition.cpp:200: Unknown enum value: 208

Posted: Sat Mar 30, 2019 6:42 pm
by internetuser
If anyone else is having this issue we've managed to salvage our save by loading it in the method described above to load it without crashing and "massaging" the trains. I cycled all trains through their order lists manually by clicking the play buttons on them and letting them drive around to their orders. I also deleted all temporary orders that I came across. There was one temporary order labeled "Temporary: Invalid" which I suspect may have something to do with the crash. After doing this, the game was saved and this save was uploaded to the headless server and appears to function normally even after several hours of playing. This "fix" was done on the latest version (0.17.23), but I suspect that the version change has nothing to do with the "fix" because the original back up save still crashes if you follow the methods above to replicate the crash.

Re: [0.17.21] Crash on loading - WaitCondition.cpp:200: Unknown enum value: 208

Posted: Mon Apr 01, 2019 11:26 am
by Rseding91
Thanks for the report. One of the trains in your save has an invalid schedule index. It's trying to use item 2 in the trains schedule and the schedule only has 1 item. I don't know how it got into that state but it's invalid and causes the crash you're seeing. I've added an extra check for the next version of 0.17 that will tell how it's happening (if it's still happening) and fix any broken trains on loading older maps.