The International Simutrans Forum

 

Author Topic: [BUG] one_train_staff triggering twice on stations  (Read 257 times)

0 Members and 1 Guest are viewing this topic.

Offline Freahk

  • Devotee
  • *
  • Posts: 1423
  • Languages: DE, EN
[BUG] one_train_staff triggering twice on stations
« on: January 18, 2020, 07:51:23 PM »
What happened?
When the exit of a one_train_staff block is at a platform, the cabinet will be triggered twice.

How to reproduce?
1. Load the reproduction save, I have already set up both cases using absolute block there, but it works exactly the same with at least tcb.
2. Observe the trains

Observations (first case):
- The train enter one_train_staff at the cabinet, when it departs the platform.
- The train will properly move towards the dead-end, reverse and move towards the first platform in the loop.
- The train will switch to drive_by_sight, as soon as entering the cabinet controlled tile, creating a reservation for the whole next block
- At departure, the train will switch to one_train_staff working method again.

I would not expect the train creating the reservation when switching to drive_by_sight nor would I expect it to trigger the cabinet on departure in this case.
« Last Edit: January 20, 2020, 09:50:51 PM by Freahk »

Offline jamespetts

  • Simutrans-Extended project coordinator
  • Administrator
  • *
  • Posts: 20700
  • Cake baker
    • Bridgewater-Brunel
  • Languages: EN
Re: [BUG] one_train_staff triggering twice on stations
« Reply #1 on: January 18, 2020, 08:33:57 PM »
This is a very singular reproduction case: it will only work where there is a station of exactly one tile in length exactly on the exit point of a one train staff section. This is quite difficult to solve, as many state data are lost when a train stops at a station, so it is very difficult in this case for the train to detect whether it is entering or exiting a one train staff section.

Offline Freahk

  • Devotee
  • *
  • Posts: 1423
  • Languages: DE, EN
Re: [BUG] one_train_staff triggering twice on stations
« Reply #2 on: January 18, 2020, 09:05:46 PM »
Might be not that singular. See the attached save.

What about considering the staffs direction? In drive direction it will pickup, in the other it will return. That's how most ppl on stephenson-siemens use it.

Offline jamespetts

  • Simutrans-Extended project coordinator
  • Administrator
  • *
  • Posts: 20700
  • Cake baker
    • Bridgewater-Brunel
  • Languages: EN
Re: [BUG] one_train_staff triggering twice on stations
« Reply #3 on: January 18, 2020, 09:25:24 PM »
Might be not that singular. See the attached save.

What about considering the staffs direction? In drive direction it will pickup, in the other it will return. That's how most ppl on stephenson-siemens use it.

I wonderd about the direction - but the trouble is this: players would generally expect a signal/sign/cabinet to interact with a train only if it is facing in the direction in which the train is travelling. In this case, it would be facing forwards both for picking up and setting down. Expecting players to know that they should place the cabinet backwards is so subtle as to be almost impossible for anyone to understand without having been explicitly told, and even then it is likely to be hard to remember.

Offline Freahk

  • Devotee
  • *
  • Posts: 1423
  • Languages: DE, EN
Re: [BUG] one_train_staff triggering twice on stations
« Reply #4 on: January 18, 2020, 11:25:08 PM »
In that case maybe an adjacent end of signaling sign or any signal should be the way to leave one train staff?
I could not find much about it in the web but I would not expect there had beeen a pickup cab and a seperate return cab was there?

Given this assumption, automatically returning the token once the train entered a tile adjacent to it would be the preferred way to go, but I fear that would be a near rewrite of one train staff, so what about the end of signalling sign?

Offline jamespetts

  • Simutrans-Extended project coordinator
  • Administrator
  • *
  • Posts: 20700
  • Cake baker
    • Bridgewater-Brunel
  • Languages: EN
Re: [BUG] one_train_staff triggering twice on stations
« Reply #5 on: January 18, 2020, 11:40:30 PM »
Any change of this sort would require a very major rewrite.