Page 1 of 1

[2.0] Routing trains to specific stops

Posted: Sun Nov 10, 2024 5:43 pm
by The_LORD_thy_GOD
Mods that generate train schedules often want to send trains to particular stations, even in the absence of unique station names. However, train schedules send trains by station name and can't target particular stations.

In 1.x, mods like LTN would work around this by adding the coordinates of a nearby rail to the schedule, then the station. This would ensure that the train was sent to the correct target station, even if not uniquely named.

With the addition of priority in 2.0, this method no longer works reliably, as if there is another station of the same name with higher priority, the train will be rerouted away from the target coordinates to the higher priority station.

I therefore suggest that an API change be made (perhaps a `stop` field in `ScheduleRecord`) that would allow a train to be routed via API to a particular stop unambiguously.

Re: [2.0] Routing trains to specific stations

Posted: Mon Nov 11, 2024 11:26 am
by curiosity
Duplicate of viewtopic.php?f=221&t=100216

And your thread title is bad. A station is the name. A stop is the entity in the world.

Re: [2.0] Routing trains to specific stops

Posted: Mon Nov 11, 2024 6:17 pm
by The_LORD_thy_GOD
Changed the title.

I don't think it's a duplicate, though. All of the information and developer responses in that thread are no longer valid due to the introduction of train priority. This is a new issue that was solvable in 1.1 but isn't in 2.0.

Re: [2.0] Routing trains to specific stations

Posted: Tue Nov 12, 2024 2:55 am
by Sharparam
curiosity wrote: Mon Nov 11, 2024 11:26 am And your thread title is bad. A station is the name. A stop is the entity in the world.
The API uses station both to refer to the entity and the name (in different places), so it's not very consistent.

Re: [2.0] Routing trains to specific stations

Posted: Tue Nov 12, 2024 8:53 am
by curiosity
Sharparam wrote: Tue Nov 12, 2024 2:55 am The API uses station both to refer to the entity and the name (in different places), so it's not very consistent.
The API is not known for its consistency.