Last Updated: 3/18/2026
Complete keyboard reference for Snake Game. This guide covers all input controls for gameplay, view manipulation, and bot automation.
Movement Controls
The snake responds to both arrow keys and WASD keys for movement. Both sets work identically during gameplay.
Arrow Keys
- Up Arrow — Move snake up
- Down Arrow — Move snake down
- Left Arrow — Move snake left
- Right Arrow — Move snake right
WASD Keys
- W — Move snake up
- S — Move snake down
- A — Move snake left
- D — Move snake right
Direction Changes — You cannot reverse direction directly. If the snake is moving right, pressing left (or A) has no effect. Turn up or down first, then change to the opposite horizontal direction.
Starting the Game — The game begins in a paused state. Press any movement key to start the game loop. The snake immediately begins moving in the chosen direction.
Game Control
Pause and Resume
- P — Pause the game / Resume from pause
Pausing stops all game logic: the snake stops moving, the timer freezes, and food spawning suspends. Press P again to resume exactly where you left off.
Pausing works during active gameplay but not on the menu or game-over screens.
Reset
- R — Start a new game immediately
This works at any time: during gameplay, while paused, or on the game over screen. The game resets without confirmation, starting fresh with your current grid size setting.
Grid Size Adjustment
- + or = — Increase starting grid size (maximum 50×50)
- - or _ — Decrease starting grid size (minimum 5×5)
Grid size changes only apply before starting a game. Once the game loop is running, these keys have no effect. The grid size adjusts in increments of 5 (5×5, 10×10, 15×15, etc.).
The current grid size appears in the game info area in the format “Grid: 10x10”.
Bot Automation
Toggle Bot Mode
- B — Enable bot mode / Disable bot mode
When bot mode is enabled:
- AI takes control of the snake using pathfinding algorithms
- Auto-rotation activates (the 3D view slowly rotates)
- You can still pause, reset, and adjust the view manually
- The bot status indicator shows “ON” with the active bot profile name
When bot mode is disabled:
- Manual control via arrow keys or WASD resumes
- Auto-rotation stops
- The bot status indicator shows “OFF”
You can toggle bot mode at any time during gameplay. Switching mid-game hands control to/from the AI without interrupting the game loop.
Bot Profile Selection
Use the Bot Profile dropdown menu to choose between three AI strategies:
- Survival — Prioritizes staying alive, avoids risky paths
- Hunter — Aggressively pursues food, accepts moderate risk
- Explorer — Balances exploration with safety
You can switch profiles at any time, even while the bot is playing. The change takes effect on the next move decision.
Bot profiles are available from both the menu screen (before starting) and during gameplay. Both dropdowns stay synchronized—changing one updates the other.
View Rotation (3D Mode)
The game renders a 3D isometric view of the grid. You can manually rotate the camera and adjust perspective depth.
Manual Rotation
- Q — Rotate view clockwise (5° per press)
- E — Rotate view counter-clockwise (5° per press)
Manual rotation pauses auto-rotation (if enabled) for 3 seconds. After 3 seconds without input, auto-rotation resumes if bot mode is active.
Perspective Strength
- [ — Decrease perspective strength (more parallel projection)
- ] — Increase perspective strength (more pronounced depth)
Perspective strength controls how much closer objects appear larger than distant objects. At 0 strength, all blocks render at the same size regardless of position (parallel projection). At maximum strength (0.8), blocks in the foreground appear significantly larger.
Adjusting perspective works at any time and updates the view immediately.
Menu and Navigation
Starting Games
- Enter — Start new game (from menu or game-over screen)
On the main menu or game-over screen, pressing Enter is equivalent to clicking the “New Game” or “Play Again” button.
During active gameplay, Enter has no effect (use R to reset instead).
Bot Profiles
- Mouse click — Select from Bot Profile dropdown
- Mouse click — Click “Start Demo Bot” to begin with bot automation enabled
The dropdown and buttons respond to mouse input only (no keyboard shortcuts for menu navigation).
Controls Summary Table
| Key | Action | Context |
|---|---|---|
| Arrow keys / WASD | Move snake | Gameplay |
| P | Pause / Resume | Gameplay |
| R | Reset game | Anytime |
| B | Toggle bot mode | Gameplay |
| Enter | Start new game | Menu / Game Over |
| +/= | Increase grid size | Before game starts |
| -/_ | Decrease grid size | Before game starts |
| Q | Rotate view clockwise | Anytime |
| E | Rotate view counter-clockwise | Anytime |
| [ | Decrease perspective | Anytime |
| ] | Increase perspective | Anytime |
Keyboard Shortcuts vs. Mouse
All essential gameplay controls use the keyboard. The mouse is only required for:
- Selecting bot profiles from the dropdown menu
- Clicking the “New Game” and “Start Demo Bot” buttons
Once a game is running, you can play entirely with the keyboard. This makes the game accessible for quick keyboard-driven sessions without switching between input devices.
What’s Next
- Game Mechanics: How collision detection, food spawning, and grid scaling work under the hood
- Bot Automation: Deep dive into AI pathfinding strategies and customizing bot behavior