Hello!
I have a game on a build, my game is action with smoke and fire -> http://temp4321.dy.fi/dist4/appletloader.php
Why my game runs slow on WinXP and OK with Ubuntu 9.04.
I have no knowledge about timers or any delays. i have added the following code to help understand my problem.
class coordinateThread extends Thread
{
public void run()
{
while ( true )
{
long endtime = System.nanoTime()+2000000;
while ( endtime > System.nanoTime () )
try
{
Thread.sleep( 0, 200000 );
} catch (InterruptedException ex)
{
Logger.getLogger(Main.class.getName()).log(Level.SEVERE, null, ex);
}
This code is my only extra Thread on my game, it is build to make game coordinate changes smoother.
As this is only my second Java game, and first with LWJGL, i need this help.
With Ubuntu my game runs ok, but with my WINXP my game runs real slow even as the screen update is smooth ??
So, With XP my game runs far too slow, why is this i have no experience on timers or any delays ??
How to fix this problem, what is the best answer, is my approach to Thread.sleep() totally wrong ??
//----
Thanks,
