Add the digital speedometer back in (with patch and images)
Posted: 03 May 2019, 11:38
I've asked about this years ago when 0.9 was in development, but this time I decided to become proactive to satisfy this myself. I created a patch file that returns the digital speedometer that last appeared in 0.8.1. It must be applied to the STK source code for it to have any effect. The following is changed with this patch:
After applying this code, I discovered the average numeric speeds of all three kart classes (all of them were obtained using the SuperTux difficulty):
Here is the patch itself, now online at https://gitlab.com/snippets/1866881, where it will receive changes to continue working in the latest STK dev versions.
Below are screenshots showing this patch in action (note that I have changed the code to display the speed as a decimal since taking these screenshots).
At least now I can tell exactly how fast karts are driving! Later on, I can add a setting to toggle the units shown, but I don't want to make too many drastic changes for now. I barely started exploring the STK source code, so anything else I would like to do, I need to familiarize myself with.
- The digital speedometer is added back in, this time in normal-sized font and with meters per second unit (displayed as "m/s"). It also uses a black border to make it easier to see this value, and it is now one digit precise after the decimal point.
- The rank number is not removed.
- The speedometer does not display if a kart is not driving forward, same as from 0.8.1.
- The digital speedometer is now placed above the graphical one, no longer sharing space with the rank number. It now shows meters/second, kllometer/hour, feet/second, mile/hour. For now, both metric and imperial units are shown.
After applying this code, I discovered the average numeric speeds of all three kart classes (all of them were obtained using the SuperTux difficulty):
- Heavy: 26.2 m/s
- Medium: 25.0 m/s
- Light: 23.8 m/s
Here is the patch itself, now online at https://gitlab.com/snippets/1866881, where it will receive changes to continue working in the latest STK dev versions.
Below are screenshots showing this patch in action (note that I have changed the code to display the speed as a decimal since taking these screenshots).
At least now I can tell exactly how fast karts are driving! Later on, I can add a setting to toggle the units shown, but I don't want to make too many drastic changes for now. I barely started exploring the STK source code, so anything else I would like to do, I need to familiarize myself with.