The International Simutrans Forum

 

Author Topic: The departure board ignores certain convoys  (Read 116 times)

0 Members and 1 Guest are viewing this topic.

Online Ranran

  • Devotee
  • *
  • Posts: 1514
  • Languages: ja
The departure board ignores certain convoys
« on: June 19, 2021, 08:52:01 PM »
The departure board is broken and keeps ignoring certain convoys.  ::-\

Confirmation procedure:

(1) Open the demo.sve
(2) Open the halt info dialog of Christminster Central railway station to check the departure board.
(3) Check Line "Train Commuter Christminster".
  Two convoys (43) and (97)  LNER Tyneside EMU belong to it that departs and arrives at Christminster Central railway station.
  However, they are never displayed on the departure board and are ignored.

Watch those convoys. When they approach the station, it must be at the top of the arrival list.
And when they arrive at the station, it must be at the top of the departure list.
Therefore we cannot trust the departure board... (´・ω・`)

Online Ranran

  • Devotee
  • *
  • Posts: 1514
  • Languages: ja
Re: The departure board ignores certain convoys
« Reply #1 on: June 21, 2021, 01:05:11 PM »
I have identified the cause.
Code: [Select]
const uint32 max_listings = 12;
uint32 listing_count = 0;

FOR(arrival_times_map, const& iter, arrival_times)
{
if(listing_count++ > max_listings)
{
break;
}
If the number of convoys exceeds max_listings, the 13th and subsequent convoys will be ignored regardless of arrival or departure order to exit the search loop.
This seems to be a bug that has been around for 7 years.
I have now resumed work on halt_info to support the auto-aligned GUI, and I plan to fix this in that work.

Offline freddyhayward

  • Devotee
  • *
  • Posts: 661
  • Languages: EN
Re: The departure board ignores certain convoys
« Reply #2 on: June 21, 2021, 03:06:19 PM »
Is there any reason for max_listings to be so low?