The developer menu
The game is built from scenes: the title, the story map, the real-time map, the battle, Team Make Up and the movie player. Scene -1 is a developers’ menu: a plain list of sixteen rows, each with a number you can change. A starts the row with that number: any of the 20 arenas, any map, any cut-scene, any sound or piece of music, or the memory card screens.
- Where
- scene -1; main.dol 0x8008F6FC (file offset 0x8C17C)
- Reachable in the retail game
- No; nothing switches to it
- Works
- Yes, every row runs; arena 19 hangs the game
- Rows
- 16
- Boot change
- 1 instruction, 2 bytes
- Tested in Dolphin
- Yes, all three methods below
- Tested on a real console
- Not yetUnconfirmed
- Files
- 14 · 46 MB
Images
- Screenshots
PREVIEW, arena 3, fresh start1280 × 960 · 3.5 MB
PREVIEW, arena 6 at night, after ROUTE set up the armies1280 × 960 · 3.5 MB
BATTLE on a fresh start1280 × 960 · 3.5 MB
Every monster has 0 HP, so the battle goes straight to its results
BATTLE after ROUTE1280 × 960 · 3.5 MB
WORLD-MAP1280 × 960 · 3.5 MB
TITLE1280 × 960 · 3.5 MB
MOVIE 0, the opening movie1280 × 960 · 3.5 MB
TEAM-EDIT1280 × 960 · 3.5 MB
CHALLENGE1280 × 960 · 3.5 MB
LOAD, with an empty memory card1280 × 960 · 3.5 MB
SAVE1280 × 960 · 3.5 MB
EVENT 2, a cut-scene played over the menu1280 × 960 · 3.5 MB
Other files
| File | What it is | Size | Actions |
|---|---|---|---|
| debug-menu-rows.md | Every row, its range and what A does | 4 KB | Open |
The rows
The sixteen rows are PREVIEW, TEAM-EDIT, CHALLENGE, BATTLE, ROUTE, WORLD-MAP, LOCAL-MAP, TIME, TITLE, EVENT, MOVIE, AUTOBLUR, SOFTFOCUS, SE&BGM, LOAD and SAVE. The menu also has a scene of its own, PREVIEW (row 0). The row names are still in the English text bank (messages 5-20), and the menu’s data keeps the original Japanese names too (listed in debug-menu-rows.md).
| Row | Name | Range | What A does |
|---|---|---|---|
| 0 | PREVIEW | Arena, 0-19 | Shows the arena with both armies’ monsters standing in it, at the time of day of row 7, with a fixed camera. Nothing else runs and nothing leaves it. AUTOBLUR applies here. Arena 19 hangs the game (below). |
| 1 | TEAM-EDIT | Menu argument, 0-1 | Opens Team Make Up. |
| 2 | CHALLENGE | Level, 0-5 | Starts challenge mode; the level picks the bonus skill card and, at 5, the bosses’ music. |
| 3 | BATTLE | Arena, 0-19 | Starts a battle in that arena at the time of day of row 7. Y and X set the player’s and the enemy’s army slot to the same number. On a fresh start every monster has 0 HP and the battle ends at once. Arena 19 hangs the game. |
| 4 | ROUTE | Story, 0-2 (Yugi, Kaiba, Joey) | Selects the story. A sets up the player’s armies for the current mission: every marshal of the mission (all ten with R held, or when the mission names none) gets its start units and an army slot. A also sets TIME back to 0. |
| 5 | WORLD-MAP | Mission, 0-22 | Selects the mission (rejected above the story’s count); A sets up the armies as above and opens the story map (the hub). |
| 6 | LOCAL-MAP | Stage, 0-29 | Sets up the armies as above and opens that stage’s map with the developers’ mission script dbg.lsc, which is not on the disc. The map starts with 5,730 gold and a time limit of 1,000 ticks. Because A sets TIME back to 0, the map always starts at 7:00. |
| 7 | TIME | Time of day, 0-3 | 0 day, 1 evening, 2 night, for PREVIEW and BATTLE. 3 lights them as 0. The map code would start a LOCAL-MAP map at 12:00 in a viewing mode of its own with 3, but no row can pass it on (row 6). |
| 8 | TITLE | Argument, 0-1 (default 1) | Opens the title: 1 as at boot, 0 straight to the title screen with its jingle. |
| 9 | EVENT | Cut-scene, 0-99 | Plays that cut-scene over the menu. |
| 10 | MOVIE | Movie, 0-2 | Opens the movie viewer, looped; START returns. Only movie 0 (the opening movie) exists; 1 and 2 show an empty viewer. |
| 11 | AUTOBLUR | Level, 0-6 | Motion-trail overlay for PREVIEW and battles (the previous frame drawn over the new one). |
| 12 | SOFTFOCUS | On/off, 0-1 | Every frame ends with a half-strength copy of the screen drawn over it. |
| 13 | SE&BGM | Sound id (hex), 0-0xFFFF (default 0x9000) | A plays the sound or music id, B plays 0x1000, Y loads the common sound bank 0xBC. |
| 14 | LOAD | Unused value, 0-99 | Memory card load screen; a load copies the save’s story and mission into rows 4 and 5. |
| 15 | SAVE | Unused value, 0-99 | Memory card save screen. |
Arena 19 hangs the game
Arena 19 has no scenery, and its camera table allows no camera position at all. When a battle starts, the camera set-up steps a random number of places through that table and waits each time for an allowed position, which never comes, so PREVIEW and BATTLE with arena 19 freeze the game, unless both random step counts come out 0. Nothing in normal play picks arena 19; only these two rows can.
The map’s viewing mode
TIME 3 belongs to a map mode that nothing can reach. A map opened without a story (LOCAL-MAP is the only way) checks TIME when it starts. With 3 it would start at 12:00 in a mode of its own:
- the clock stands still, and the three HUD icons at the bottom of the screen fade out;
- no battle can start, because the step that stages engagements is skipped;
- the main stick is not read, only the C-stick and the triggers;
- A on one of your own units sends it walking to a random point of the map, and A again stops it.
So the mode shows the map with units wandering about, probably for looking at the map or for pictures. LOCAL-MAP sets TIME back to 0 before it opens the map, so the mode never starts.
The rows are the game’s own settings
The sixteen values are not the menu’s alone. The retail game passes its own scene arguments through them: the story map writes the stage into LOCAL-MAP’s value before it opens a map, a map battle writes the arena into BATTLE’s and the time of day into TIME’s, the title writes the challenge level into CHALLENGE’s, and 53 of the attack effect modules read BATTLE’s value to learn the arena. The menu only lets a person set them by hand.
Why you never see it
Nothing in the retail game switches to scene -1. Every scene change in the code names a fixed scene (1, 2, 3, 5, 6 or 8). There is no button combination, save flag or console-type check. The start of the game is one call that switches to scene 8, the title:
0x8008F6FC li r3, 8 38 60 00 08 scene_switch(8, 0): the title
The development build probably switched to -1 there. Changing that one instruction to li r3, -1 starts the game in the menu, and the menu then works as the root of everything: each row’s scene returns to it when it ends. Nothing in the menu leaves it (START does nothing there), which fits a screen that was the root.
Opening it on your own disc
Three ways to make the same 2-byte change:
# Dolphin patch (game Properties > Patches)
0x8008F6FC:dword:0x3860FFFF
# Gecko code
0408F6FC 3860FFFF
# main.dol in a hex editor: file offset 0x8C17C
38 60 00 08 -> 38 60 FF FF
All three were tested in Dolphin and boot straight into the menu. They have not yet been tried on a real console; reports are welcome. If Dolphin says it failed to verify the code, RetroAchievements hardcore mode is on: it blocks codes that are not on Dolphin’s approved list, so turn it off (Tools > Achievements > Settings) to use them.
Some rows need set-up first: on a fresh start every monster has 0 HP, so use ROUTE (row 4) before BATTLE or PREVIEW to give the armies their units. LOCAL-MAP loads a test mission that is missing from the disc (dbg.lsc). The full table of rows, ranges and controls is in debug-menu-rows.md above.
Evidence
The menu’s update and drawing code was decompiled and every row was run from it. The places that write the current scene were all found (the scene switch, the three scene request functions and the start-up), and every caller passes a constant except the menu itself. The boot call at 0x8008F6FC is in game_init; its file offset in main.dol follows from the DOL’s section table.