How mstan/supermarioworldrecomp works
SuperMarioWorldRecomp is a native-C static recompile of Super Mario World: generated CPU-game logic runs against an emulated SNES hardware core, then host rendering and audio present the result. The main user journey is supplying a legal ROM, optionally selecting a mode or mod, and playing; co-op adds ROM patching and synchronized multiplayer. The README documents these product branches, while sampled source gives more detail on Falcon’s controller boundary. Framework internals and several listed subsystems were not sampled, so their internal links are omitted.
Main entry points: main.c Launcher and Boot · smw_falcon_plugin.c Falcon Mod Activation · funcs.h Recompiled Game Logic · foreign_controller.c Foreign Controller Registry
Components 21
Game Runtime
- Launcher and Boot
src/main.c - Runtime Settings
src/config.c - Recompiled Game Logic
recomp/funcs.h - SNES Hardware Core
- Gamepad Input
src/main.c
Play Modes
- Co-op ROM Patch
src/coop_patch.c - Netplay Lobby
src/smw_netplay_lobby.c
Falcon Mod
- Foreign Controller Registry
src/foreign_controller.c - Falcon Mod Activation
src/mods/smw_falcon_plugin.c - Falcon Movement
src/mods/falcon/captain_falcon_controller.c - SMW Falcon Adapter
overrides/falcon/falcon_smw_adapter.c - Falcon Presentation
src/mods/falcon/smw_falcon_presentation_runtime.c
Host Presentation
- Adaptive Renderer
src/smw_renderer.c - Renderer Hooks
src/smw_renderer_hooks.c - SPC Audio Playback
src/smw_spc_player.c
Optional Integrations
- Lua Fire Stream
src/lua_fire_stream.c - MSU-1 Audio Mod
src/mods/smw_msu1_plugin.c
Other components
- Player
- SMW ROM
- Lobby Service
- Smash Bros. ROM
Connections 22
- Player → Launcher and Boot: starts game
README.md - SMW ROM → Launcher and Boot: loads ROM
README.md - Launcher and Boot → Runtime Settings: reads settings
src/main.c - Launcher and Boot → Recompiled Game Logic: runs gameplay
README.md - Recompiled Game Logic → SNES Hardware Core: uses hardware emulation
README.md - Launcher and Boot → Co-op ROM Patch: prepares co-op ROM
README.md - Co-op ROM Patch → SMW ROM: patches stock ROM
README.md - Launcher and Boot → Netplay Lobby: opens lobby
README.md - Netplay Lobby → Lobby Service: publishes room
README.md - Player → Gamepad Input: provides controls
README.md - Launcher and Boot → Falcon Mod Activation: activates mod
src/main.c - Falcon Mod Activation → Smash Bros. ROM: resolves assets
src/mods/smw_falcon_plugin.c - Falcon Mod Activation → Falcon Presentation: activates presentation
src/mods/smw_falcon_plugin.c - Falcon Mod Activation → Foreign Controller Registry: selects controller
src/mods/smw_falcon_plugin.c - Foreign Controller Registry → Falcon Movement: registers controller
- SMW Falcon Adapter → Foreign Controller Registry: ticks movement
overrides/falcon/falcon_smw_adapter.c - SMW Falcon Adapter → Recompiled Game Logic: hooks physics
- Launcher and Boot → Adaptive Renderer: initializes renderer
src/main.c - Renderer Hooks → Recompiled Game Logic: hooks rendering
README.md - Launcher and Boot → SPC Audio Playback: initializes audio
src/main.c - Launcher and Boot → Lua Fire Stream: enables scripting
README.md - Launcher and Boot → MSU-1 Audio Mod: loads optional mod
README.md