I was making a countdown in my game for the Heist Jam, but its a big game, and the lag messed with the timing. I thought it would be a simple fix with the Deltatime Extension but it still doesn’t work.
I copied the code into the project below, please help.
The demo includes the timer and a bunch of sprites to lag the game. You can press A to clear the sprites without resetting the timer.
I was correct in my initial guess, but also that “delta” block is very incorrect. It looks like it’s correct at first, but after the lag actually starts it becomes wildly incorrect. What you should be doing is this:
The “delta” block is taking the maximum of the delta time * 30 and 1. This is… incorrect. It means that until the lag gets bad enough that delta time * 30 is greater than 1, you’re just multiplying/dividing by 1. That’s why the timer looked correct when you were dividing, until the lag started to affect it, and it became very wrong.