pi-snake
v1.0.2
Published
Terminal Snake game for pi — classic arcade with audio-reactive visuals and power-ups
Maintainers
Readme
pi-snake 🐍
Terminal Snake game for pi — classic arcade with power-ups, walls, portals, and skins.
Install
npm install -g pi-snakePlay
/snake # Normal mode — walls at higher levels
/snake classic # Wrap-around edges, no walls
/snake turbo # Fast mode for expertsControls
| Key | Action | |-----|--------| | ←→↑↓ / WASD | Move | | K | Cycle skin (Neon, Lava, Ice, Toxic, Royal, Gold) | | P / ESC | Pause | | R | Restart (game over) | | Q | Quit |
Features
- 6 Snake Skins — Neon, Lava, Ice, Toxic, Royal, Gold
- 5 Power-ups — ⚡ Speed boost, 👻 Ghost (phase through walls/self), 🧲 Magnet (pulls food), ✂ Shrink, ❄ Freeze (slow time)
- Progressive difficulty — walls and portals appear at higher levels
- Portal pairs — teleport across the board
- Persistent high scores — saved across sessions
- 3 Game modes — Normal, Classic (wrap), Turbo
Architecture
Single-file pi extension (extensions/pi-snake.ts). Uses pi TUI component API with handleInput/render/invalidate. Box-drawing chrome matches pi-tetris style.
License
MIT
