Static recompilation of Dr. Mario (NES) for native PC. Built with the NESRecomp framework.
Status: Playable. Title screen, options menu, and gameplay are functional. 1-player mode tested through virus clearing. If you find a bug, please open an issue.
Function coverage and game logic analysis made possible by the dr-mario-disassembly by Nostaljipi.
- Title screen
- Options menu (level, speed, music type selection)
- 1-player gameplay with virus placement and pill dropping
- Palette and CHR bank switching (all 4 CHR ROM banks)
- Music playback (Fever, Chill, Off)
- Download
DrMarioNesRecomp-windows-x64.zipfrom Releases - Extract and run
DrMarioRecomp.exe - Select your Dr. Mario (USA) ROM when prompted — the path is saved for future launches
Controls are fully configurable via keybinds.ini, auto-generated next to the executable on first run.
| NES Button | Keyboard |
|---|---|
| D-Pad | Arrow keys |
| A | Z |
| B | X |
| Start | Enter |
| Select | Tab |
| NES Button | Keyboard |
|---|---|
| D-Pad | W / A / S / D |
| A | K |
| B | L |
| Start | \ |
| Select | Right Shift |
| Key | Action |
|---|---|
| F5 | Toggle turbo (fast-forward) |
| F6 | Save state → quicksave.sav |
| F7 | Load state |
| Escape | Quit |
Requires Visual Studio 2022 and CMake 3.20+.
git clone https://github.com/mstan/DrMarioNesRecomp
cd DrMarioNesRecomp
# Windows
setup.bat
# Linux / macOS
chmod +x setup.sh && ./setup.shThis clones nesrecomp at the exact
version pinned in nesrecomp.pin and links the Nestopia oracle core.
Then build:
cmake -S . -B build -G "Visual Studio 17 2022" -A x64
cmake --build build --config ReleasePlace your Dr. Mario (USA).nes ROM in the build directory or select it at runtime.
# Build the recompiler (one time)
cmake -S nesrecomp/recompiler -B nesrecomp/build/recompiler -G "Visual Studio 17 2022" -A x64
cmake --build nesrecomp/build/recompiler --config Release
# Generate C code from ROM
nesrecomp/build/recompiler/Release/NESRecomp.exe "Dr. Mario (USA).nes" --game game.toml
# Build the game
cmake --build build --config ReleaseThis is a static recompiler, not an emulator. The original 6502 machine code is translated to C at build time, then compiled to native x64. The NES PPU, APU, and mapper are simulated by the runner library.
game.toml— recompiler configuration (TOML format, inspired by N64Recomp)game.cfg— legacy configuration (same directives, text format)extras.c— game-specific hooks (CRC32 verification, debug server)generated/— auto-generated C code (do not edit manually)nesrecomp/— framework submodule (NESRecomp)keybinds.ini— auto-generated controller bindings (edit to customize)
| ROM | CRC32 | Status |
|---|---|---|
| Dr. Mario (USA) | 0x9735D267 |
Supported |
- 2-player mode is untested (keyboard controls for P2 are mapped but gameplay is unverified)
- Audio may sound slightly faster than original hardware in some configurations
- Level completion cutscenes and ending sequences are untested