drekdrek / grinding-stats

Openplanet plugin which shows statistics
https://openplanet.dev/plugin/grindingstats
MIT License
6 stars 5 forks source link

Timer stops when disabling HUD while it is paused #14

Closed NotEnoughSpeed closed 1 year ago

NotEnoughSpeed commented 2 years ago

So I only noticed this because I have a weird habit when playing the game: I usually turn HUD off when driving and when I "give up" I turn it on again for a short moment (to look at plugins, time left on server etc.) and then turn it off again. When playing the campaign yesterday I noticed that on a track with length ~1 minute I had >10 finishes, but the grinding stats timer was below 5 minutes, which is impossible of course. I tested a bit and saw that every time I "give up" and restart the track, the timer stops for a short while, which is a nice feature but as it turns out the timer does not start again if I turn of the HUD while it is stopped. If I wait a short moment until the timer starts running again and then turn the HUD off it seems to work fine, but turning the HUD off while the timer is paused makes it so the timer does not "un-pause" itself. I also tested this in the case that the grinding stats window stays visible, even if HUD is off, and the same error occurs. On the other hand if the HUD stays off between resetting and starting a new run, the timer does not pause itself at all, it just keeps going the whole time. I really like the plugin and hope that there is an easy way to fix this :) (sorry for long paragraph xD)

drekdrek commented 2 years ago

im currently rewriting the timer logic, this should be fixed in the next few days.

drekdrek commented 1 year ago

sorry for the really late response on this, ive had alot of stuff going on away from the internet.

for the life of me i cannot reproduce this bug. could you detail some steps to get this issue to arise?

NotEnoughSpeed commented 1 year ago

step 1: press "give up" step 2: while the countdown for the new attempt is going and the grinding stats timer is stopped, hide the interface Now when you start driving, the grinding stats timer will stay paused until you turn the interface on again. To test this you can set the Display setting to "Always" so the grinding stats window stays on screen while you hide the interface. Quick example after doing the 2 steps: as you can see the timer stays on 01:03.81 even tho I drove on the track image image

drekdrek commented 1 year ago

should be fixed in the latest update.