JGRennison / OpenTTD-patches

OpenTTD - http://www.openttd.org/ - with additional patches
Other
553 stars 127 forks source link

[Bug]: "Time since last pickup" day count is scaled by the square of the day length factor #625

Closed 0-zM closed 5 months ago

0-zM commented 6 months ago

Version of OpenTTD

0.56.2

Expected result

The Rating Details tooltip displayed when hovering over a cargo type in the rations screen for a station includes the time since the last time that cargo type has been picked up, which is relevant for station rating calculations. When using a day length factor greater than one, the allowed time until you receive a rating penalty for long waits gets scaled by that same factor, and the time displayed in the window should also get scaled in the same way.

Actual result

When using longer day lengths, the time that gets displayed in the tooltip is significantly shorter than the time which has elapsed in game or the time used for station rating calculations. The ratio between the actual time and the time in the tooltip is roughly the day length factor, which leads me to believe that the displayed time is erroneously being scaled twice.

Steps to reproduce

New Rinston Transport, 1970-01-18.sav.tar.gz Day length factor is set to 3. The coal train in the save takes roughly 17 days to complete a full round trip, but when checking the ratings screen of New Rinston Mines just before the train returns to the station, the displayed time is just five days.

JGRennison commented 6 months ago

Thanks, this will be fixed in the next release.