The International Simutrans Forum

 

Author Topic: SPADs  (Read 6632 times)

0 Members and 1 Guest are viewing this topic.

Offline Moe Ron

  • *
  • Posts: 64
  • Languages: EN
SPADs
« on: September 01, 2013, 08:14:15 AM »
Just wondering, why do freight trains in 0.9.0 ignore signals, and rear-end other services ahead?

Offline jamespetts gb

  • Simutrans-Extended project coordinator
  • Moderator
  • *
  • Posts: 18745
  • Cake baker
    • Bridgewater-Brunel
  • Languages: EN
Re: SPADs
« Reply #1 on: September 01, 2013, 11:23:24 AM »
This appears to be a bug with the code, rather than a pakset issue. Can you see whether you can reproduce this problem in 11.9 (I notice that you are using 11. 8) , and, if you can, post a saved game in which the problem can be reproduced so that I can try to find and fix the bug? Thank you!
« Last Edit: September 26, 2013, 10:47:06 PM by jamespetts »

Offline Moe Ron

  • *
  • Posts: 64
  • Languages: EN
Re: SPADs
« Reply #2 on: September 01, 2013, 11:46:58 PM »


It seems like a recurring problem on my slow lines with freight trains.




This one just seems to be the issue that is supposedly patched where a convoy would reserve a random spot, or ignore a choose signals, and go directly to the platform.

Offline jamespetts gb

  • Simutrans-Extended project coordinator
  • Moderator
  • *
  • Posts: 18745
  • Cake baker
    • Bridgewater-Brunel
  • Languages: EN
Re: SPADs
« Reply #3 on: September 02, 2013, 12:19:49 AM »
Can you upload a saved game in which this can reliably be reproduced so that I can track it down and fix it?

Offline Junna

  • Devotee
  • *
  • Posts: 1082
Re: SPADs
« Reply #4 on: September 02, 2013, 12:30:21 AM »
Isn't this the good old reservation thing once again? Say, did you use way points for goods services?

Offline Moe Ron

  • *
  • Posts: 64
  • Languages: EN
Re: SPADs
« Reply #5 on: September 02, 2013, 12:49:30 AM »
Isn't this the good old reservation thing once again? Say, did you use way points for goods services?

I have to keep a service with a max of 96kph off fast lines w/ a max of 145.

Can you upload a saved game in which this can reliably be reproduced so that I can track it down and fix it?

I'll try to do so ASAP.

Offline Moe Ron

  • *
  • Posts: 64
  • Languages: EN
Re: SPADs
« Reply #6 on: September 02, 2013, 02:23:54 AM »
On a somewhat related note, I'm wondering; is there a way to figuratively turn a locomotive around, allowing it to pass through signals?

Offline jamespetts gb

  • Simutrans-Extended project coordinator
  • Moderator
  • *
  • Posts: 18745
  • Cake baker
    • Bridgewater-Brunel
  • Languages: EN
Re: SPADs
« Reply #7 on: September 02, 2013, 09:54:01 AM »
On a somewhat related note, I'm wondering; is there a way to figuratively turn a locomotive around, allowing it to pass through signals?

I am not sure that I understand the question, I am afraid...

Offline ӔO

  • Devotees (Inactive)
  • *
  • Posts: 2345
  • Hopefully helpful
  • Languages: en, jp
Re: SPADs
« Reply #8 on: September 02, 2013, 12:59:51 PM »
I find that longer and slower convoys are more susceptible to this problem.

Offline jamespetts gb

  • Simutrans-Extended project coordinator
  • Moderator
  • *
  • Posts: 18745
  • Cake baker
    • Bridgewater-Brunel
  • Languages: EN
Re: SPADs
« Reply #9 on: September 02, 2013, 01:15:36 PM »
AEO, if you have seen the problem and can reproduce it in a saved game, I should be grateful if you could upload it.

Offline ӔO

  • Devotees (Inactive)
  • *
  • Posts: 2345
  • Hopefully helpful
  • Languages: en, jp
