Debug Mode
Retail cartridges of Golden Sun: The Broken Seal still contain Camelot's built-in developer toolkit behind a single global flag, along with ten test rooms across three scene overlays.
How DebugMode is gated
Inside syInit() in games/tbs/src/system/system_start_up.c, boot code clears
one global byte before the main routine starts:
DebugMode = 0;No normal gameplay path ever sets DebugMode to a non-zero value; only an
unreachable sprite viewer writes to it. When DebugMode is non-zero in memory,
the retail cartridge activates Camelot's developer hooks across the field
engine, the battle engine, and the sound driver:
- Scene selector (
Start + Bon the field): Lists all 201 scenes by internal code (SPWV00,PLOGV00,WORLD,TITLE,GET_ITEM,MENU) and entrance ID (mnDebugSceneSelectRuninwindow/screens_debug.c). - 4,096-flag editor (
Select + Bon the field): Inspects and toggles every bit inGameFlags(mnDebugFlagEditorRuninwindow/screens_debug.c). - Live palette editor (
Start + Lon the field): Edits GBA hardware palettes directly (fdPaletteEditorRuninfield/field_engine_palette_editor.c). - Movement and timing tools: Walk-through-walls (
L), single-tick freeze and step (Start + SelectviaDebugPaused), cutscene fast-forward, battle instant victory, an enemy status inspector, a sound test, and 10 test rooms.
Code reference
- Debug mode & test rooms (
games/tbs/src/debug/): FullDebugModeshortcut table, cheats, and the three debug overlays (test_scenes.c,level.c, andtest.c).