Games·terminal · desktop·MIT
tool-snake
Snake beside the chat, where every tool call Claude makes turns into food.

tool-snake is a Snake game for the minutes Claude spends working. Every tool call Claude makes adds a piece of food to the board, marked with the tool’s initial, and the snake moves only until Claude finishes the turn. Nothing in the mod calls the model, so playing costs no tokens. cc-arcade has a Snake among its nine games; in tool-snake, Claude’s work sets the food.
The demo comes from the author’s launch animation, drawn in code with the mod’s game logic. The zoom and the sparks belong to the animation: the pane itself draws neither.
What it does
- Sending a prompt opens the game pane: beside the chat in the fullscreen layout, above the prompt otherwise.
/snakeopens it at any other time. - Each chip shows the tool’s initial and color: B for Bash in yellow, E for Edit in pink, R for Read in cyan, W for Write in orange, G for Grep and Glob in blue. Other tools drop a gray chip with their first letter. Only the main agent’s calls count; subagent calls drop nothing.
- The board is 22 by 12 squares, the edges wrap, and the snake takes a step every 110 ms. Running into your own body ends the round.
- When Claude finishes, the snake freezes, the badge flips from LIVE to DONE, and a toast tells you how many of the turn’s tool calls you ate. Claude Code also says it out loud.
- The eaten count and any leftover food reset with each prompt. The score keeps adding up, even after a crash, and the best score of the session sits above the board.
Install
Needs Claude Code 2.1.287 or later and git to clone the repo.
git clone https://github.com/Yash1927/claude-code-snake
claude --plugin-dir claude-code-snake
The repo has no marketplace, so the mod loads only when you start Claude Code with --plugin-dir pointing at your clone. Send Claude a prompt and the pane opens. Click the board to give it the keys: arrow keys or WASD steer, r restarts after a crash, Esc hands the keys back to the prompt.
How it works
The mod hooks prompt.submit to start a turn and open the pane, tool.call to drop food, turn.complete to stop the snake, and ui.message to announce the final count. A tool.call hook receives the whole call, but tool-snake keeps only the tool’s name and call ID: no command, file path or output. It never reads the text of your prompts either; a prompt only marks the start of a turn.
Its state is two values in the mod’s own store: the current turn’s food (the last 60 calls at most) and your best score. It makes no network calls. The end-of-turn summary goes to a toast and to Claude Code’s audio.speak.
Limitations
- The author documents the game in the terminal and the Claude Desktop app. Where the pane can’t host it, a one-line notice takes its place, and nothing appears in
claude -p. - The pane opens with every prompt you send, and the code has no setting to stop that or to mute the spoken summary.
Similar Claude Mods
intermission
Multiplayer Doom deathmatch in a pane while Claude works, handed back when it needs you.
claude-arcade
Five retro games in a pane that freeze whenever Claude needs you.
claude-doom
The original Doom engine and Freedoom, playable in a Claude Code pane with /doom.
mission-control
Main agent, subagents and every tool call in a pane, plus a map of the files they touch.
Popular Claude Mods
The whole directory →replay-theater
A /replay pane that walks through the last turn's file edits, one diff per step.
paste-view
Previews of pasted text and thumbnails of pasted images, drawn above the prompt.
RemCTL
Today's Apple Reminders above the prompt, plus tools for Claude to manage them.
firstmate-calm
Hides tool rows and swaps the spinner for a sailboat. Toggle with /calm, zero tokens.





