|
This post was updated on .
I just noticed that Thread.sleep is not totally accurate when the JVM is bussy (the thread oversleeps or undersleeps) can you help me?
EDIT: I was in a hurry when I wrote the post, let me rewrite it.
In my application main loop I perform the game logic and then sleep the thread for 25-(game logic cost) milliseconds, and sometimes the sleep last for more than 25 milliseconds, throwing unpleasant results, I want to know how yo deal with this issue in Java, I hope you can help me, thanks in advice.
|