Re: SPADs
« Reply #10 on: September 02, 2013, 01:58:12 PM »
I tried to reproduce the reservation bug, but I think it requires a more complex network, perhaps very long lines?, to reproduce.

In the mean time, I've managed to reproduce two other bugs.
1. scheduling allocates the same departure time
2. vehicles going through a choose signal will slow down to 4km/h for 2 to 3 tiles, before vehicle will speed up.

https://dl.dropboxusercontent.com/u/17111233/schedule_bug.sve

Offline jamespetts gb

  • Simutrans-Extended project coordinator
  • Moderator
  • *
  • Posts: 18745
  • Cake baker
    • Bridgewater-Brunel
  • Languages: EN
Re: SPADs
« Reply #11 on: September 02, 2013, 03:53:45 PM »
AEO - thank you. The first bug has, in fact, already been fixed. The second is interesting. When I load your saved game with my 11.x development version, the first convoy to enter the station displays this issue, but, having run it for a long time since, this is not repeated. Is this the same result that you get, or do you see this second error more frequently?

Offline ӔO

  • Devotees (Inactive)
  • *
  • Posts: 2345
  • Hopefully helpful
  • Languages: en, jp
Re: SPADs
« Reply #12 on: September 02, 2013, 03:58:12 PM »
the second error happens quite frequently on the server, from what I have seen.

when looking at swaningborne, all the trains that pass through a choose signal experience that 4km/h bug.

Offline jamespetts gb

  • Simutrans-Extended project coordinator
  • Moderator
  • *
  • Posts: 18745
  • Cake baker
    • Bridgewater-Brunel
  • Languages: EN
Re: SPADs
« Reply #13 on: September 02, 2013, 04:01:54 PM »
Yes - the 4km/h bug is present in 11.10, but fixed on the 11.x branch. Does the second bug relating to scheduling slots appear frequently on the saved game that you posted here, or was that occurrence a one off?

Offline Carl

  • Devotee
  • *
  • Posts: 1600
    • Website
  • Languages: EN
Re: SPADs
« Reply #14 on: September 02, 2013, 04:05:28 PM »
The 4kph bug is not only repeated at choose signals and is (I would wager) related to a similar one I reported a couple of versions ago. Here's a place where I've tracked it down where there are no choose signals involved:

https://dl.dropboxusercontent.com/u/61716/4kph.sve

All of the eight-car Brighton-Bedford services going through Kentish Town will slow to 4kph just after the corner for no apparent reason. (I say "all", but actually, the first one that goes through immediately after loading does not. Subsequent convoys do, however.) None of the four-car services on the Sutton Loop services do this.

I think the "same departure time" bug might have a new and different instance, now -- I'm working on tracking down exactly when this occurs.

Offline jamespetts gb

  • Simutrans-Extended project coordinator
  • Moderator
  • *
  • Posts: 18745
  • Cake baker
    • Bridgewater-Brunel
  • Languages: EN
Re: SPADs
« Reply #15 on: September 02, 2013, 04:13:23 PM »
Yes, the 4km/h bug will occur at any choose signal; this is fixed in the 11.x branch. Any insight into the other bugs would, however, be welcomed.

Offline Carl

  • Devotee
  • *
  • Posts: 1600
    • Website
  • Languages: EN
Re: SPADs
« Reply #16 on: September 02, 2013, 04:28:04 PM »
Sorry, to clarify, that savegame shows an instance where the bug occurs with no choose signal present.

Offline ӔO

  • Devotees (Inactive)
  • *
  • Posts: 2345
  • Hopefully helpful
  • Languages: en, jp
Re: SPADs
« Reply #17 on: September 02, 2013, 04:39:18 PM »
I think the "scheduling allocates the same departure time" bug may be related to a save/load when a train is part way through a choose, entering into a platform.

Offline Carl

  • Devotee
  • *
  • Posts: 1600
    • Website
  • Languages: EN
