JGRennison / OpenTTD-patches

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

[Bug]: Last vehicle max speed isn't said to be clamped #772

Closed jostephd closed 2 weeks ago

jostephd commented 3 weeks ago

Version of OpenTTD

jgrpp-0.63.0-2-g73dbed7e2

Expected result

The "Max speed of last vehicle" should say "643 km/h", or at least "more than 256 km/h".

Actual result

It says "Max speed of last vehicle: 256 km/h".

That's confusing, because that's not the speed limit of any relevant piece of infrastructure (engine, wagons, track).

Steps to reproduce

  1. Set the Station ratings tooltip preference to Detailed.
  2. Get a Lev4 maglev train to pick up cargo at a station and leave the station.
  3. Wait a few seconds for that station to get a cargo rating for that cargo.
  4. See what the cargo rating tooltip says.
JGRennison commented 3 weeks ago

This is how the ratings algorithm works, the speed field for this is one byte. The details mode is to display what is recorded and goes into the algorithm. There isn't any plan to record additional information or make fields wider just for the tooltip.

jostephd commented 2 weeks ago

Thanks for explaining. I understand the speed is capped to 256 km/h because internally it's a uint8_t, and I'm not asking to make the field wider just for this. However, is there any chance of rephrasing the tooltip? As it stands it gives the impression that the train's speed is 256 km/h, even though it's actually traveling at over double the speed. Just to change "256 km/h" to "at least 256 km/h" in the tooltip text is what I'm asking.

Actually, for me it said "4.6 tiles/sec", so I didn't even have the hint that something powers-of-two-y was going on...

Anyway, it's not a biggie, feel free to close if you disagree.

This is how the ratings algorithm works, the speed field for this is one byte. The details mode is to display what is recorded and goes into the algorithm. There isn't any plan to record additional information or make fields wider just for the tooltip.

-- Reply to this email directly or view it on GitHub: https://github.com/JGRennison/OpenTTD-patches/issues/772#issuecomment-2458521859 You are receiving this because you authored the thread.

Message ID: @.***>

JGRennison commented 2 weeks ago

That makes sense, I've made a change along these lines, it'll be in the next release.

jostephd commented 2 weeks ago

Thank you!