[2.0.13] Crash when train enters shunting station... (AutomatedTrainController::getPathTarget)
Posted: Fri Nov 01, 2024 8:41 am
"Crash when train enters shunting station after fuel runs low between stations"
I got stuck for a bit with a repeating crash in my save and I think I found what was causing it. It kept crashing when a copper ore train entered my shunting station, which uses an interrupt, after also hitting the threshold for its fuel interrupt on the way. Both interrupts use the "interrupt other interrupts" to work correctly, but they had been working in tandem for some time.
With no interaction, the attached game save (swap.zip) crashes after about 60 seconds, right as the copper ore train enters the shunting station. I can delay the crash if I delay the train by slowing the ore loading, and it crashes at the same place on the track each time.
Fortunately I'm not stuck, I can stop the crash if I walk over and add a bit of fuel to the train by hand, or manually activate the fuel interrupt at any point before the crash. Perhaps this de-syncs whatever unfortunate timing is causing the bug?
Either way the crash seems have something to do with the timing of the fuel running below the interrupt threshold between stations, though there may be another factor that I can't pinpoint; I certainly thought the interrupt list order would set a hierarchy to solve exactly such conflicts of interrupting interrupts, ah, interrupting each other.
Something else of note: the crash happens the moment the train enters a big block with 23 rail signal exits, not as it gets to the station itself on the other side of the signal. Also I apologize for the lack of radar coverage, I was in the middle of moving my radar grid.
The relevant bits:
I got stuck for a bit with a repeating crash in my save and I think I found what was causing it. It kept crashing when a copper ore train entered my shunting station, which uses an interrupt, after also hitting the threshold for its fuel interrupt on the way. Both interrupts use the "interrupt other interrupts" to work correctly, but they had been working in tandem for some time.
With no interaction, the attached game save (swap.zip) crashes after about 60 seconds, right as the copper ore train enters the shunting station. I can delay the crash if I delay the train by slowing the ore loading, and it crashes at the same place on the track each time.
Fortunately I'm not stuck, I can stop the crash if I walk over and add a bit of fuel to the train by hand, or manually activate the fuel interrupt at any point before the crash. Perhaps this de-syncs whatever unfortunate timing is causing the bug?
Either way the crash seems have something to do with the timing of the fuel running below the interrupt threshold between stations, though there may be another factor that I can't pinpoint; I certainly thought the interrupt list order would set a hierarchy to solve exactly such conflicts of interrupting interrupts, ah, interrupting each other.
Something else of note: the crash happens the moment the train enters a big block with 23 rail signal exits, not as it gets to the station itself on the other side of the signal. Also I apologize for the lack of radar coverage, I was in the middle of moving my radar grid.
The relevant bits: