Shellsnake is a terminal-based Snake game for Windows, built as part of the Shellcade collection of classic arcade experiences.
Install the root requirements.txt before playing to enable Blessed terminal
rendering.
The ui.py module owns the Snake terminal session and keeps screen control
separate from gameplay rules.
- Real-time Snake gameplay in a terminal
- Arrow-key and WASD controls
- Pause, quit, and replay flow
- Persistent top-ten leaderboard
- Speed increases every 50 points
- No third-party Python dependencies
| Key | Action |
|---|---|
| Arrow keys / W A S D | Steer the snake |
| P | Pause or resume |
| Q | Quit to the menu |
| Enter | Select a menu option |
Eat fruit to grow and earn 10 points. Avoid the walls and the snake's own body. The game ends when the snake collides with an obstacle.
Open a Windows terminal in the project directory and run:
python snake.py
You can also double-click snake.bat.
To run the rule regression tests:
python -m unittest test_snake.py
snake.py- application entry pointgame.py- Snake state, collision rules, scoring, and renderinggame_loop.py- real-time input and movement timingmenu.py- menu, leaderboard, and instructions screensdisplay.py- terminal rendering helperskeyboard_input.py- Windows keyboard and name-entry handlingscores.py- persistent leaderboard storageconstants.py- board dimensions and shared pathstest_snake.py- regression tests for movement and collisions
This project is intended for personal and educational use.