Game runs very fast when deactivating TransitionGameState

I got a problem with the TransitionGameState.

Showing it up and fading into LevelGameState works fine, but the first update times are too high, so the game runs too fast for the first update cycles.



If I make some output in the LevelGameState:

protected void stateUpdate(float tpf) {
      super.stateUpdate(tpf);
      System.out.println(tpf);
      ...
}



the first tpf's are above 0.3, if I have a long loading time, later the mean tpf is 0.012.

Where and how can I catch the large tpf, or what can I do against it?

Ok, I solved it.



In my maingame I catch large times by dividing them by 10:



    protected void update(float tpf) {
       if (tpf > 0.1f)
          tpf /= 10;
       ..
    }



I hope thats a good solution, looks like it works for my case.

hmm, might try resetting the timer actually…

Thats a much better solution  ;), thanks for it!