[kovarex] [for 0.16] [0.15.32] Trains creep forward when swapping destination

This subforum contains all the issues which we already resolved.
Post Reply
aaargha
Filter Inserter
Filter Inserter
Posts: 330
Joined: Wed Dec 07, 2016 8:35 am
Contact:

[kovarex] [for 0.16] [0.15.32] Trains creep forward when swapping destination

Post by aaargha »

It seems like each time a train waiting at a red signal changes destination station, due to the station getting disabled, it creeps forward a pixel or so. If that happens enough times the train can creep past the red signal.

I've attached a pretty extreme example where the trains swap station every tick as a demonstration, just turn off the constant combinator to get it running.

Apologies if this is a duplicate, I think I've seen something like this, but I can't find that post.
Attachments
Signal creep bug.zip
(2.05 MiB) Downloaded 35 times

Loewchen
Global Moderator
Global Moderator
Posts: 8317
Joined: Wed Jan 07, 2015 5:53 pm
Contact:

Re: [0.15.32] Trains creep forward when swapping destination

Post by Loewchen »

According to: 47911, 46473, the creeping is supposed to be fixed.

aaargha
Filter Inserter
Filter Inserter
Posts: 330
Joined: Wed Dec 07, 2016 8:35 am
Contact:

Re: [0.15.32] Trains creep forward when swapping destination

Post by aaargha »

Those bugs describe slightly different situations, namely when there is no valid station/the same station appears twice in the schedule. What I'm doing here is swapping which of two identically named stations is enabled which apparently forces the same behaviour. It seems like the previous fixes removed the some other ways that the trains could get into this rapid switching mode but perhaps not the creeping itself if it gets there?

Running creative mode and enabling event logging (attached a short log from some manual triggering) for on_train_changed_state shows that each time the train switches station it cycles through "defines.train_state.arrive_signal" and "defines.train_state.wait_signal", each arrive_signal it manages to pick up some speed before stopping.
Attachments
event-log.txt
(2.24 KiB) Downloaded 39 times

kovarex
Factorio Staff
Factorio Staff
Posts: 8078
Joined: Wed Feb 06, 2013 12:00 am
Contact:

Re: [kovarex] [for 0.16] [0.15.32] Trains creep forward when swapping destination

Post by kovarex »

I can confirm, that it is happening in 0.15, but not in the 0.16 where I cleaned up the train code.
This makes me even more confident, that the changes were for the better.

Post Reply

Return to “Resolved Problems and Bugs”