opencode-tetris-battleMultiplayer Tetris Battle plugin for OpenCode TUI
0
192
1 in 7 days
28.3
Multi-signal model
3 months ago
2026-05-02
Install and configure
opencode.jsonWrites to this project's opencode.json — applies to this repository only.
opencode.json
{
"$schema": "https://opencode.ai/config.json",
"plugin": ["opencode-tetris-battle@1.0.46"]
}Writes to ~/.config/opencode/opencode.json — applies to every project.
~/.config/opencode/opencode.json
{
"$schema": "https://opencode.ai/config.json",
"plugin": ["opencode-tetris-battle@1.0.46"]
}If you want to modify the plugin locally, install it into the project and reference the local path.
shell
pnpm add -D opencode-tetris-battleopencode loads npm dependencies through its embedded runtime on startup and caches them locally — no manual global install needed.
Multiplayer Tetris Battle for the OpenCode TUI.
Play side-by-side terminal Tetris with live opponent boards, garbage attacks, private room codes, and quick matchmaking. The game uses a hosted Convex backend for rooms, reactive board sync, attacks, and match results.
Install
opencode plugin opencode-tetris-battle@latest --global
Restart OpenCode, then run:
/tetris-battle
Upgrade
bunx opencode-tetris-battle upgrade
Restart your OpenCode TUI session afterwards.
Play
Matchmaking
- Open
/tetris-battlein two OpenCode windows. - Press
Min both windows. - Press
Rin both windows when paired.
Private room
- Host presses
Nto create a numeric room code. - Guest presses
J, types the room code, then presses Enter. - Both players press
Rto ready.
Controls
Splash:
- Any key enters the lobby.
Qcloses the dialog.
Lobby:
Ncreates a private room.Jenters room-code typing mode (4 numeric digits).Enterjoins the typed room code.Mstarts matchmaking.Rtoggles ready.Qopens the quit confirm; pressQagain to confirm orEscto cancel.
Room (waiting / countdown):
Rtoggles ready.Lopens the leave-to-lobby confirm; pressLagain to confirm orEscto cancel.Qopens the quit confirm.
Game:
←/Amoves left.→/Dmoves right.↑/Wrotates.↓/Ssoft drops.Spacehard drops.Cholds.Ppauses.Lreturns to the lobby (double-press to confirm).Qquits (double-press to confirm).
Pause:
Presumes — onlyP,L, andQdo anything while paused; other keys are ignored.Lopens the leave-to-lobby confirm.Qopens the quit confirm.
Match over:
Rrematches in the same room.Lreturns to the lobby.Qquits.
Hosted backend
The plugin works out of the box with the public hosted Tetris Battle backend.
Development
bun install
bun run typecheck
bunx convex dev --once --typecheck=disable
License
MIT