hey im trying to create a time counter to show how long the player has been alive for
can anyone help?


// When the game is started, do: long startTime = System.currentTimeMillis(); // Later (for example in an act() method), do: long currentTime = System.currentTimeMillis(); int durationMillis = (int)(currentTime - startTime); // durationMillis is in milliseconds, so you // can convert to seconds/minutes whatever: int durationSecs = durationMillis / 1000;