Mercurial > hg > ristipolku
diff game/Engine.java @ 148:5b25561855c3
Move next piece animation call into better place.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Mon, 28 May 2012 16:46:41 +0300 |
parents | 0ec311706d3c |
children | d6d92845d6a2 |
line wrap: on
line diff
--- a/game/Engine.java Sat Nov 26 11:25:46 2011 +0200 +++ b/game/Engine.java Mon May 28 16:46:41 2012 +0300 @@ -344,6 +344,11 @@ public void animate(float time) { + if (nextPiece != null) + { + nextPiece.animate(time); + } + ptime = time; for (int y = 0; y < boardSize; y++) for (int x = 0; x < boardSize; x++) @@ -846,8 +851,6 @@ // Animate components lauta.animate(gameUpdates); - if (lauta.nextPiece != null) - lauta.nextPiece.animate(gameUpdates); // Repaint with a frame limiter if (gameUpdates % 4 == 1)