Page 1 of 1

[boskid] [2.0.11] Train stop condition "Station is full" and "Station is not full" are not filled green when expected

Posted: Sun Oct 27, 2024 3:10 pm
by Incon22
I'm actually not quite sure if it's a bug but I think the "Wall is not full" condition should be empty/grey when all stations with that name are full or deactived. And while testing, I found out that "[Station] is full" contition is not green. They seem to be swapped.
The behavior of the train is still like I would expect aka it would drive when said conditions is met.

Picture has both condition just as a test/proof and "Wall" has a train limit of 1
10-27-2024, 15-57-26.png
10-27-2024, 15-57-26.png (51.21 KiB) Viewed 1125 times

Re: [2.0.11] Train stop condition "Station is full" and "Station is not full" are not filled green when expected

Posted: Sun Oct 27, 2024 5:56 pm
by boskid
Thanks for the report. Issues are now fixed for 2.0.12. In this case those were actually 2 separate bugs. "Station is not full" drawing was simply inverted (it was drawing green when condition was false). "Station is full" was a different issue because it tries to do a smart logic of drawing fractional highlighting so if you have 2 slots occupied out of 5 total it would draw as fulfilled in 2/5th, but this code was not handling cases of 0 out of 0 going into a floating point divide by zero that returned a fraction of 0 when for this logic it should be a fraction of 1.