Page 1 of 1

[0.15] Waypoint stations

Posted: Sun Sep 24, 2017 7:26 pm
by aaargha
Info Adds a special kind of train stops that unlock with the Automated rail transportation research. These train stops are meant to be used to guide train paths without forcing trains to stop.

Please note that they do not force trains to travel through them, it is enough for the train to start braking for the stop to send it on to the next destination. This means that it cannot be used to micro-manage train paths, but it will still work well over longer distances. Behaviour might be improved in 0.16.

Basically we listen to on_train_changed_state for the arrive_station state, if the destination is a waypoint -> go to the next destination.

Should also be usable in earlier versions of Factorio by changing info.json.

Feedback, suggestions and bug reports welcome.

Re: [0.15] Waypoint stations

Posted: Thu Oct 05, 2017 2:51 am
by quyxkh
Heh. I was going to write this but then I saw a train blow through a stop it had been scheduled for and realized you can get waypoints in vanilla Factorio, put a signal just beyond braking distance and disable the stop on Red=1. This has _so_ many potential uses.

Re: [0.15] Waypoint stations

Posted: Thu Oct 05, 2017 9:14 am
by aaargha
quyxkh wrote:Heh. I was going to write this but then I saw a train blow through a stop it had been scheduled for and realized you can get waypoints in vanilla Factorio, put a signal just beyond braking distance and disable the stop on Red=1. This has _so_ many potential uses.
That is a good alternative, and can allow for finer path control as the player can decide when the train should switch to the next station. There are however a few drawbacks to that approach and some situations where it does not really work:
  • Trains are likely to slow down as they start braking for stations way earlier than for signals. It's usually not a problem but there may be some cases where you can't fit the sensor signal where you want to.
  • It likely won't work well for multiple trains using the same waypoint: a train reaching the waypoint will also make all other trains heading to is switch destination.
  • It can be triggered by other trains: you need to make sure that other trains won't use this stretch of track as that can disable the station. This can sometimes be worked around by putting the station and sensor signal on its own branch but that will get pretty messy for multi-lane systems.
  • You can't have two waypoints with the same name: trains will go to the other waypoint once the first one disables.
That said, for many cases the vanilla setup will work just fine.

I agree that controlling train stops with signals has a lot of potential for interesting builds. The best I've seen so far is the "instant stop train station" that reduces the braking distance for stations to just a few tiles, but I'm sure there are many more uses for this.