public void update() {
		input.update();
		
		if(input.space && fireCooldown == 0) {
			int missileStartX = x + (sprite.WIDTH / 2);
			int missileStartY = y;
			
			Game.playerMissiles.add(new PlayerMissile(missileStartX, missileStartY));
			
			fireCooldown = 180;
		}
		if(fireCooldown > 0) fireCooldown--;
		
		int xa = 0, ya = 0;
		
		if(input.left) xa--;
		if(input.right) xa++;
		
		if(xa != 0 || ya != 0) {
			if((x + xa) >= 0 && (x + xa + sprite.WIDTH) <= Game.width) {
				move(xa, ya);
				moving = true;
			}
		} else {
			moving = false;	
		}
		
		super.update();
	}