diff --git a/HeatUp/src/de/heatup/ui/KeyBindings.java b/HeatUp/src/de/heatup/ui/KeyBindings.java index caa6214..49e5368 100644 --- a/HeatUp/src/de/heatup/ui/KeyBindings.java +++ b/HeatUp/src/de/heatup/ui/KeyBindings.java @@ -42,7 +42,12 @@ public class KeyBindings extends KeyAdapter { down = false; break; case KeyEvent.VK_ESCAPE: - esc = false; + //esc = false; + if ( key ) { + esc = false; + } else { + esc = true; + } break; case KeyEvent.VK_A: key = false; @@ -78,9 +83,9 @@ public class KeyBindings extends KeyAdapter { case KeyEvent.VK_DOWN: down = true; break; - case KeyEvent.VK_ESCAPE: - esc = true; - break; +// case KeyEvent.VK_ESCAPE: +// esc = true; +// break; case KeyEvent.VK_A: if(((MapGrid.getGridCell(Main.player01.getGridLocation().x, Main.player01.getGridLocation().y).isTrigger() && !HardewareManipulate.getHardware(MapGrid.getGridCell(Main.player01.getGridLocation().x, Main.player01.getGridLocation().y).getCorrespondingHardwareToTrigger()))&&!key)&&ActionControl.getKeyA()){ @@ -190,8 +195,8 @@ public class KeyBindings extends KeyAdapter { player.animate = true; } if (isESC()) { - System.out.println("ESC pressed."); Main.pause(); + esc=false; } }