News:

Simutrans Chat Room
Where cool people of Simutrans can meet up.

[BUG] dragging signals can exceed signalboxes capacity

Started by Mariculous, January 19, 2020, 12:22:21 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Mariculous

I just tried to reproduce another bug when I noticed this one.

What happened?
I just dragged a lot signals and they were all placed linking back to the signalbox, whilst the amount would exceed signalboxes capacity. Is seems these excessive signals are not linked back from the signalbox to the signal.

How to reproduce?
- Open the attached save and select the signalbox.
- Select the "stop signal (colur light) and set a small signal spacing e.g. 125.
- Drag signals along the existing rail.
- - You will now have many more signals than what the signalbox could controll.
- Randomly remove some signals.
- - you will see signalboxes counter will decrease for ones that were placed whilst there was still capacity, whilst the others won't decrease the counter.
- Delete the signalbox
- - you will see all signals that were placed whilst there was still capacity to get removes. The others will remain "Controlled from: none"

jamespetts

Thank you for the report: I believe that I have now fixed this. I should be grateful if you could re-test with the next nightly build.
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.

freddyhayward

I'm not sure if this is the correct thread to post this in, but one recent change related to signalboxes caused a segfault when placing signals from signal_group=0 (i.e. one train staff). I have submitted a pull request that I believe fixes this.

jamespetts

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.

Mariculous

Fixed.
As this is not calculated at drag time but later on at placement time, a mesage like
"Not all signaly were built successfully. Attempting to build n signal, but signalbox had only m slots left" would be splendid.

Did not compile the incorporated changes, so I can't confirm the crash to be fixed yet.