This page contains notes for the game Medarot 3.
Debug Menu#
Accessed by setting RAM address C480 to 31 and C481 to 00.
Text Debug#
Accessed by selecting メッセージチェック (the 14th option from the top of the list). RAM addresses:
- C740: Cursor position
- C741: オート -- If set to 1, the text index increments after the previous string is printed.
- C742: BANK -- This is an index to a table of ROM banks, starting at ROM offset 0:20A9. The value in the table determines the bank of the text string. This also references a pointer table starting at ROM offset 0:20D8. This value can reach up to 0x1B.
- C743: NOH -- The high byte of the text index.
- C744: NOL -- The low byte of the text index. (These bytes together can be viewed as a 16-bit value.)
To determine the text string being printed:
- Use the BANK value to lookup a table from ROM offset 0:20A9 to determine the ROM bank of the text. For example, if this value is 03, look up the value from 0:20A9 + 03 = 0:20AC. This value in a retail ROM is 79, which is the ROM bank where the text string will be printed.
- For the pointer, a master pointer table exists starting at ROM offset 0:20D8. Use the BANK value and multiply it by 2 to get the pointer. Pointers are little endian. For example, if this value is 03, look up the value from 0:20D8 + 03 * 02 = 0:20DE. The little endian value is at 4000.
- The pointer table for the text therefore starts at 79:4000 (or 1E4000). For the index, the formula is (NOH * 100 + NOL) * 2. For example, if the NOH value is 00, and the NOL value is 02, the pointer is 79:4000 + (00 * 100 + 02) * 02 = 79:4004. For a retail Kabuto ROM, the value for this little endian pointer is 4067, which resolves to ROM offset 79:4067 or 1E4067. For a retail Kuwagata ROM, the value for this little endian pointer is 4077, which resolves to ROM offset 79:4077 or 1E4077.
With this debug feature, banks between 76 to 91 (inclusive) can be accessed.
Any strings that have custom names, such as the player's name or a Medabot's name, appear to ignore what the user entered and use preset strings instead.
Note that there is no safeguard for invalid strings, and a glitched string can cause the game to hang.