Re:Game Timers: Issues and Solutions (2012)
by flohofwoe on Tuesday August 17, 2021 @01:33PM
(#28212541)
This isn't the problem, those timers exist and are accessible (unless you're in a web browser). The problem is that your code is essentially running at an unpredictable point in time within the current frame. E.g. if you measure the time duration between the same line of code at the start of your per-frame function you'll get a tiny jitter and never exactly 16.66667 ms (assuming a 60Hz display). I'm not sure what's the exact reason, but I guess there are many things that can throw off this sort of time measurement in a modern operating system (for instance process/thread scheduling).
[ Parent
| on HN ]
There are no comments on this comment yet.