Pokémon Red and Blue (PokemonRedAndBlueRecomp)
Pokémon Red and Blue
OrigenGame Boy / Game Boy Color
TecnologíaRecompilación Estática (C/C++ nativo)
Disponible paraWindows
Ver proyecto oficialSobre el proyecto
Pokémon Edición Roja y Pokémon Edición Azul son dos videojuegos de rol desarrollados por Game Freak y publicados por Nintendo para su consola portátil Game Boy. Son las primeras entregas de la serie de videojuegos de la franquicia Pokémon. Los videojuegos fueron lanzados a la venta por primera vez en Japón durante 1996 y en Estados Unidos, Europa y Australia casi tres años después. Pokémon Amarillo, una versión especial, fue lanzada al mercado aproximadamente un año más tarde.
3 versiones de Pokémon Red and Blue
Estás viendo: Pokémon Red and Blue (PokemonRedAndBlueRecomp)
Información oficial del proyecto
PokemonRedAndBlueRecomp
A static recompilation of Pokemon Red and Pokemon Blue (Game Boy) for native PC.
This project uses gb-recompiled (forked from arcanite24/gb-recompiled) to translate the original Game Boy machine code into C, which is then compiled to a native x64 executable. The Game Boy's PPU, APU, and memory mapper are handled by the gb-recompiled runtime library.
Status
Early working prototype. The game is playable from the title screen through the Elite Four, but this is not a finished product.
- The game runs and is playable with both Red and Blue ROMs
- Some animations may lag or chug slightly (e.g., certain battle intro spirals)
- Minor visual glitches may occur in edge cases
- Code paths not yet discovered by the static analyzer will fall back to an interpreter — this works but is slower than recompiled code
- Audio works but may stutter briefly during animation-heavy scenes
- No link cable support
If you encounter a crash or a new interpreter fallback, please open an issue with the address logged to the console.
Extended Edition (Gen 2 Graft)
Alongside the faithful Stock build, there is an Extended build that
back-ports the full Johto Pokédex — 100 new Pokémon (#152–251) from
pret/pokecrystal into the Gen 1 engine,
bringing Red and Blue to the complete National Dex #1–251, plus a batch of
Gen 2 moves and the real Dark/Steel types. Sprites use native 48×48 back
sprites for the grafted mon (no blocky 2× upscale). All of this is produced by
editing decomp source (../PokemonYellowDecomp/inject_red.py injecting
pret/pokered) and reassembling a real ROM —
not by binary-patching a .gbc.
This gives a bifurcation of four packages — {Red, Blue} × {Stock, Extended}
— served by two recompiled exes (one per variant; each runs both games via CRC):
| Package | Exe | ROM |
|---|---|---|
Pokemon_Red_Stock | Pokemon_Red_Blue.exe | stock Red |
Pokemon_Blue_Stock | Pokemon_Red_Blue.exe | stock Blue |
Pokemon_Red_Extended | Pokemon_Red_Extended.exe | Gen 2 Red |
Pokemon_Blue_Extended | Pokemon_Red_Extended.exe | Gen 2 Blue |
Release Packaging
scripts/build.sh stock # recompile stock exe + package Red/Blue Stock zips
scripts/build.sh extended # inject Gen2, build both ROMs, recompile, package Extended zips
# or package an already-built variant directly:
scripts/package.sh <red|blue> <stock|extended> [version]
Each zip is self-contained (exe + auto-bundled runtime DLLs + rom.gb + rom.cfg
run.bat) and lands indist/(gitignored). The zips bundle a ROM, so they are private/personal artifacts — do not distribute.
Quick Start
Pre-built Release
- Download the latest release from the Releases page
- Extract the zip
- Run the bundled
.exe(orrun.bat) - Stock accepts either Pokemon Red or Blue (UE); Extended runs the bundled Gen 2 ROM
Building from Source
Requires MSYS2 MinGW64 toolchain, CMake 3.20+, Ninja, and SDL2.
git clone --recursive https://github.com/mstan/PokemonRedAndBlueRecomp
cd PokemonRedAndBlueRecomp
cp /path/to/your-pokemon-rom.gb roms/
./build.sh all # Full build (recompiler + code gen + compile)
./build.sh run # Build + launch
Build commands:
./build.sh all— Full rebuild (recompiler + regenerate + compile)./build.sh game— Incremental compile only./build.sh regen— Regenerate C code from ROM./build.sh bank 00 03— Regenerate + rebuild specific banks./build.sh run— Build + launch
Controls
| GB Button | Keyboard |
|---|---|
| D-Pad | Arrow keys |
| A | Z |
| B | X |
| Start | Enter |
| Select | Tab |
| Hotkey | Action |
|---|---|
| TAB (hold) | Turbo (fast-forward) |
How It Works
This is a static recompiler, not an emulator. The original SM83 (Game Boy CPU) machine code is translated to C at build time, then compiled to native x64. At runtime, the executable loads the original ROM file for its data (graphics, maps, text, Pokemon stats, etc.) while executing the recompiled native code.
Red and Blue share identical code layout — only data tables differ (Pokemon availability, title screen graphics, etc.). A single recompiled build accepts either ROM at runtime via CRC32 validation.
When the recompiler encounters a code path it didn't discover during static analysis, it falls back to an interpreter. These fallback addresses can be added to the configuration file (pokemon_red_blue.toml) to be included in the next build.
Project Structure
pokemon_red_blue.toml— Recompiler configuration (entry points, data regions, valid CRCs)build.sh— Build script (regen, compile, run)generated/— Auto-generated C code from the recompiler (not committed)gb-recompiled/— Framework submodule (mstan/gbrecompiled)INITIATIVE.md— Tracked rendering and audio improvement work
Credits
- arcanite24/gb-recompiled — The original static recompilation framework that this project is built on. All recompiler and runtime code is derived from this project.
- pret/pokered — The pokered disassembly project, used as a reference for entry points and symbol information.
Known Limitations
- Some animation-heavy scenes (e.g., certain battle intro effects) may experience frame drops
- Audio may stutter briefly during heavy rendering
- Undiscovered code paths fall back to interpreter (logged to console)
- No link cable or printer support
- Only tested with US/Europe ROM versions
Legal
This project does not include any Nintendo copyrighted material. You must provide your own legally obtained Pokemon Red or Blue ROM file. The generated C code is not committed to this repository.
<p align="center"> <sub><b>R.A.I.D. — Retro AI Development</b> · a Discord for AI-assisted retro reverse-engineering, decomp & recomp</sub> </p> <p align="center"> <a href="https://discord.gg/Ad9BwSzctP"><img src=".github/raid-discord.png" alt="Join the Retro AI Development (R.A.I.D.) Discord" width="200"></a> </p>

