News: Portal
Our Simutrans site. You can find everything about Simutrans from here.

Ship changes line on its own

Started by zook2, August 30, 2021, 08:55:38 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.


A weird one (and reproducible):
on the BB server, go to the dock at 217,600 (password: pw). Buy a boat, set the line to "#- Welsh Potatoes". It shows up in the line list in the white font. Launch it. A second later it disappears from the potato line and is now in "#- Welsh Bulk & Goods".


Confirmed now. If I have two lines with identical stops (e.g. one freight line and one cargo), the game often auto-assigns a new convoy to the other line (perhaps based on some kind of internal line ID?) and not the one I selected in the depot. A second after leaving the depot my "Foo - Bar Express" passenger train slips into "Foo - Bar Cargo Express". After manually reassigning it, everything's OK.


I'm not sure if this is a bug or a feature...
What's going on is that that the line comparator method used to compare schedules is used to select a line with the same schedule.
If they match, the first matching line will be assigned.


It seems that this can be worked around relatively easily using waypoints. But it's undocumented and confusing, especially for new players.
(Signature being tested) If you enjoy playing Simutrans, then you might also enjoy watching Japan Railway Journal
Available in English and simplified Chinese


Definitely. This is confusing and should be fixed.

I am not exactly sure about the intention of this code.
This behavior seems to be meant to re-assign the original line of a convoy when it's leaving the depot as the line is unassigned when a convoy enters the depot.
This method (schedule_t::matches) is based on more than just the waypoints. It does also account for the schedule options.

I am wondering if instead of this admittedly confusing re-assignment mechanism, convoys should instead "simply"* not un-assign their line when entering a depot.
The same can be observed in further cases, e.g. when changing the schedule of a convoy outside of the depot.

*I did not yet check how simple this actually is.


I am trawling through past bug reports. Because we may find something new or have a chance to solve the bug. (´・ω・`)
I recently noticed that there is such a specification in the standard. It seems that it is not possible to make each convoy belong to multiple lines with duplicate schedules. It is aggregated on one side.
I don't know if it was brought to extended by the merge, or if it is an original specification.
(´・ω・`)シミュトランスのアップデート履歴(日本語) (※更新停止中)


I believe that this is a long established original feature dating from before Extended was forked from Standard.
Download Simutrans-Extended.

Want to help with development? See here for things to do for coding, and here for information on how to make graphics/objects.

Follow Simutrans-Extended on Facebook.