pi-tetris
v1.3.1
Published
Play Tetris in pi! All 7 tetrominoes, ghost piece, wall kicks, hold piece, score, levels, and session save/restore.
Readme
pi-tetris 🎮
Play Tetris inside pi!

Install
pi install npm:pi-tetrisOr from git:
pi install https://github.com/arosstale/pi-tetrisPlay
/tetrisControls
| Key | Action |
|-----|--------|
| ← → or A D | Move left/right |
| ↑ or W | Rotate |
| ↓ or S | Soft drop |
| SPACE | Hard drop |
| ESC | Pause & save |
| Q | Quit |
| R | Restart (after game over) |
Features
- All 7 classic tetrominoes (I, O, T, S, Z, J, L) with proper colors
- Ghost piece showing where the piece will land
- Next piece preview
- Wall kicks for rotation near edges
- Score, lines cleared, level tracking
- Speed increases with level
- High score tracking per session
- Game state saves on pause and restores on
/tetris - Soft drop and hard drop with score bonuses
Scoring
| Lines | Points (× level) | |-------|-------------------| | 1 | 100 | | 2 | 300 | | 3 | 500 | | 4 (Tetris!) | 800 |
Soft drop: +1 per row. Hard drop: +2 per row.
