Skip to main content

Keyboard Controls

Space Birds supports full keyboard control for desktop players. All controls are responsive and allow smooth gameplay.

Movement Controls

KeyAction
← (Left Arrow)Move bird left
→ (Right Arrow)Move bird right
↑ (Up Arrow)Move bird up
↓ (Down Arrow)Move bird down
Movement is continuous while the key is held. The bird stays within screen boundaries automatically.

Action Controls

KeyActionState
SPACEShoot bulletPLAYING, MENU
ENTERStart game / View scoreMENU, PLAYING, GAME_OVER
ESCEnd game earlyPLAYING
Press ENTER during gameplay to view your current score without ending the game!

Touch Controls (Mobile)

The game features intuitive touch controls optimized for mobile devices.

Touch Movement

Directional Touch System

Touch anywhere on the screen and the bird will move toward your finger position.

How It Works

  1. Touch the Screen: Place your finger anywhere
  2. Bird Follows: The bird moves toward your touch position
  3. Dead Zone: A 5-pixel dead zone prevents micro-movements
  4. Continuous Tracking: Keep your finger down for continuous movement

Touch Direction Logic

Horizontal Movement:
- Touch more than 5 pixels to the right → Bird moves right
- Touch more than 5 pixels to the left → Bird moves left

Vertical Movement:
- Touch more than 5 pixels above bird → Bird moves up  
- Touch more than 5 pixels below bird → Bird moves down
The dead zone of 5 pixels prevents accidental movements when you’re trying to hold position.

Touch Actions in Different States

StateTouch Action
MENUTap anywhere to start game
PLAYINGTouch and drag to move bird
GAME_OVERNo touch action (use ENTER key)
Touch controls do NOT trigger shooting. You must use keyboard SPACE or mouse right-click to fire.

Mouse Controls

Mouse controls provide an alternative shooting method for desktop players.

Mouse Actions

ButtonActionState
Right ClickShoot bulletPLAYING

Hybrid Control Scheme

Many players prefer using arrow keys for movement and right-click for shooting, as it allows for more precise control.

Mouse Shooting Features

  • Same 0.3-second cooldown as keyboard shooting
  • Produces visual flash effect
  • Plays shooting sound effect
  • Fires bullet from bird’s center position

Control Tips

Desktop Players

Use arrow keys for movement and SPACE or right-click for shooting. Try both shooting methods to find your preference!

Mobile Players

Use touch to move your bird around, but remember you’ll need to connect a keyboard or use an external input method to shoot.
For best performance on desktop, use keyboard for movement and mouse right-click for shooting. This gives you independent control over both actions.

Starting the Game

From the MENU state, you have multiple options:
InputAction
SPACE keyStart game
ENTER keyStart game
Touch screenStart game

In-Game Controls

InputActionResult
ESCQuit to game overShows final score
ENTERView current scoreTemporary score overlay
Arrow KeysMovementContinuous while held
SPACE / Right ClickShoot0.3s cooldown

Game Over Screen

InputAction
ENTERReturn to menu
The game over screen only responds to the ENTER key. Touch and other inputs are disabled in this state.

Movement Boundaries

The bird automatically stays within screen boundaries:
  • Left Boundary: 0 pixels (left edge)
  • Right Boundary: Screen width - 64 pixels (bird width)
  • Bottom Boundary: 0 pixels (bottom edge)
  • Top Boundary: Screen height - 64 pixels (bird height)
You can safely hold movement keys without worrying about going off-screen. The game prevents out-of-bounds movement automatically.

Accessibility

Multiple Input Methods

The game supports multiple control schemes simultaneously: Keyboard-only gameplay (arrows + space)
Hybrid keyboard + mouse (arrows + right-click)
Touch + keyboard (touch movement + space to shoot)
Experiment with different control combinations to find what works best for your play style!

Build docs developers (and LLMs) love