@Override
	public void keyPressed(KeyEvent e) {
		if (e.getKeyCode() == KeyEvent.VK_LEFT) {
			leftPressed = true;
		}
		
		if (e.getKeyCode() == KeyEvent.VK_RIGHT) {
			rightPressed = true;
		}
		
                if (e.getKeyCode() == KeyEvent.VK_N) {
			nPressed = true;
                }	
		
		if (e.getKeyCode() == KeyEvent.VK_P) {
		    pPressed = true;
		}
	}