Pokémon Red and Blue/Debug Functions
This is a sub-page of Pokémon Red and Blue.
"Battle Test" Function
Check whether the code exists in non-English translations. It seems to have been removed in Yellow, but it could still exist in an altered form.
This unusual functionality may have been used for debugging purposes. It can be accessed by running the code at 01:4DA6, which requires a bank switch to be performed using the bank switch function at $35D6. This sets the bank to whatever register b is, and jumps to hl.
Once accessed, the following occurs:
- The "badges" value is set to $80, which gives you the Earth Badge and nothing else.
- Your current location is set to Pallet Town.
- Your current party Pokémon are removed.
- You are prompted to nickname a level 20 Rhydon. Regardless of whether you give it a nickname...
- A battle against another level 20 Rhydon will commence.
- All four of your moves act like Pound, though this doesn't apply to the opposing Rhydon.
- Whatever the outcome of the battle, once the fight is over, the nickname prompt appears again, and the entire process repeats.
According to an interview with Ken Sugimori, Rhydon was the first Pokémon ever created, which may be why Rhydons are used in this battle.
The same setup also exists in Pokémon Red (J) and Green, at 01:4B8D, where it appears to work in an identical manner. (Refer to this post for the location of the bank switch function in other regions & revisions.)
Corrupted Cable Club Data
During a Cable Club session, Red & Green 1.0 check if either player's name starts with character ID 60 (a bold Ａ). If so, a message about data corruption appears on the 「つうしんじゅんびちゅう！」 ("PLEASE WAIT!") screen, which is seemingly looped indefinitely if both versions are v1.0.
ld a, [wPlayerName] cp $60 jr nz, .playerDataNotCorrupted ld de, OneselfString jr .corrupted .playerDataNotCorrupted ld a, [wLinkEnemyTrainerName] cp $60 jr nz, .parterDataNotCorrupted ld de, PartnerString .corrupted call CopyStringToCF4B ld hl, DataCorruptedString call PrintText jr @ ; spin
If both players' names start with character ID 60, they see the following message:
|じぶんの データが こわれています！||My data is corrupted!|
If only one player has their name started by character ID 60, then player 1 receives the previous message while player 2 gets this one instead:
|あいての データが こわれています！||Partner's data is corrupted!|
However, the continuation of these messages isn't displayed under any conditions:
|でんげんを きって やリなおしてください。||Please turn off the power and try again.|
As there is no obvious reason for this check to be performed, it was removed for Red & Green 1.1, Japanese Blue & Yellow, and the games' localizations.
Attempting to connect Red & Green 1.0 with Red & Green 1.1 or Japanese Blue & Yellow via the Cable Club may cause the games to behave unusually. For example, at the Trade Center with 1.1 as the game with the bad name linked with a 1.0 with an ordinary name, the newer game may proceed to the trade menu while the older game is stuck at 'Waiting...', and making an action such as trading a Pokémon can bring up a glitched Pokémon list for the other side which may badly affect the memory.
To get an Ａ as the first character in your name simply use the GameShark code 01601DD1. To do it without a cheating device, execute arbitrary code execution (e.g. with the "てへ" hex:7B glitch item), such as with items Lemonade x96 Carbos x209 X Accuracy x29 Water Stone x201 which will change D11D to 60, or obtain it without arbitrary code execution using "Super Glitch" with some very specific requirements.
Setting bit 1 of RAM address D732 enables a debug mode with the following features:
- When starting a new game, most of Oak's intro speech is skipped, including the player and rival name selections. This results in the player and rival's names being automatically set to the version's defaults. (See the chart below.)
- The player begins the game outside their house, rather than inside their bedroom.
- Holding the B button prevents wild Pokémon encounters.
The RAM address can be set using the GameShark code 010332D7. However, this code also changes other, unrelated bits of the same address, causing incidental side effects, such as not forcing the player to use a bicycle on Cycling Road, and incorrectly-functioning warps.
Default Names by Version:
|Named for Wataru Yamaguchi, listed in the games' credits under "Special Thanks", and Tsunekazu Ishihara, a Pokémon developer.|
|Blue (J)|| ゲーフリ
|Named for Game Freak and Creatures Inc., two of the companies that worked on Pokémon.|
|Yellow (J)|| ゲーフリ1
|Same as above, with the exception of a "1" added to the player's name.|
|NINTEN||SONY||A tongue-in-cheek reference to the rivalry between Nintendo and Sony.|
|Yellow (U)||NINTEN||SONY||Same as above.|
Error code messages are displayed when a 00 character appears in the middle of a text string. When an error message is printed on the screen, all text after the 00 character is ignored. The messages' formatting differs between versions:
- Red & Blue: "[x] ERROR."
- Yellow: "[x] error."
[x] is a number that represents the identifier of the text string. However, it is possible for other text, including numbers, to precede the error code, which can potentially result in confusing messages. Take "54 error," for example, which could be read as both "5[4 error]" and "[54 error]".
You can cause an error code to appear by using the Trainer-Fly glitch in the English versions of Pokémon Red and Blue.
- Flee from the long-range trainer on Route 6.
- Re-enable the start menu using a Trainer in another location.
- Read the PokéMart sign in Vermilion City and return to Route 6.
An error message reading "9 ERROR" will now appear, as seen in the picture at right. This is because Vermilion's PokéMart sign has a text identifier of 09, stored at the memory address CF13, and the game is attempting to load the last text box ID in memory. There is no such corresponding text for Route 6, and the information at that address is, presumably, a single 00 character, so the game prints a "9 ERROR."
The PokéMart sign in Yellow, meanwhile, has a text identifier of 0B, which, coincidentally, does not result in an error message. However, the sign that says "VERMILION CITY - The Port of Exquisite Sunsets" has an identifier of 08, so reading it and returning to Route 6 will bring up an "8 ERROR."
Gift Pokémon Function
In Japanese Red and Green, an unused function exists that adds three Pokémon to the player's party:
|Red (J) 1.0||01:645C|
|Red (J) 1.1||01:6401|
- Exeggutor (Level 90)
- Ekans (Level 90)
- Rhydon (Level 5)
In Japanese Blue, the function adds three slightly different party members:
- Exeggutor (Level 90)
- Chansey (Level 100)
- Rhydon (Level 5)
In English Red and Blue, the function adds five Pokémon:
|Red & Blue (U)||01:64CA|
- Exeggutor (Level 90)
- Mew (Level 20)
- Jolteon (Level 56)
- Dugtrio (Level 56)
- Articuno (Level 57)
In a 2000 ABC News interview with Pokémon developer Tsunekazu Ishihara, he states that Exeggutor is his favourite Pokémon, since he used it while debugging the game. This may explain the inclusion of Exeggutor.