private void initInput() {
        moveLeft = new GameAction("moveLeft");
        moveRight = new GameAction("moveRight");
        jump = new GameAction("jump",
            GameAction.DETECT_INITAL_PRESS_ONLY);
        exit = new GameAction("exit",
            GameAction.DETECT_INITAL_PRESS_ONLY);
        fire = new GameAction("fire");
        pause = new GameAction("pause", GameAction.DETECT_INITAL_PRESS_ONLY);
        restart = new GameAction("restart", GameAction.DETECT_INITAL_PRESS_ONLY);
        instructions = new GameAction("instructions", GameAction.DETECT_INITAL_PRESS_ONLY);
        credits = new GameAction("credits", GameAction.DETECT_INITAL_PRESS_ONLY);
        sound = new GameAction("sound", GameAction.DETECT_INITAL_PRESS_ONLY);
        
        inputManager = new InputManager(
            screen.getFullScreenWindow());
        inputManager.setCursor(InputManager.INVISIBLE_CURSOR);

        inputManager.mapToKey(moveLeft, KeyEvent.VK_LEFT);
        inputManager.mapToKey(moveRight, KeyEvent.VK_RIGHT);
        inputManager.mapToKey(jump, KeyEvent.VK_UP);
        inputManager.mapToKey(fire, KeyEvent.VK_SPACE);
        inputManager.mapToKey(exit, KeyEvent.VK_ESCAPE);
        inputManager.mapToKey(pause, KeyEvent.VK_P);
        inputManager.mapToKey(restart, KeyEvent.VK_ENTER);
        inputManager.mapToKey(instructions, KeyEvent.VK_I);
        inputManager.mapToKey(credits, KeyEvent.VK_C);
        inputManager.mapToKey(sound, KeyEvent.VK_S);
    }