Disable transition effect when entering or leaving game pause.

This commit is contained in:
Jan Philipp Timme 2014-11-29 23:34:01 +01:00
parent 0221bb957d
commit 8ac78ec43c
2 changed files with 2 additions and 2 deletions

View File

@ -91,7 +91,7 @@ public class GamePausedScreen extends Screen {
switch (this.menuPoint) { switch (this.menuPoint) {
case 0: case 0:
//Removes itself from the GameScreen, so the player can continue playing. //Removes itself from the GameScreen, so the player can continue playing.
this.parent.setOverlay(null); this.parent.setOverlay(null, false);
break; break;
case 1: case 1:
//Replaces its parents (the GameScreen) parent (the SuperScreen) overlay. //Replaces its parents (the GameScreen) parent (the SuperScreen) overlay.

View File

@ -92,7 +92,7 @@ public class GameScreen extends Screen {
// Pass the collision handler a copy of the entity list // Pass the collision handler a copy of the entity list
CollisionHandler.handleCollisions(); CollisionHandler.handleCollisions();
if (Keyboard.isKeyDown(KeyEvent.VK_ESCAPE)) { if (Keyboard.isKeyDown(KeyEvent.VK_ESCAPE)) {
this.setOverlay(new GamePausedScreen(this)); this.setOverlay(new GamePausedScreen(this), false);
} }
//Go to GameOverScreen if the game is actually over. //Go to GameOverScreen if the game is actually over.