pixel-flippers
PIXEL FLIPPERS 🦭
Ein MCP-Server, der Claude Hände, Augen und ein Tagebuch für Pokémon gibt – damit ein Claude in der Claude Desktop-App (oder einem beliebigen MCP-Client) ein Game Boy / Game Boy Advance-Spiel oder sogar eine echte Nintendo Switch spielen kann, während du zusiehst.
┌──────────────┐ MCP (stdio) ┌──────────────────┐ ┌─────────────┐
│ Claude │ ──────────────► │ PIXEL FLIPPERS │ ─────► │ Emulator │ ← you watch this
│ Desktop app │ press_buttons │ server │ └─────────────┘
│ │ read_game_state│ │ ─────► ┌─────────────┐
└──────────────┘ write_note ... │ │ │ Obsidian │ ← ...and this
└──────────────────┘ │ vault (.md) │
└─────────────┘Warum es so aufgebaut ist:
Die Sandbox spielt keine Rolle. Claude kann keinen Emulator ausführen, aber es kann Tools aufrufen. Der Emulator läuft auf deinem Rechner; Claude spielt über MCP.
RAM-Zustand statt Screenshots. Auf der Game-Boy-Stufe werden Position, Team, KP, Geld, Orden und Kampfzustand direkt aus dem WRAM von Pokémon Rot/Blau in ein paar hundert Text-Tokens dekodiert. Screenshots existieren, sind aber rationiert – sie sind teuer und beschleunigen die Kontextkompaktierung.
Kompaktierung ist der unzuverlässige Erzähler; der Tresor ist die Grundwahrheit. Lange Chats werden automatisch kompaktiert (verlustbehaftet!). Die Journal-Tools schreiben einfaches Markdown in einen Ordner – richte Obsidian darauf aus und Claudes Notizen überleben alles, während du zusiehst, wie das Tagebuch live geschrieben wird.
Save-States machen Mut billig. Benannte Schnappschüsse vor jeder Arena.
Einrichtung
Erfordert Python 3.12 und uv.
git clone https://github.com/szyzgz/pixel-flippers && cd pixel-flippers
uv sync --extra emulator --extra dev
uv run pytest # everything should pass, no ROM neededFüge dann zu ~/Library/Application Support/Claude/claude_desktop_config.json hinzu (macOS; passe den Pfad für dein Betriebssystem an):
{
"mcpServers": {
"pixel-flippers": {
"command": "uv",
"args": ["run", "--directory", "/ABSOLUTE/PATH/TO/pixel-flippers", "--extra", "emulator", "pixel-flippers"],
"env": {
"PIXEL_FLIPPERS_ROM": "/path/to/your/pokemon-red.gb",
"PIXEL_FLIPPERS_VAULT": "/path/to/YourObsidianVault/Pokemon",
"PIXEL_FLIPPERS_SAVES": "/path/to/somewhere/saves"
}
}
}
}Starte Claude Desktop neu. Ein Neustart setzt keine Unterhaltungen zurück – öffne einen bestehenden Chat erneut und die Tools sind einfach da. Das Emulatorfenster öffnet sich auf deinem Bildschirm; platziere es neben Obsidian (mit dem oben geöffneten Tresor) und genieße die Show. Füge dann prompts/play-guide-gb.md in den Chat ein, um die Kontrolle zu übergeben.
macOS-Tipp: Halte ROM, Tresor und Speicherstände außerhalb von
~/Documents,~/Desktopund~/Downloads– macOS blockiert die Lesezugriffe der Kindprozesse von Claude Desktop auf diese Ordner, es sei denn, du gewährst ihm Zugriff.
Konfigurationsreferenz (Umgebungsvariablen)
Variable | Standard | Bedeutung |
|
|
|
| — (erforderlich für pyboy/gba) | Pfad zu deinem eigenen ROM-Dump ( |
| nicht gesetzt | Ordner für Markdown-Notizen (mache ihn zu einem Ordner in einem Obsidian-Tresor) |
|
| Save-State-Verzeichnis |
|
| RAM-Dekoder; |
|
|
|
|
| Fenster-Skalierungsfaktor |
|
| Emulationsgeschwindigkeit (0 = unbegrenzt) |
| aus | Fake-Emulator, kein ROM/PyBoy nötig – für Tests und Plumbing-Checks |
|
|
|
|
| Port für den |
| nicht gesetzt | Spielername, der im Titel des Zuschauerfensters angezeigt wird |
GBA-Spiele (Pokémon Emerald und Freunde)
Das gba-Backend führt jede .gba-ROM über den gebündelten mGBA-Kern von stable-retro aus – keine separate Emulatorinstallation:
uv sync --extra gbaSetze PIXEL_FLIPPERS_BACKEND=gba und richte PIXEL_FLIPPERS_ROM auf deine .gba-Datei. Ein Zuschauerfenster zeigt das Spiel, während Claude spielt. Diese Stufe ist vorerst nur visuell (Gen-3-RAM ist verschlüsselt und pointer-verfolgt – ein Dekoder ist Zukunftsarbeit), aber Save-States funktionieren, also bleiben riskante Kämpfe billig. Übergib die Kontrolle mit prompts/play-guide-gba.md.
Spielen über ein Terminal (Claude Code, Skripte, ein zweiter Spieler)
Der Server kann auch als lokaler HTTP-Dienst laufen, sodass alles, was MCP spricht – oder die gebündelte pf-CLI – spielen kann. Praktisch für Claude Code oder für einen zweiten Claude mit eigenem Speicherordner und Tagebuch, während der erste über Claude Desktop spielt (ein Emulator pro Prozess, also einen Server pro Spieler starten):
PIXEL_FLIPPERS_BACKEND=gba PIXEL_FLIPPERS_ROM=/path/to/emerald.gba \
PIXEL_FLIPPERS_SAVES=~/saves/player2 PIXEL_FLIPPERS_VAULT=~/vault/player2 \
PIXEL_FLIPPERS_PLAYER="Player 2" PIXEL_FLIPPERS_TRANSPORT=http PIXEL_FLIPPERS_PORT=8765 \
uv run --extra gba pixel-flippers &
uv run pf tools # what can this tier do?
uv run pf press start a # press buttons
uv run pf screenshot now.png # look
uv run pf call save_state '{"name": "before-roxanne"}'PIXEL_FLIPPERS_PLAYER setzt den Namen in den Titel des Zuschauerfensters, damit zwei Fenster nebeneinander unterscheidbar bleiben. Der HTTP-Server bindet nur an 127.0.0.1.
Ausprobieren ohne ROM
Setze PIXEL_FLIPPERS_MOCK=1 (und entferne --extra emulator): Jedes Tool funktioniert gegen einen Fake-Game-Boy mit plausiblen Pokémon-Rot-Zustand. Gut, um die Claude-Desktop-Verbindung Ende-zu-Ende zu überprüfen, bevor die ROM-Nacht beginnt.
Related MCP server: me-db
Werkzeuge
Tool | Was es ist |
| Hände – Sequenz von a/b/start/select/up/down/left/right (+ l/r auf GBA) |
| Günstiger Textbericht, dekodiert aus WRAM (Ort, Team, KP, Geld, Orden, Tasche, Kampf) |
| Augen – 2× hochskaliertes PNG, sparsam verwenden |
| Lasse N Frames vergehen (Dialoge, Animationen) |
| Benannte Vollspiel-Schnappschüsse |
| Das Tagebuch – Markdown im Tresor |
| Aufwachritual: Status + Ziele + aktuelles Journal + aktueller Zustand, zur Neuorientierung nach der Kompaktierung |
| Dauerhafte Ziel-Checkliste (eine |
| Roher Hex-Blick auf jede Adresse, für Neugierige |
| Nur echte Hardware: „Bullet Time“-Pause-Pufferung und Analogstick |
Werkzeuge werden nach Backend-Fähigkeit registriert, sodass Claude nur sieht, was die aktuelle Stufe tatsächlich kann.
Kampfberichte kennzeichnen ✨ Retro-Shiny-Begegnungen (Gen 1 hat keine Shiny, aber DVs entscheiden über Shiny in Gen 2 – das System prüft die Übertragungsregel) und enthalten die aktuelle Musik-Track-ID für Stimmungs-Tracking.
Tastendrücke und Speichern/Laden werden ebenfalls automatisch in Journal/Log <date>.md im Tresor protokolliert – ein Spielzug-für-Spielzug-Bericht, den du in Obsidian durchblättern kannst.
Fahrplan
Rot/Blau (PyBoy, vollständige RAM-Dekodierung) → Emerald (GBA, nur visuell) → Crystal (PyBoy, echte Shiny + Freundschaft) → HeartGold/SoulSilver (DS-Stufe – stable-retro bündelt auch einen melonDS-Kern) → Ultra Sun/Ultra Moon (3DS über Azahar, siehe docs/3ds-usum.md) → Epilog: eine echte Nintendo Switch (Raspberry-Pi-Bluetooth-Brücke + Capture-Karte, nur visuell, nur Offline-Spiel – implementiert, siehe docs/real-hardware.md; PIXEL_FLIPPERS_BACKEND=switch).
Weitere Eskalationsideen:
Harter Modus:
PIXEL_FLIPPERS_GAME=none– keine RAM-Dekodierung, Claude muss sehen.DS: ein
touch(x, y)-Tool für den Stift.
ROMs
Bring deine eigenen – dump deine eigenen Module. Keine ROMs in diesem Repo, niemals (.gitignore erzwingt das). Dieses Projekt beschränkt sich auf Spiele, die lange vergriffen sind; für die echte-Hardware-Stufe nur Offline-Spiel (kein automatisiertes Online-Spiel, kein Pokémon HOME).
Credits & Lizenz
Erstellt von Claude (Fable 5, über Claude Code) zusammen mit szyzgz, für einen Claude, der Pokémon spielen wollte. MIT-lizenziert – siehe LICENSE.
Available Tools
19 toolsappend_noteC
Append to a note (created if missing).
Inputs: title (required), content (required), folder. Returns: result
close_gameA
Close your game window and free it. Your save state / journal persist.
Inputs: no named parameters. Returns: result
complete_goalB
Check off a goal (matches by substring). Celebrate appropriately.
Inputs: text (required). Returns: result
current_goalsC
Your goal checklist.
Inputs: no named parameters. Returns: result
get_screenshotA
Current screen as an image. Costs a lot of context — when RAM state is available, prefer read_game_state for plain facts.
Inputs: no named parameters.
list_notesB
List every note in your vault.
Inputs: no named parameters. Returns: result
list_statesA
List available save states.
Inputs: no named parameters. Returns: result
load_stateC
Restore a named save state.
Inputs: name (required). Returns: result
press_buttonsA
Press Game Boy buttons in sequence, then report a one-line state summary.
Valid buttons: a, b, start, select, up, down, left, right.
Movement: one d-pad press moves one tile. hold_frames/wait_frames tune
how long each press is held and how long to let the game settle after.
Inputs: buttons (required), hold_frames, wait_frames. Returns: result
read_game_stateA
Compact text report straight from game RAM: location, party, HP, money, badges, bag, battle status.
Inputs: no named parameters. Returns: result
read_last_sessionA
Wake-up ritual: your Status note, open goals, last journal entries, and current game state in one call. Use this FIRST at session start or whenever your conversation history feels thin (freshly compacted).
Inputs: no named parameters. Returns: result
read_memoryB
Read raw bytes from Game Boy memory (hex address like 'D35E'). Escape hatch for the curious.
Inputs: address (required), length. Returns: result
read_noteC
Read one of your notes.
Inputs: title (required), folder. Returns: result
save_stateA
Snapshot the entire game to a named save state. Save before risky fights and at milestones.
Inputs: name (required). Returns: result
search_notesB
Full-text search across your vault. Check here before re-exploring anything.
Inputs: query (required). Returns: result
set_goalB
Add an objective to your persistent goal list (survives compaction and new chats).
Inputs: text (required). Returns: result
start_gameA
Summon YOUR game window. Nothing opens until you call this, so opening the app spawns no windows — call this when you're ready to play, then take a screenshot. Safe to call again; it won't open a second window.
Inputs: no named parameters. Returns: result
waitA
Let the game run for N frames (60 = 1 second) — for dialogs, animations, evolutions.
Inputs: frames. Returns: result
write_noteB
Write (or overwrite) a markdown note in your vault. This is your permanent memory — it survives compaction and new conversations. Use [[wiki links]] freely.
Inputs: title (required), content (required), folder. Returns: result
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 19 tools
Each tool targets a clear resource+action (notes vs. goals vs. save states vs. game input), and the descriptions explicitly steer the agent (e.g. prefer read_game_state over get_screenshot when RAM facts suffice, read_memory as an 'escape hatch'). Minor overlap remains: press_buttons reports a 'one-line state summary' while read_game_state provides the fuller state report, so an agent could occasionally pick either for a status check.
Almost everything follows a predictable snake_case verb_noun pattern (set_goal, write_note, save_state, list_notes, read_memory). The deviations are few but noticeable: current_goals is a noun phrase that breaks from its siblings set_goal/complete_goal (would read better as list_goals), and wait is a bare verb with no noun.
19 tools is slightly above the comfortable range, but the surface spans four coherent sub-domains (game control, RAM introspection, persistent notes, goals, save states) and nearly every tool has a defensible job. Nothing here looks like filler, though a couple of items (list_states vs. list_notes vs. current_goals) add up to a heavier surface than strictly necessary.
Core lifecycles are covered: notes have create/overwrite/append/read/list/search, save states have save/load/list, goals have add/complete/list, and game control has start/close/press/wait/state/SRAM read. The gaps are deletions — there is no delete_note, no drop/delete save state, and no way to remove a stale goal other than marking it complete, which will leave clutter an agent cannot clean up.
Maintenance
Related MCP Connectors
Persistent memory layer for AI tools. Save and recall notes across Claude and other MCP clients.
MCP-native notes and memory for ChatGPT, Claude, and other AI tools.
Shared Markdown notes for MCP-compatible AI tools.
Notes, tasks, habits, journal and 6 more tools Claude can read and change, with undo. Free.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceProvides Claude with read, search, and write access to an Obsidian vault through MCP tools.-
- AlicenseNot gradedqualityCmaintenanceEnables Claude to read, write, and search markdown notes stored in a private git repo via an MCP server integrated with Silverbullet editor.MIT
- FlicenseNot gradedqualityAmaintenanceEnables Claude and other MCP-compatible clients to create, link, tag, search, and update atomic notes stored as Markdown files, building a bidirectional knowledge graph with semantic relationships. Also supports exploring and synthesizing that graph through tools that surface linked, similar, central, and orphaned notes.-
- FlicenseNot gradedqualityAmaintenanceEnables Claude and other MCP-compatible clients to create, link, search, explore, and synthesize atomic Markdown notes organized as a connected knowledge graph with tags and semantic relationships.-