Re: SPADs
« Reply #18 on: September 02, 2013, 04:41:29 PM »
It's certainly related to map loading, but I don't think it's quite that. Rather, when a map is loaded, all convoys which are waiting for spacing will take a few seconds to realise this. During this time, they display only "Loading, 13:04 left" rather than the more conventional "Loading (0 --> XXX%), 13:04 left". If another convoy arrives before they've switched to the second label, it will receive the same spacing slot. I think. I'll try to get a save for this too.

Offline jamespetts gb

  • Simutrans-Extended project coordinator
  • Moderator
  • *
  • Posts: 18745
  • Cake baker
    • Bridgewater-Brunel
  • Languages: EN
Re: SPADs
« Reply #19 on: September 02, 2013, 05:06:53 PM »
Hmm - that is a separate bug. The issue appears to be that the Brighton-Bedford trains fail to reserve a route on leaving St. Pancras International. Investigating...

Offline Carl

  • Devotee
  • *
  • Posts: 1600
    • Website
  • Languages: EN
Re: SPADs
« Reply #20 on: September 02, 2013, 05:09:13 PM »
Ah, ok -- thanks.

Two more bug demonstrations. First, a savegame for the bug described in my last post. It will happen here at High Barnet immediately after the map is loaded.
https://dl.dropboxusercontent.com/u/61716/spacingslot.sve

And now one which is related to the original topic of this post -- misuse of choose signals. At the underground Piccadilly platforms a convoy will sometimes "choose" an already-occupied platform as its destination. Upon loading you will see that it's already happened on one of the underground platforms. It will reoccur from time to time, albeit not all that often.
https://dl.dropboxusercontent.com/u/61716/chooseplatform.sve

Offline jamespetts gb

  • Simutrans-Extended project coordinator
  • Moderator
  • *
  • Posts: 18745
  • Cake baker
    • Bridgewater-Brunel
  • Languages: EN
Re: SPADs
« Reply #21 on: September 02, 2013, 11:39:00 PM »
Thank you for your reports - I have now found and fixed the "4km/h" bug on the 11.x branch: what was in fact happening was that trains were starting without reserving their route when a signal was placed at the same tile as that on which a train started from a scheduled stop (in this case, at the end of the platforms at St. Pancras, which were filled by the 8-car trains, but not the 4-car trains (I assume from that that the 12 car trains run only in peak time); the 4 car trains stopped a tile further back, which is why they did not exhibit this bug).

This was capable of causing problems other than slowing down, including ignoring red signals, which is the original topic of this post. I have not been able to confirm, however, whether the reported issues are caused by this bug, and therefore now fixed.

Edit: I have now also fixed the bug whereby convoys would be allocated the same departure time as convoys already in a station when the game was freshly loaded. This was caused by failing to register convoys as loading at a stop when the game was loaded.
« Last Edit: September 02, 2013, 11:57:20 PM by jamespetts »

Offline Carl

  • Devotee
  • *
  • Posts: 1600
    • Website
  • Languages: EN
Re: SPADs
« Reply #22 on: September 03, 2013, 07:19:33 AM »
Excellent, thanks!

Offline ӔO

  • Devotees (Inactive)
  • *
  • Posts: 2345
  • Hopefully helpful
  • Languages: en, jp
Re: SPADs
« Reply #23 on: September 03, 2013, 06:07:39 PM »
I think I have reproduced the bug where trains will fail to properly reserve blocks after a save/load.

After a train has failed to properly reserve blocks ahead, it will keep its bad path and run into the train ahead and will keep doing this until it gets stuck when the train in front needs to reverse.


This is caused when a train waiting at a signal 'resets' its block reservation, and the train immediately behind it will detect that the block in front is open, when in fact, it is not.

You should see that the block at the signal is incorrectly shown as 'free', because the train is attempting to be a contortionist.

Offline jamespetts gb

  • Simutrans-Extended project coordinator
  • Moderator
  • *
  • Posts: 18745
  • Cake baker
    • Bridgewater-Brunel
  • Languages: EN
Re: SPADs
« Reply #24 on: September 26, 2013, 11:06:22 PM »
Thank you, AEO - that is very helpful. I think that I have now fixed this issue on the 11.x branch.