Added HGSS commands MD as test

This commit is contained in:
Miguel Terol Espino 2024-03-03 20:50:31 +01:00 committed by Mixone-FinallyHere
parent 1f759ef0f7
commit e37bc952e7
3 changed files with 861 additions and 0 deletions

View File

@ -436,6 +436,7 @@
<DependentUpon>Settings.settings</DependentUpon>
<DesignTimeSharedInput>True</DesignTimeSharedInput>
</Compile>
<None Include="Resources\HGSSCommands.md" />
<None Include="Resources\ROMToolboxDB\CPUE_cam.bin" />
<None Include="Resources\ROMToolboxDB\CPUS_cam.bin" />
<None Include="Resources\ROMToolboxDB\IPGE_cam.bin" />

View File

@ -29,7 +29,10 @@ using System.ComponentModel;
using DSPRE.Editors;
namespace DSPRE {
public partial class MainProgram : Form {
public MainProgram() {
InitializeComponent();
EditorPanels.Initialize(this);

View File

@ -0,0 +1,857 @@
Outer pipes Cell padding
No sorting
| | SDSME names | New proposed names | Parameters | Function | Notes |
| ---- | -------------------------- | ---------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| 0000 | Nop | Nop | \- | Nothing | |
| 0001 | Nop1 | Dummy | \- | Nothing | Has exactly the same ASM code as Nop. |
| 0002 | End | End | \- | End script execution | |
| 0003 | Return2 | WaitTime | u16: Time; Var: ??? | Stop script execution for Time frames | The Var's purpose is unknown. Command uses ScrReg 0 as countdown. |
| 0004 | | RegValueSet | u8: Script Register; u8: Value | Assigns Value to Script Register value | |
| 0005 | | RegDataSet | u8: Script Register; u32: Value | Assigns Value to Script Register value | |
| 0006 | | RegAdrsSet | u8: Script Register; u32: Address | Assigns data in Address offset to Script Register value | |
| 0007 | | AdrsValueSet | u32: Address; u8: Value | Assigns Value to the Address offset | |
| 0008 | | AdrsRegSet | u32: Address; u8: Script Register | Assigns Script Register value to the Address offset | |
| 0009 | | RegRegSet | u8: Script Register 1; u8: Script Register 2 | Assigns Script Register 2 value to Script Register 1 value | |
| 000A | | AdrsAdrsSet | u32: Address 1; u32: Address 2 | Assigns data in Address 2 to the Address 1 offset | |
| 000B | | CompareRegs | u8: Script Register; u8: Script Register | Compares two Script Register | |
| 000C | | CompareRegValue | u8: Script Register; u8: Value | Compares Script Register value with Value | |
| 000D | | CompareRegAdrs | u8: Script Register; u32: Address | Compares Script Register value with data in Address | |
| 000E | | CompareAdrsReg | u32: Address; u8: Script Register | Compares data in Address with Script Register value | |
| 000F | | CompareAdrsValue | u32: Address; u8: Value | Compares data in Address with Value | |
| 0010 | | CompareAdrsAdrs | u32: Address 1; u32: Address 2 | Compares data in Address 1 with data in Address 2 | |
| 0011 | If | CompareVarValue | Var: Variable; u16: Value | Compares Variable value with Value | |
| 0012 | If2 | CompareVars | Var: Variable 1; Var: Variable 2 | Compares Variable 1 value with Variable 2 value | |
| 0013 | | ParallelCommonScript | u16: ??? | ??? | Somehow related with parallel common script execution. |
| 0014 | CallStandard | CommonScript | u16: Global Script ID | Calls Global Script ID script | The Common Script table is located at 0xFA48C in IPKS arm9.bin, ordered from highest to lowest with structure: u16 Global Script ID | u16 Script file | u16 Text file. The executed script inside script file is determined as: used Global Script ID \- tabulated Global Script ID. |
| 0015 | | LocalScript | \- | Returns to the invoking script/function after a Common Script | |
| 0016 | Jump | Jump | u32: Relative Jump | Jumps to a function, Relative Jump bytes forward or backward | Relative Jump can have negative values (backward jump). |
| 0017 | | JumpIfObjID | u8: Event ID; u32: Relative Jump | Jumps to a function, Relative Jump bytes forward or backward, if invoking event has Event ID as ID | |
| 0018 | | JumpIfBgID | u8: ???; u32: Relative Jump | ??? | Maybe jumps to a function if invoking event has a specific ID. |
| 0019 | | JumpIfPlayerDir | u8: Player Direction; u32: Relative Jump | Jumps to a function, Relative Jump bytes forward or backward, if player is looking in Player Direction | Supposed. Needs to be tested in game. |
| 001A | Call | Call | u32: Relative Jump | Calls a function, Relative Jump bytes forward or backward | Can be used to make loops when calling the own invoking function. |
| 001B | Return | Return | \- | Returns to the invoking script/function after a Call | |
| 001C | CompareLastResultJump | JumpIf | u8: Condition; u32: Relative Jump | If Condition in the condition table, jumps to a function | Ask AdAstra for the condition list. Condition table is updated after a IfVarValue, IfVarVar, CheckFlag... |
| 001D | CompareLastResultCall | CallIf | u8: Condition; u32: Relative Jump | If Condition in the condition table, calls a function | |
| 001E | SetFlag | SetFlag | u16: Flag | Sets Flag to 1 | |
| 001F | ClearFlag | ClearFlag | u16: Flag | Sets Flag to 0 | |
| 0020 | CheckFlag | CheckFlag | u16: Flag | Checks if Flag is set | It updates the internal condition flag and maybe part of the condition table. |
| 0021 | | SetFlagFromVar | Var: Flag | Sets the flag whose ID is stored in Flag | |
| 0022 | | ClearFlagFromVar | Var: Flag | Clears the flag whose ID is stored in Flag | |
| 0023 | | FlagStatusToVar | Var: Flag; Var: Variable | Checks if Flag is set and store the result in Variable | |
| 0024 | | SetTrainerFlag | Flex: Trainer ID | Sets the flag of Trainer ID, so marks it as beaten trainer | So this trainer will not battle against you. Used in every Gym after the leader is beaten. |
| 0025 | | ClearTrainerFlag | Flex: Trainer ID | Clears the flag of Trainer ID, so marks it as unbeaten trainer | So this trainer can be challenged again. |
| 0026 | | CheckTrainerFlag | Flex: Trainer ID | Checks if Trainer ID has been beaten | It updates the internal condition flag and maybe part of the condition table. |
| 0027 | Copy | IncrementVar | Var: Variable; Flex: Operand | Stores the operation Variable \+ Operand in Variable | |
| 0028 | | DecrementVar | Var: Variable; Flex: Operand | Stores the operation Variable \- Operand in Variable | |
| 0029 | SetVar | SetVar | Var: Variable; u16: Value | Stores Value in Variable | |
| 002A | CopyVar | SetVarFromVariable | Var: Variable 1; Var: Variable 2 | Assigns value of Variable 2 to Variable 1 | |
| 002B | | SetVarFromFlexible | Var: Variable; Flex: Flexible Value | Stores Flexible Value (or its value if variable) in Variable | |
| 002C | | MessageAll | u8: Text Slot | Display line Text Slot from the text file, all at once | |
| 002D | Message | Message | u8: Text Slot | Display line Text Slot from the text file | |
| 002E | Message2 | MessageFlex | Flex: Text Slot | Display line Text Slot from the text file | Unlike 002D, this command also accepts a variable as the input field. |
| 002F | | MessageNoSkip | Flex: Text Slot | ??? | |
| 0030 | | | u8: Text Slot | ??? | |
| 0031 | | WaitAB | \- | Waits for button A or button B to be pressed | Somehow it uses ScrReg 0 as countdown. |
| 0032 | WaitButton | WaitButton | \- | Waits for a button to be pressed | It seems only A, B, X and direction pad buttons work. |
| 0033 | | WaitABPad | \- | Waits for button A, button B or pad buttons to be pressed | Supposed. Needs to be tested in game. |
| 0034 | | OpenMessage | \- | ??? | |
| 0035 | CloseMessageOnKeyPress | CloseMessage | \- | Closes message box | SDSME name is misleading, for no button is needed to be pressed. |
| 0036 | FreezeMessageBox | FreezeMessage | \- | ??? | Probably keeps the message box alive after a script. ASM differs with CloseMessage only in a BL instruction. |
| 0037 | CallMessageBox | SetIconBoard | u8: Text Slot; u8: Type; u16: Icon; u16: ??? | Prepares an icon board message box displaying Text Slot message, of Type type, and with Icon image if chosen type supports it | Type values from 0 to 3 are: brown (with icon), green (with icon), gray and blue. |
| 0038 | ColorMessageBox | SetTextBoard | u8: Type; u16: Icon | Prepares a text board message box of Type type, and with Icon image if chosen type supports it | Type values from 0 to 3 are: brown (with icon), green (with icon), gray and blue. |
| 0039 | TypeMessageBox | ShowBoard | u8: Process | Triggers different Process processes for the board | Process value 0 keeps the board, value 1 creates the board, value 2 hides the board, value 3 shows the board and value 4 deletes the board. |
| 003A | NoMapMessageBox | WaitBoard | \- | Waits the board last process to end | Supposed. |
| 003B | | BoardMessage | u8: Text Slot; u16: Variable | Displays Text Slot message in the current text box, stores the current text box status in Variable | |
| 003C | | CloseBoard | Var: Variable | Returns 1 to Variable if the player has pressed a button so the board must close, 0 otherwise | Variable is stored in ScrReg 0. Command waits for a button to be pressed and stores result in Variable. |
| 003D | | Menu | \- | | |
| 003E | | | u8: ???; u8: ???; u8: ???; u8: ???; u8: ???; u8: ??? | | |
| 003F | | YesNoBox | Var: Variable | Opens a Yes-No dialog and stores user response in Variable | Variable is stored in ScrReg 0. |
| 0040 | Multi | MultiStandardText | u8: X; u8: Y; u8: Cursor; u8: Cancel; Var: Selection | Prepares a multiple selection menu at X and Y screen position, with Cursor default selected option and possibility of cancelling depending on Cancel, with text bank #321, returns selected slot ID in Selection | If Cancel is 1, the user can select the last option by pressing B button. |
| 0041 | Multi2 | MultiLocalText | u8: X; u8: Y; u8: Cursor; u8: Cancel; Var: Selection | Prepares a multiple selection menu at X and Y screen position, with Cursor default selected option and possibility of cancelling depending on Cancel, with local texts, returns selected slot ID in Selection | If Cancel is 1, the user can select the last option by pressing B button. |
| 0042 | TextScriptMulti | AddMultiOption | u8: Text Slot; u8: Multi Slot | Adds an option with Multi Slot ID showing Text Slot text | |
| 0043 | CloseMulti | ShowMulti | \- | Shows the prepared multi in screen | The game will hide it when the player has selected an option. |
| 0044 | Multi3 | ListStandardText | u8: X; u8: Y; u8: Cursor; u8: Cancel; Var: Selection | Prepares a multiple selection list at X and Y screen position, with Cursor default selected option and possibility of cancelling depending on Cancel, with text bank #321, returns selected slot ID in Selection | If Cancel is 1, the user can select the last option by pressing B button. The difference between a Multi and a List seems to be that lists are scrollable. |
| 0045 | | ListLocalText | u8: X; u8: Y; u8: Cursor; u8: Cancel; Var: Selection | Prepares a multiple selection list at X and Y screen position, with Cursor default selected option and possibility of cancelling depending on Cancel, with local texts, returns selected slot ID in Selection | If Cancel is 1, the user can select the last option by pressing B button. The difference between a Multi and a List seems to be that lists are scrollable. |
| 0046 | | AddListOption | Flex: Option MSG; Flex: Highlight MSG; Flex: List Slot | Adds a new option to the list, with List Slot ID and showing text line Option MSG. It also displays text line Highlight MSG when that option is highlighted. | If Highlight MSG is set to 255 [0xFF], no message will be displayed when the option is highlighted.<br>This command relies on an open message box in order to display the highlight messages.<br><br>Trying to highlight an option with Highlight MSG different than 255 [0xFF] will result in a crash if no message box is already being displayed. |
| 0047 | | ShowList | \- | Shows the prepared list in screen | The game will hide it when the player has selected an option. |
| 0048 | MultiRow | MultiColumn | u8: Columns | Splits the multi window in Columns different columns | |
| 0049 | PlayFanfare | PlayFanfare | Flex: Sound | Plays Sound | |
| 004A | PlayFanfare2 | StopFanfare | Flex: Sound | Stops Sound | |
| 004B | WaitFanfare | WaitFanfare | Flex: Sound | Waits Sound to finish | |
| 004C | PlayCry | PlayCry | Flex: Pokémon; Flex: Unused | Plays a Pokémon cry | |
| 004D | WaitCry | WaitCry | \- | Waits the current cry to finish | |
| 004E | PlaySound | PlaySound | u16: Sound | Pauses current music, then Plays Sound | |
| 004F | FadeDefaultMusic | WaitSound | \- | Waits for Sound to finish, then resumes music | |
| 0050 | PlayMusic | PlayMusic | u16: Music | Plays Music | |
| 0051 | StopMusic | StopMusic | u16: Unused | Stops current music | Parameter is ignored because the game identifies what music is playing. |
| 0052 | RestartMusic | PlayDefaultMusic | \- | Plays map default music | |
| 0053 | | SetMusic | u16: Music | ??? | |
| 0054 | SwitchMusic | FadeOutMusic | u16: Volume; u16: Time | Fades out the current music to Volume in Time frames | |
| 0055 | | FadeInMusic | u16: Time | Fades in the current music to normal volume in Time frames | |
| 0056 | | SetMusicPauseStatus \* | u8: SSEQ Player ID; u8: Status | ??? | |
| 0057 | | TempMusic \* | u16: Music ID | ??? | |
| 0058 | | SetBGMFlag \* | u8: ??? | ??? | Seems to set a flag related to the music system. |
| 0059 | | CheckChatotCry | Var: Variable | Checks if Chatot has custom sound, stores answer in Variable | Returns 0 or 1 to the specified Variable. Not for a specific Chatot but for all (they share a custom sound). |
| 005A | SwitchMusic2 | StartChatotCry | Var: Variable | Starts Chatot microphone record, stores answer in Variable | Returns 0 or 1 to the specified Variable depending on successful recording. |
| 005B | | StopChatotCry | \- | Stops recording Chatot custom sound | |
| 005C | | SaveChatotCry | \- | ??? | Maybe saves the custom Chatot sound in the savegame. |
| 005D | | | \- | ??? | |
| 005E | ApplyMovement | Movement | Flex: Event ID; u32: Relative Jump | Applies movement at Relative Jump to Event ID | Movements must be halfword-aligned in the script file. If you're using an old tool which doesn't align them, force the alignment with a TextPlayerName 0x0 or some unnoticeable command of 3, 5, 7 or 9 bytes length. |
| 005F | WaitMovement | WaitMovement | \- | Waits for all movements to finish | |
| 0060 | LockAll | LockAll | \- | Locks every event in the map | |
| 0061 | ReleaseAll | ReleaseAll | \- | Releases every event in the map | |
| 0062 | Lock | Lock | u16: Event ID | Locks Event ID | |
| 0063 | Release | Release | u16: Event ID | Releases Event ID | |
| 0064 | AddPeople | AddOW | Flex: Event ID | Add Event ID overworld in the map | It is probable that, if executing this having Event ID overworld already in the map, it gets duplicated. |
| 0065 | RemovePeople | RemoveOW | Flex: Event ID | Removes Event ID overworld from the map | |
| 0066 | LockCam | LockCamera | Flex: X; Flex: Y | Locks the camera at position X and Y | Seems to place a invisible NPC at coords X and Y. It appears that both must be the current player position. |
| 0067 | | ReleaseCamera | \- | Releases the camera | |
| 0068 | FacePlayer | FacePlayer | \- | Makes the invoking event look at the player | In fact it simply takes the current player direction and makes the NPC look at the opposite direction. |
| 0069 | CheckSpritePosition | GetPlayerPosition | Var: X; Var: Y | Saves the current player position in X and Y | |
| 006A | | GetOWPosition | Flex: Event ID; Var: X; Var: Y | Saves the current Event ID position in X and Y | If Event ID is deleted (via RemoveOW) it gives 0xFF for both coordinates. |
| 006B | CheckPersonPosition | SetFollowingOverworld \* | Flex: X; Flex: Z; Flex: Y | ??? | Maybe teleports the player to other coords? |
| 006C | ContinueFollow | KeepOverworld | Flex: Event ID; u8: Value | If Value is 1, prevents Event ID from disappearing when entering on a new map header | |
| 006D | FollowHero | SetOWMovement | Flex: Event ID; u16: Movement | Changes the Event ID's movement number to Movement | |
| 006E | GiveMoney | GiveMoney | u32: Money | Adds Money to the player's money | |
| 006F | TakeMoney | TakeMoney | u32: Money | Subtracts Money from the player's money | |
| 0070 | CheckMoney | CompareMoney | Var: Variable; u32: Money | Stores 1 into Variable if the player has Money or more money. Stores 0 otherwise. | |
| 0071 | ShowMoney | ShowMoney | Flex: X; Flex: Y | Shows the money box at X and Y coordinates of the screen | Each X and Y unit implies 8 pixels. Values of 0 or higher than the screen may glitch the screen. |
| 0072 | HideMoney | HideMoney | \- | Hides the money box | |
| 0073 | | UpdateMoney | \- | Updates the current money in the money box | |
| 0074 | | ShowSpecialCurrency | u8: Currency; Flex: X Coord; Flex: Y Coord | Shows the Currency box at X and Y coordinates of the screen. | Currency:<br><br>0 = Coins<br>1 = Battle Points<br>2 = Athlete Points |
| 0075 | | HideSpecialCurrency | \- | Hides the currently displayed special currency box. | |
| 0076 | | UpdateSpecialCurrency | u16: Currency | Updates the current Currency in the currency box. | Currency types are the same as above [0074]. |
| 0077 | | CheckCoins | Var: Variable | Stores the current casino coin amount in Variable | |
| 0078 | | GiveCoins | Flex: Coins | Adds Coins to the player's casino coins | |
| 0079 | | TakeCoins | Flex: Coins | Subtracts Coins from the player's casino coins | |
| 007A | | GiveAthletePoints | Flex: Amount | Adds the given Amount to the player's Athlete Points | |
| 007B | | TakeAthletePoints | Flex: Amount | Subtracts the given Amount from the player's Athlete Points | |
| 007C | | CompareAthletePoints | Var: Result; Flex: Amount | Stores 1 into Variable if the player has the given Amount of Athlete Points or more. Stores 0 otherwise. | |
| 007D | | GiveItem | Flex: Item; Flex: Amount; Var: Variable | Adds Amount of Item item, stores 1 in Variable if the player had less than 1000 - Amount (100 - Amount if TM/HM), stores 0 otherwise | Both Item and Amount are flexible, but if you use CommonScript 0x7F1 after that (as it is meant to be) you must place these two values in 0x8004 and 0x8005 in order to make the script work properly. |
| 007E | TakeItem | TakeItem | Flex: Item; Flex: Amount; Var: Variable | Subs Amount of Item item, stores 1 in Variable if the player had at least Amount items in the bag, stores 0 otherwise | |
| 007F | GiveItem | CheckItemSpace | Flex: Item; Flex: Amount; Var: Variable | Stores 1 in Variable if the player has less than 1000 - Amount of Item items (100 - Amount if TM/HM), stores 0 otherwise | |
| 0080 | CheckItem | CheckItem | Flex: Item; Flex: Amount; Var: Variable | Stores 1 in Variable if the player has at least Amount of Item items in the bag, stores 0 otherwise | Even if the Amount to check for is 0, the check will return 0 if you don't have the item at all. |
| 0081 | | CheckItemIsMachine | Flex: Item; Var: Variable | Stores 1 in Variable if Item is TM or HM, stores 0 otherwise | |
| 0082 | | GetItemPocket | Flex: Item; Var: Variable | Stores the bag pocket of Item in Variable | |
| 0083 | | SetStarter | Flex: Pokémon | Stores Pokémon as the starting Pokémon in the game save data | |
| 0084 | DoubleMessage | GenderMessage | u8: Male Text; u8: Female Text | Displays Male Text or Female Text message depending on player's gender | |
| 0085 | | CheckSeals \* | Flex: Seal ID; Var: Number of Seals in Seal Case | Checks the number of a certain type of Ball Seals that the player has. The variable is the output of how many Seals you have. | Example: Farmhouse on Route 39 |
| 0086 | | GiveSeals \* | Flex: Seal ID; Flex: Number of Seals to be Given | Gives the player Ball Seals. | Example: Farmhouse on Route 39 |
| 0087 | | GiveRandomSeals \* | Var: Random Seal ID 1; Var: Random Seal ID 2; Var: Random Seal ID 3 | Generates three random types of Ball Seals and gives them to the player (repeats are possible). Each variable will yield a 0 if the player has no more room for the Seal(s) in the Seal Case. | Example: House in top right of Olivine City |
| 0088 | | CheckPokemonForm \* | Flex: Party Position; Var: Variable | Checks the form of the Pokemon in party slot Party Position and returns the form ID in Variable. | |
| 0089 | GiveStoredPokemon | GivePokemon | Flex: Pokémon; Flex: Level; Flex: Item ID; Flex: Form; Flex: Ability; Var: Variable | Gives Pokémon at level Level, store 1 in Variable if succeed and 0 otherwise | |
| 008A | | GivePokemonEgg | Flex: Pokémon; Flex: Location | Gives a Pokémon egg received from Location text slot at text bank #281 | |
| 008B | | ReplaceMove | Flex: Party Slot; Flex: Move Slot; u16: Move ID | Overwrites Move Slot of the Pokémon at the specified Party Slot with Move ID. | Party slot and move slot start at 0 rather than 1, so the ranges are 0-5 and 0-3 respectively.<br>[https://bulbapedia.bulbagarden.net/wiki/List_of_moves](https://bulbapedia.bulbagarden.net/wiki/List_of_moves) |
| 008C | | CheckPokemonHasMove | Var: Variable; Flex: Move ID; Flex: Party Slot | Checks if a Pokémon at the specified Party Slot knows a move with given Move ID.<br>Stores 1 into Variable if yes, 0 otherwise. | Example: Headbutt tutor in Ilex Forest (Script File 92, Script 3) |
| 008D | | CheckMoveInParty | Var: Variable; Flex: Move ID | Checks if any Pokémon in the party knows Move ID move, stores in Variable the position of the first Pokémon that knows it or stores 6 if no Pokémon in the party knows the move | |
| 008E | | CheckPokeGearRematch \* | Flex: Phone Number; Var: Variable | | Has something to do with rematches but not sure if it's checking if a rematch is active or the # the rematch is on. Gets used when deciding when to let Gym Leaders appear in the overworld for a photo shoot after they are defeated in the Dojo. |
| 008F | | ChooseRivalName | Var: Variable | Opens the keyboard for naming the rival, stores 1 in Variable if user cancels the proccess | |
| 0090 | | GetCounterpartSprite | Var: Variable | Stores 97 (Lyra sprite ID) into the Variable if you're playing as Ethan;<br>Stores 0 (Ethan sprite ID) into the Variable if you're playing as Lyra. | Remember that Overworld Entities with sprite IDs 101 to 116 refer to the value of vars 0x4020-0x402F for the sprite to display. |
| 0091 | | UpgradePokegear | u8: Module | Adds the worldmap to the Pokegear if Module is 1, adds the radio if Module is 2 | |
| 0092 | RecordPokegearNumber | RecordPokegearNumber | Flex: ??? | | |
| 0093 | | CheckPokegearNumberRegistered \* | Flex: Phone Number; Var: Variable | Stores 0 into Variable if Phone Number has not been registered, and 1 if it has been registered. | Example: Sabrina in Olivine Harbor (Script File 153, Script 7). Used frequently by Gym Leaders appearing in the overworld. |
| 0094 | | | | | |
| 0095 | | | | | |
| 0096 | CallEnd | ReturnScreen | \- | Restores the normal overworld screen | |
| 0097 | | | | | |
| 0098 | Wifi | | \- | | |
| 0099 | | DressPokemon \* | \- | | |
| 009A | OpenPokemonDress | ContestDressupScreen \* | \- | | |
| 009B | | DressUpArtworkScreen \* | \- | | |
| 009C | | SealCapsuleScreen \* | \- | | |
| 009D | OpenPokegearMap | WorldMapScreen | \- | Opens the worldmap screen | |
| 009E | | PCBoxScreen \* | \- | | |
| 009F | | DrawScreenUnion \* | \- | | |
| 00A0 | | TrainerCaseUnion \* | \- | | |
| 00A1 | CallEnd2 | TradeScreenUnion \* | \- | | |
| 00A2 | | RecordMixingUnion \* | \- | | |
| 00A3 | EndGame | EndGameScreen | \- | Opens the Hall of Fame and game ending screens | |
| 00A4 | | HallOfFameData \* | \- | | |
| 00A5 | | StoreGTSStatus \* | ??? | | |
| 00A6 | WFC | InitWFC \* | ??? | | |
| 00A7 | | StarterSelectionScreen | \- | Opens the starter Pokémon selection screen | |
| 00A8 | | GetTrainerPathToPlayer \* | Flex: ??? | | |
| 00A9 | | TrainerStepTowardsPlayer \* | Flex: ???; Var: Variable | | |
| 00AA | | GetTrainerEyeType \* | Var: Variable | | |
| 00AB | | GetEyeTrainerNum \* | Flex: ???; Var: Variable | | |
| 00AC | | WritePlayerName | Var: Variable | Opens the keyboard for naming the player, stores 1 in Variable if user cancels the proccess | |
| 00AD | GivePokemonNickname | WritePokemonName | Flex: Party Position; Var: Variable | Opens the keyboard for naming a Pokémon in Party Position, stores 1 in Variable if user cancels the proccess | |
| 00AE | FadeScreen | FadeScreen | u16: Frame Count; u16: Duration; u16: Fade Style; u16: Color | Fades screen to chosen 15-bit Color, using the chosen Fade Style. The transition will render Frame Count images, of Duration length each. | Type 0 for fade in, Type 1 for fade out. Color has 15-bit format. Transition is the number of color changes that the game does in the fading. |
| 00AF | ResetScreen | WaitFadeScreen | \- | Waits for the screen fade to end | |
| 00B0 | Warp | Warp | Flex: Map; u16: Door; Flex: X; Flex: Y; Flex: Dir | Warps to X and Y position of Map header with initial Dir direction, using Door warp | When Door is 0 it doesn't use any door animation. |
| 00B1 | HallFameData | RockClimbAnimation | Flex: Party Position | Uses rock climb with the Pokémon at Party Position position | |
| 00B2 | | SurfAnimation | Flex: Party Position | Uses surf with the Pokémon at Party Position position | |
| 00B3 | WFC1 | WaterfallAnimation | Flex: Party Position | Uses waterfall with the Pokémon at Party Position position | |
| 00B4 | | FlyAnimation | u16: Map; Flex: X; Flex: Y | Flies to Map header map, to coordinates X and Y | |
| 00B5 | | FlashAnimation | \- | Sets weather to 12 (darkness after flash) and then updates the weather graphics | |
| 00B6 | | WhirlpoolAnimation | Flex: Party Position | Uses whirlpool with the Pokémon at Party Position position | |
| 00B7 | | CutAnimation | Flex: Party Position | Uses cut with the Pokémon at Party Position position | |
| 00B8 | | CheckBike | Var: Variable | Stores 1 in Variable if player is riding the bike, stores 0 otherwise | |
| 00B9 | | RideBike | u8: Action | Changes player form from normal to riding the bike if Action is 1, otherwise it sets the normal form to the player | |
| 00BA | | CyclingRoad | u8: Action | If Action is 1, the game sets the cycling road flag and moves the player down. Otherwise the flag is deactivated. | |
| 00BB | | CheckPlayerForm | Var: Variable | Stores in Variable the current player form | Values 0 is for normal form, value 1 for riding the bike, value 2 for surfing, value 3 for Rocket clothing |
| 00BC | | SetPlayerForm | u16: Form | Activates the Form bit in the internal player form data | The purpose of the different bits still needs to be researched. |
| 00BD | | UpdatePlayerForm | \- | Updates changes in the internal player form data in the screen | |
| 00BE | SetVariableHero | TextPlayerName | u8: String Buffer | Stores player's name in String Buffer | |
| 00BF | SetVariableRival | TextRivalName | u8: String Buffer | Stores rival's name in String Buffer | |
| 00C0 | SetVariableAlter | TextCounterpart | u8: String Buffer | Stores counterpart's name in String Buffer | |
| 00C1 | SetVariablePokemon | TextPartyPokemon | u8: String Buffer; Flex: Party Position | Stores the name of the Pokémon in Party Position in String Buffer | |
| 00C2 | SetVariableItem | TextItem | u8: String Buffer; Flex: Item | Stores Item's name in String Buffer | |
| 00C3 | | TextPocket | u8: String Buffer; Flex: Pocket | Stores Pocket's name in String Buffer | |
| 00C4 | SetVariableAttackItem | TextMachineMove | u8: String Buffer; Flex: Item | Stores the name of the move contained in Item TM/HM in String Buffer | |
| 00C5 | SetVariableAttack | TextMove | u8: String Buffer; Flex: Move | Stores battle Move's name in String Buffer | |
| 00C6 | SetVariableNumber | TextNumber | u8: String Buffer; Flex: Number | Stores a Number in String Buffer | |
| 00C7 | SetVariablePokemonNickname | TextPokeNickname | u8: String Buffer; Flex: Party Position | Stores the nickname of the Pokémon in Party Position in String Buffer | |
| 00C8 | SetVariableObject | | | | |
| 00C9 | | TextPlayerTrainerType | u8: String Buffer | Stores player's Union Room trainer type in String Buffer | |
| 00CA | SetVariablePokemonStored | TextPokemon | u8: String Buffer; Flex: Pokémon; u16: Unused; u8: Unused | Stores Pokémon's name in String Buffer | The two Unused parameters are for defining male/female nouns and singular/plural nouns respectively. However both don't apply in this command. |
| 00CB | | TextStarterPokemon | u8: String Buffer | Stores the name of the player' starter Pokémon in String Buffer | |
| 00CC | | TextRivalStarter | u8: String Buffer | Stores the name of the rival' starter Pokémon in String Buffer | |
| 00CD | CheckStarter | TextCounterpartStarter | u8: String Buffer | Stores the name of the counterpart' starter Pokémon in String Buffer | |
| 00CE | | CheckStarter | Var: Variable | Stores the starter Pokémon ID in Variable | |
| 00CF | | DummyTextGoods | u8: String Buffer; Flex: Unused | Loads an empty string in String Buffer | |
| 00D0 | | DummyTextTrap | u8: Unused; Flex: Unused | Nothing | |
| 00D1 | | DummyTextTreasure | u8: Unused; Flex: Unused | Nothing | |
| 00D2 | | TextMapName | u8: String Buffer; Flex: Map | Stores Map header name in String Buffer | |
| 00D3 | | GetSwarmInfo | Var: Map; Var: Pokémon | Selects a zone depending on a random seed, then stores the zone ID in Map and the corresponding swarm Pokémon of that zone in Pokémon | Predicted. Needs to be checked. |
| 00D4 | | TrainerID | Var: Variable | Stores the trainer ID number in Variable depending on the script ID | This means you shouldn't use this command in a normal script. |
| 00D5 | TrainerBattle | TrainerBattle | Flex: Trainer 1; Flex: Trainer 2; u8: Result; u8: ??? | Starts a battle against Trainer 1 and, if Trainer 2 is neither 0 nor the same as Trainer 1, a double battle against both. Continues without warping to Pokemon Center/home if Result is equal to 1. | Your party will also be fully healed after the battle if Result is 1. Example: Cherrygrove City fight with Rival |
| 00D6 | | TrainerMessage | Flex: Trainer ID; Flex: Type | Displays the text of Trainer ID trainer at condition Type | The possible Type values are the following (expand the note for see them) |
| 00D7 | | TrainerMsgCheck | Var: Noticing; Var: Defeat; Var: One Pokémon | If the script ID corresponds to a single battle trainer, stores 0 in Noticing, 2 in Defeat and 0 in One Pokémon. If it corresponds to a double battle, stores 3, 5 and 6 or 7, 9 and 10 depending on whether it's the first or the second trainer | This means you shouldn't use this command in a normal script. |
| 00D8 | | TrainerRematchMsgCheck | Var: Noticing; Var: Defeat; Var: One Pokémon | If the script ID corresponds to a single battle trainer, stores 17 in Noticing, 0 in Defeat and 0 in One Pokémon. If it corresponds to a double battle, stores 18, 0 and 6 or 19, 0 and 10 depending on whether it's the first or the second trainer | This means you shouldn't use this command in a normal script. |
| 00D9 | | TrainerTypeCheck | Var: Variable | Stores 0 in Variable if the script ID corresponds to a single battle, stores 1 if it corresponds to a double battle | This means you shouldn't use this command in a normal script. |
| 00DA | | TrainerMusic | Flex: Trainer | Plays Trainer's overworld music | It checks if player is in Johto or Kanto for that. |
| 00DB | LostGoPokecenter | LostBattle | \- | Return to Pokémon Center or player's house after being defeated | |
| 00DC | CheckLost | CheckBattleIsLost | Var: Variable | Stores 0 in Variable if player has been defeated in battle, stores 1 otherwise | |
| 00DD | | CheckDefeatedPokemon | Var: Variable; u8: ??? | Stores 0 in Variable if player defeated or catched the wild Pokemon, stores 1 otherwise | |
| 00DE | StoreStarter | Check2vs2 | Var: Variable | Stores 1 in Variable if player has at least 2 not fainted Pokémon, stores 0 otherwise | |
| 00DF | | DummyTrainerBattle | \- | Starts a battle against trainer with ID 1 | |
| 00E0 | | DummyTrainerFlag | \- | Sets the trainer flag with the same ID as the invoking event | |
| 00E1 | | DummyTrainerFlagJump | u32: Relative Jump | Jumps to a function, Relative Jump bytes forward or backward, if trainer flag with the invoking event ID is set | |
| 00E2 | | | | | |
| 00E3 | | | | | |
| 00E4 | | | | | |
| 00E5 | | | | | |
| 00E6 | | | | | |
| 00E7 | | | | | |
| 00E8 | | | | | |
| 00E9 | | | | | |
| 00EA | | | | | |
| 00EB | | | | | |
| 00EC | | | | | |
| 00ED | | | | | |
| 00EE | | CheckPokerus | Var: Variable | Stores 1 in Variable if one or more Pokémon in the party are infected with the Pokérus | |
| 00EF | ChecPokemonGender | GetPokemonGender | Flex: Party Position; Var: Variable | Stores 0 in Variable if Pokémon at Party Position is male, 1 if is female and 2 if gender is unknown | Unknown gender value is supposed and should be checked. |
| 00F0 | WarpLift | SetElevatorWarp \* | Var: Variable | | |
| 00F1 | CheckFloor | GetElevatorFloor | Var: Variable | Stores in Variable the current floor in a elevator | |
| 00F2 | | ElevatorBox | u8: X; u8: Y; Var: Variable; Flex: Floor | Shows the current floor number in a box at X and Y coordinates in the screen | Each X and Y unit implies 8 pixels. Values of 0 or higher than the screen may glitch the screen. Variable and Floor parameters have not been tested. |
| 00F3 | WirelessBattleWait | CountJohtoDexSeen | Var: Variable | Stores in Variable the total seen Pokemon in the Johto Pokédex | |
| 00F4 | | CountJohtoDexObtained | Var: Variable | Stores in Variable the total obtained Pokemon in the Johto Pokédex | |
| 00F5 | | CountNationalDexSeen | Var: Variable | Stores in Variable the total seen Pokemon in the National Pokédex | |
| 00F6 | | CountNationalDexObtained | Var: Variable | Stores in Variable the total obtained Pokemon in the National Pokédex | |
| 00F7 | PokemonContest | DummyNationalDexCheck | \- | Nothing | |
| 00F8 | | GetDexProgressMsg | u8: Mode; Var: Message; Var: Unknown | Checks the number of seen Pokémon in the Johto Pokédex (if Mode is 0) or the number of obtained Pokémon in the National Pokédex (otherwise) and stores the corresponding Professor message in Message, also storing 0x4AA in Unknown | |
| 00F9 | | WildBattle | Flex: Pokémon; Flex: Level | Starts a wild battle against a Pokémon of level Level | |
| 00FA | | WildBattleNoButtons | Flex: Pokémon; Flex: Level | Starts a first wild battle against a Pokémon of level Level | The difference between this and other similar commands is that Bag, Run and Pokémon buttons are disabled. |
| 00FB | | CatchTutorial | \- | Starts the catch tutorial battle | |
| 00FC | | | | | |
| 00FD | | CheckSaveGame | Var: Variable | Stores 0 in Variable if a different savegame exists and it's not possible to save, stores 1 if no previous savegame exists, stores 2 if game has to save a lot of data and stores 3 if game can perform a quick save | |
| 00FE | | SaveGame \* | | | |
| 00FF | | CheckPortrait \* | | | |
| 0100 | | SetPortraitTitle \* | | | |
| 0101 | | | | | |
| 0102 | | | | | |
| 0103 | | | | | |
| 0104 | | | | | |
| 0105 | | | | | |
| 0106 | | | | | |
| 0107 | | | | | |
| 0108 | | | | | |
| 0109 | | | | | |
| 010A | | | | | |
| 010B | | | | | |
| 010C | | | | | |
| 010D | | | | | |
| 010E | | | | | |
| 010F | | | | | |
| 0110 | | | | | |
| 0111 | | | | | |
| 0112 | | | | | |
| 0113 | | MartScreen | Flex: Unused | Opens the common mart shopping screen | |
| 0114 | | SpMartScreen | Flex: Mart ID | Opens the Mart ID mart shopping screen | Used in the Departament Store for a shop with specific fixed items. At 0x48188 of arm9.bin (IPKS) is the pointer to the shops table, each entry of the table being a pointer to an item table. |
| 0115 | | GoodsMartScreen | Flex: Mart ID | Opens the Mart ID goods mart shopping screen | |
| 0116 | | SealMartScreen | Flex: Mart ID | Opens the Mart ID seal mart shopping screen | |
| 0117 | | DummyLostBattle | \- | Return to Pokémon Center or player's house after being defeated | Same code as LostBattle command. |
| 0118 | | SetLastWarp | Flex: Warp ID | Sets map's Warp ID warp as the last used warp | Supposed. This would affect actions like Escape Rope use. |
| 0119 | CheckGender | CheckPlayerGender | Var: Variable | Stores 0 in Variable if player is male, stores 1 if female | |
| 011A | HealPokemon | HealPokemon | \- | Heals every Pokémon in the player's party | That does not include the black fade nor the healing sound. |
| 011B | | EndWirelessComms \* | | | |
| 011C | | EnterBattleRoom \* | | | |
| 011D | | SetPlayerDirComm \* | | | |
| 011E | | UnionMapChange \* | | | |
| 011F | | UnionRoomSpriteScreen \* | | | |
| 0120 | | StoreUnionSprite \* | | | |
| 0121 | | SetUnionSprite \* | | | |
| 0122 | | CheckPokedex | Var: Variable | Stores 1 in Variable if player has the Pokédex, stores 0 otherwise | |
| 0123 | ActivatePokedex | GivePokedex | \- | Gives the Pokédex to the player | |
| 0124 | | CheckShoes | Var: Variable | Stores 1 in Variable if player has the running shoes, stores 0 otherwise | |
| 0125 | GiveRunningShoes | GiveShoes | \- | Gives the running shoes to the player | |
| 0126 | CheckBadge | CheckBadge | Flex: Badge ID; Var: Variable | Checks if player has Badge ID badge, stores result in Variable | |
| 0127 | EnableBadge | GiveBadge | Flex: Badge ID | Gives the player Badge ID badge | |
| 0128 | DisableBadge | CountBadges | Var: Variable | Stores in Variable the number of badges obtained | |
| 0129 | | DummyCheckBag | Var: Variable | Stores 1 in Variable if flag 0x960 is set, stores 0 otherwise | |
| 012A | | DummyGiveBag | \- | Sets flag 0x960 | |
| 012B | | CheckPartner | Var: Variable | Stores 1 in Variable if the following event flag is activated, stores 0 otherwise | |
| 012C | | SetPartner | \- | Activates the following event flag, so you can no longer use the bike, surf, rock climb... | |
| 012D | | ClearPartner | \- | Deactivates the following event flag, so you can use the bike, surf, rock climb... again | |
| 012E | | CheckStepFlag \* | | | |
| 012F | | SetStepFlag \* | | | |
| 0130 | | ClearStepFlag \* | | | |
| 0131 | | DummyCheckGameCompleted | Var: Variable | Stores 1 in Variable if flag 0x964 is set, stores 0 otherwise | This flag is not the one that HGSS uses when the player clears the game. |
| 0132 | | DummyGameCompleted | \- | Sets flag 0x964 | This flag is not the one that HGSS uses when the player clears the game. |
| 0133 | PrepareDoorAnimation | DoorAnimation | u16: Matrix X; u16: Matrix Y; Flex: Map X; Flex: Map Y; u8: Door ID | Prepares a building located at Map X and Map Y coordinates in a map located at Matrix X and Matrix Y in the current matrix for animation, with Door ID animation ID | |
| 0134 | CloseDoor | WaitDoor | u8: Door ID | Wait animation of building with Door ID animation ID | |
| 0135 | MoveDoor | FreeDoor | u8: Door ID | Free animation of building with Door ID animation ID | |
| 0136 | OpenDoor | OpenDoor | u8: Door ID | Triggers first animation of building with Door ID animation ID | |
| 0137 | WaitDoor | CloseDoor | u8: Door ID | Triggers second animation of building with Door ID animation ID | |
| 0138 | | GetDaycareNames | \- | Stores first daycare Pokémon nickname in string buffer 0, the second daycare Pokémon nickname in string buffer 1 and the first Pokémon trainer's name in buffer 2 | If there's only one Pokémon in the daycare, string buffer 1 does not change. If no Pokémon is in the daycare, commands does nothing. |
| 0139 | | GetDaycareStatus | Var: Variable | If daycare Pokémon have an egg, stores 1 in Variable. Otherwise it stores 0 if no Pokémon is in the daycare, 2 if only one Pokémon is in the daycare or 3 if there are two Pokémon | |
| 013A | | InitEcruteakGym \* | | | |
| 013B | | | | ??? Something to do with the Goldenrod Dept. Store Basement, probably moving around blocks or opening access to doors. | |
| 013C | | | | ??? | |
| 013D | | | | | |
| 013E | | CianwoodGymInit \* | | | |
| 013F | | CianwoodGymTurnWinch \* | | | |
| 0140 | | VermilionGymInit \* | | | |
| 0141 | VermillionGymAnimation | VermilionGymLockAction \* | | | |
| 0142 | VermillionGymBin | VermilionGymCanCheck \* | | | |
| 0143 | | ResetVermilionGymCans \* | | | |
| 0144 | | InitVioletGym | \- | Initializes Violet Gym internal data and 3D model animations | |
| 0145 | | VioletGymElevator | \- | Triggers model #111 to move up or down | |
| 0146 | | InitAzaleaGym \* | | | |
| 0147 | AzaleaGym | AzaleaGymSpinarak \* | | | |
| 0148 | AzaleaGym2 | AzaleaGymSwitch \* | | | |
| 0149 | | BlackthornGymInit \* | | | |
| 014A | | FuchsiaGymInit \* | | | |
| 014B | | ViridianGymInit \* | | | |
| 014C | CheckPartyNumber | GetPartyCount | Var: Variable | Stores in Variable the current number of Pokémon in the party | |
| 014D | | BagScreen \* | | | |
| 014E | | BagScreenSelection \* | | | |
| 014F | | CheckPocketItems \* | | | |
| 0150 | | DummyTextBerry \* | | | |
| 0151 | | TextNature? \* | | | |
| 0152 | | SetOWDefaultPosition | Flex: Event ID; Flex: X; Flex: Y | Sets Event ID spawn position to global coords X and Y | |
| 0153 | SetOverworldPosition | SetOWPosition | Flex: Event ID; Flex: X; Flex: Z; Flex: Y; Flex: Dir | Moves Event ID to global coords X, Y, Z with Dir direction | Even though some maps are higher, the Z parameter is often 0. Game seems to calculate the correct Z position if it is wrong. |
| 0154 | | SetOWDefaultMovement | Flex: Event ID; Flex: Movement ID | Sets Event ID's default move code to Movement ID | |
| 0155 | | SetOWDefaultDirection | Flex: Event ID; Flex: Direction ID | Sets Event ID's default direction to Direction ID | |
| 0156 | | SetWarpPosition | Flex: Warp ID; Flex: X; Flex: Y | Moves Warp ID to global coords X and Y | |
| 0157 | | SetSpawnablePosition | Flex: Spawnable ID; Flex: X; Flex: Y | Moves Spawnable ID to global coords X and Y | |
| 0158 | | SetOWDirection | Flex: Event ID; Flex: Direction ID | Sets Event ID's current direction to Direction ID | |
| 0159 | | AddWaitingIcon \* | | | |
| 015A | | RemoveWaitingIcon \* | | | |
| 015B | | ReturnScriptWkSet \* | | | |
| 015C | | WaitTimeOrAB | Flex: Time | Stops script execution until Time frames have passed or until user presses A or B buttons | |
| 015D | ChoosePokemonMenu | ChoosePKMNSelection \* | | | |
| 015E | ChoosePokemonMenu2 | UnionChoosePKMNSelection\* | | | |
| 015F | StorePokemonMenu | GetSelectedPartySlot | Var: Variable | Stores in Variable the selected party slot in a party Pokémon screen, or 0xFF is user cancelled the selection | |
| 0160 | | SelectMove \* | | | |
| 0161 | | GetMoveSelection \* | | | |
| 0162 | StorePokemonNumber | GetPartyPokemonID | Var: Party Position; Var: Variable | Stores in Variable the ID of the Pokémon at Party Position | It will return 0 if Pokémon is an egg. |
| 0163 | CheckIfPokemonTraded | CheckTradedPokemon | Var: Party Position; Var: Variable | Stores 0 in Variable if trainer ID and secret ID of the Pokémon at Party Position are the player's ones, stores 1 otherwise | |
| 0164 | | CountPartyBornPokemon | Var: Variable | Stores in Variable the number of Pokémon in the Pokémon party, excluding the eggs | |
| 0165 | | CountAlivePokemonExceptFirst | Var: Variable; Flex: Party Position | Stores in Variable how many alive Pokémon would remain in the Pokémon party if Pokémon at Party Position disappeared | Eggs are excluded from the count. |
| 0166 | | CountTotalAlivePokemon | Var: Variable | Stores in Variable the number of Pokémon in the Pokémon party and PC boxes, excluding the eggs and fainted Pokémon | As Pokémon can't be fainted in the PC boxes, only eggs are not taken into account in the PC boxes count. |
| 0167 | | CountPartyEggs | Var: Variable | Stores in Variable the number of eggs in the Pokémon party | |
| 0168 | | TakeMoneyFlex | Flex: Money | Subtracts Money from the player's money | |
| 0169 | | RetrieveDayCareMon \* | | | |
| 016A | | GiveLoanMon \* | | | |
| 016B | | CheckReturnLoanMon \* | | | |
| 016C | | DeletePartyPokemon | Flex: Party Position | Deletes the Pokémon at Party Position from the party | The Pokémon data is destroyed. |
| 016D | | RemoveDayCareEgg \* | | | |
| 016E | | GiveDayCareEgg \* | | | |
| 016F | | TextDayCareCost \* | | | |
| 0170 | CheckHiroMoneyNumber | CompareMoneyFlex | Var: Variable; Flex: Money | Returns 1 to Variable if the player has Money or more money, returns 0 otherwise | |
| 0171 | | EggHatchScreen | \- | Opens the egg hatching screen with an egg in the Pokémon party that has 0 steps left for hatching | This may crash if there's no ready egg in the Pokémon party. It's better not to use this command unless you know what are you doing. |
| 0172 | | | | | |
| 0173 | | CheckDaycareLevelGain \* | Var: Variable; Flex: Position | Stores the amount of levels a Pokémon in the Daycare has gained from being in the Daycare | |
| 0174 | | GetDayCareSpeciesandNick \* | | | |
| 0175 | | GiveDayCareMon \* | | | |
| 0176 | | UnvanishOverworld | Flex: Event ID | Makes Event ID visible again if it was invisible | Can be used on Following Pokémon. Useful for scripting events that happen as soon as the player walks into a buidling and their Following Pokémon hasn't spawned yet. The Following Pokémon will "unvanish" on the same tile as the player, so account for this in movement scripts. |
| 0177 | | VanishOverworld | Flex: Event ID | Makes Event ID invisible, but still collisionable | It's a great idea to use this command in a level script for blocking doors with invisible events. |
| 0178 | OpenMail | MailScreen | \- | Opens the mail screen | |
| 0179 | CheckMail | CountMail | Var: Variable | Stores in Variable the current amount of mails in the mailbox | |
| 017A | | RankingView \* | | | |
| 017B | | GetTimePeriod | Var: Variable | Stores in Variable the current time period of the day | The different values are:<br>0: From 04:00 AM to 09:59 AM (Morning)<br>1: From 10:00 AM to 04:59 PM (Noon)<br>2: From 05:00 PM to 07:59 PM (Evening)<br>3: From 08:00 PM to 11:59 PM (Night)<br>4: From 00:00 AM to 03:59 AM (Midnight) |
| 017C | | GetRandom | Var: Variable; Flex: Range | Generates a random number between 0 and Range \- 1, and stores it in Variable | |
| 017D | | DummyGetRandom | Var: Variable; Flex: Range | Generates a random number between 0 and Range \- 1, and stores it in Variable | Exactly the same code as the command above. |
| 017E | | GetPokemonHappiness | Var: Variable; Flex: Party Position | Stores in Variable the happiness of Pokémon in Party Position | |
| 017F | | AddHappiness | Flex: Happiness; Flex: Party Position | Adds Happiness to the happiness of Pokémon in Party Position | |
| 0180 | | SubHappiness | Flex: Happiness; Flex: Party Position | Subs Happiness to the happiness of Pokémon in Party Position | |
| 0181 | | TextDayCareMonStats \* | | | |
| 0182 | | GetPlayerDirection | Var: Variable | Stores in Variable the direction the player is looking at | Predicted. Seeing up gives 0, seeing down gives 1, seeing left gives 2 and seeing right gives 3. |
| 0183 | | GetDayCareMonCompatibility \* | | | |
| 0184 | | CheckDayCareEgg \* | | | |
| 0185 | | CheckBornPokemonInParty | Flex: Pokémon; Var: Variable | Stores 1 in Variable if Pokémon is currently in the Pokémon party, stores 0 otherwise | Eggs do not count as Pokémon, so they will be ignored. |
| 0186 | | CheckPokemonSizeRecord | Var: Variable; Flex: Party Position | Stores 0 in Variable if Pokémon at Party Position does not have a bigger relative size than player's record, stores 1 if it's the same size and stores 2 if it has a bigger relative size | |
| 0187 | | SetPokemonSizeRecord | Flex: Party Position | Stores the relative size of Pokémon at Party Position as player's record | |
| 0188 | ComparePokemonHeight | TextPartyPokemonSize | Flex: Integer String Buffer; Flex: Decimal String Buffer; Flex: Party Position | Stores the integer part of Pokémon at Party Position size in Integer String Buffer (1 to 3 digits) and the decimal part of the size in Decimal String Buffer (1 digit) | |
| 0189 | CheckPokemonHeight | TextPokemonRecordSize | Flex: Integer String Buffer; Flex: Decimal String Buffer; Flex: Pokémon ID | Stores the integer part of player's record size, normalized to Pokémon ID range, in Integer String Buffer (1 to 3 digits) and the decimal part of the size in Decimal String Buffer (1 digit) | |
| 018A | ChoosePokemonDelete | | | | |
| 018B | StoreDeleteMove | | | | |
| 018C | CheckMoveNumber | CountPokemonMoves | Var: Variable; Flex: Party Position | Stores in Variable the total amount of moves that the Pokémon at Party Position currently has | |
| 018D | DeleteMove | DeleteMove | Flex: Party Position; Flex: Move Slot | Deletes the move in Move Slot from the Pokémon at Party Position | |
| 018E | | GetPartyPokemonMove | Var: Variable; Flex: Party Position; Flex: Move Slot | Stores in Variable the ID of the move in Move Slot from the Pokémon at Party Position | |
| 018F | SetVariableDeleteMove | TextPartyPokemonMove | u8: String Buffer; Flex: Party Position; Flex: Move Slot | Stores the name of the move in Move Slot from the Pokémon at Party Position in String Buffer | |
| 0190 | | Strength | Command format depends on the first parameter:<br>u8: 0<br>u8: 1<br>u8: 2; Var: Variable | Function depends on the first parameter:<br>0: Disables Strength so player can no longer move boulders<br>1: Allows the player to automatically move Strength boulders<br>2: Checks if Strength is activated, store answer in Variable | |
| 0191 | | FlashAction \* | Command format depends on the first parameter:<br>u8: 0<br>u8: 1<br>u8: 2; Var: Variable | Function depends on the first parameter:<br>0: Clears the Flash system flag<br>1: Sets the Flash system flag<br>2: Checks if Flash is activated, store answer in Variable | |
| 0192 | | DefogAction \* | Command format depends on the first parameter:<br>u8: 0<br>u8: 1<br>u8: 2; Var: Variable | Function depends on the first parameter:<br>0: Clears the Defog system flag<br>1: Sets the Defog system flag<br>2: Checks if Defog is activated, store answer in Variable | |
| 0193 | | GiveAccessory \* | | | |
| 0194 | GiveItemStored | CheckGivenAccessory \* | | | |
| 0195 | | CheckAccessory \* | | | |
| 0196 | | GiveBGAccessory \* | | | |
| 0197 | | CheckBGAccessory \* | | | |
| 0198 | | | | | |
| 0199 | | | | | |
| 019A | | | | | |
| 019B | | | | | |
| 019C | | | | | |
| 019D | | | | | |
| 019E | | | | | |
| 019F | | | | | |
| 01A0 | | | | | |
| 01A1 | | | | | |
| 01A2 | | | | | |
| 01A3 | | | | | |
| 01A4 | | | | | |
| 01A5 | | | | | |
| 01A6 | | | | | |
| 01A7 | | CheckCompleteJohtoDex | Var: Variable | Stores 1 in Variable if every Pokémon in the Johto Pokédex has been seen, stores 0 otherwise | |
| 01A8 | | CheckCompleteNationalDex | Var: Variable | Stores 1 in Variable if every Pokémon in the National Pokédex has been caught, stores 0 otherwise | |
| 01A9 | | OpenPokedexScreen \* | | | |
| 01AA | | CheckPokemonMail \* | | | |
| 01AB | | | | | |
| 01AC | | TakePokemonMail \* | | | |
| 01AD | | CountFossils | Var: Variable | Stores in Variable the current amount of fossils in the bag | Technically it's the number of items in the bag whose ID is between 99 and 105. |
| 01AE | | PreparePokeGearCall | Var: ???; Var: ???; Var: ??? | | |
| 01AF | | StartPokeGearCall | \- | Starts the PokéGear phone call that was previously set. | |
| 01B0 | | CheckFossilPokemon | Var: Variable; Flex: Item ID | Stores in Variable the ID of the Pokémon to which Item ID fossil belongs | |
| 01B1 | | CheckFossil | Var: Position; Var: Item ID; Flex: Amount | Stores in Item ID the ID of the first fossil item in the bag that the player has at least Amount quantity of, and stores in Position the amount of fossils in the bag before the first fossil that met the quantity condition | Stores 0 in both variables if there's no fossil in the bag. |
| 01B2 | | CountPokemonUnderLevel | Var: Variable; Flex: Level | Stores in Variable the amount of Pokémon in party whose level is equal or lower than Level | Eggs are completely ignored. |
| 01B3 | | SurvivePoison | Var: Variable; Flex: Party Position | If Pokémon at Party Position is poisoned and at 1 HP, it cures the poison and stores 1 in Variable, otherwise it stores 0 | |
| 01B4 | | FinishOverworldScreen \* | | | |
| 01B5 | | DebugPoketch \* | | | |
| 01B6 | | MessageAllFromArchive \* | | | |
| 01B7 | | MessageFromArchive \* | | | |
| 01B8 | | MessageAllPutPMS \* | | | |
| 01B9 | | | | | |
| 01BA | | | | | |
| 01BB | | | | | |
| 01BC | | | | | |
| 01BD | | GetPreviousHeaderID | Var: Variable | Stores in Variable the header ID of the previous accessed map | |
| 01BE | | GetCurrentHeaderID | Var: Variable | Stores in Variable the header ID of the map the player is in | |
| 01BF | | SetSafariFlag | u8: Flag; u8: Mode | If Flag is 0 safari encounters are activated, if Flag is 1 safari encounters are deactivated, being the own safari encounters if Mode is 0 or using the Safari Zone link if 1 | |
| 01C0 | | BattleRoomWarp \* | | | |
| 01C1 | | ExitBattleRoom \* | | | |
| 01C2 | | GeonetScreen | \- | Opens the Geonet screen | |
| 01C3 | | | | | |
| 01C4 | | ShowPokemonPic | Flex: Pokémon; Flex: Gender | Opens a window with the picture of Pokémon with Gender gender and registers the Pokémon in the Pokédex as seen | 0 = Male or Genderless; 1 = Female |
| 01C5 | | HidePokemonPic | \- | Hides the window of a Pokémon picture | |
| 01C6 | | | | | |
| 01C7 | | | | | |
| 01C8 | | | | | |
| 01C9 | | GetPokemonNature \* | Var: Variable; Flex: Party Position | | |
| 01CA | | CheckPartyNature \* | Var: Variable; Flex: Nature ID | | |
| 01CB | | | | | |
| 01CC | | LoadPokegearData \* | | | |
| 01CD | | SetRebattleTrainerID \* | | | |
| 01CE | | SetRebattleGymLeaderID \* | | | |
| 01CF | | EnableMassOutbreaks \* | | | |
| 01D0 | | AddRoamingPokemon | u8: ID | Activates a roaming Pokemon depending on the ID | Uses ID to determine which roaming Pokémon must appear: 0 for Entei, 1 for Raikou, 2 for Latias and 3 for Latios. |
| 01D1 | | UnionGroup | Command format depends on the first parameter:<br>u16: 0; Flex: ID; Var: Variable<br>u16: 1; Flex: ID; Var: Variable<br>u16: 2; Flex: ID; Flex: String Buffer<br>u16: 3; Flex: ID; Flex: String Buffer<br>u16: 4; Var: Variable<br>u16: 5; Flex: ID<br>u16: 6<br>u16: 7; Var: Variable | Function depends on the first parameter:<br>0: Checks if group ID exists, returns answer in Variable<br>1: Checks if group ID is accesible, returns answer in Variable<br>2: Writes group ID name in String Buffer<br>3: Writes leader's name of Group ID in String Buffer<br>4: Opens keyboard, stores 1 in Variable if user cancels, 2 if group name already exists, 0 otherwise<br>5: Enter in group ID<br>6: Creates a group<br>7: ??? | This command is the devil. |
| 01D2 | | CheckEggMoves \* | | | |
| 01D3 | ChoosePokemonRem | RememberMoveScreen \* | | | |
| 01D4 | | TeachMovesScreen \* | | | |
| 01D5 | StoreMoveRem | ResponseTeachMove \* | | | |
| 01D6 | | InitTrade | u8: Trade ID | Initializes Trade ID trade data | |
| 01D7 | | GetOfferedPokemon | Var: Variable | Stores in Variable the ID of the offered Pokémon of the current trade data | |
| 01D8 | CheckPokemonTrade | GetRequestedPokemon | Var: Variable | Stores in Variable the ID of the requested Pokémon of the current trade data | |
| 01D9 | TradeChosenPokemon | TradePokemonScreen | Flex: Party Position | Opens the trade Pokémon screen, giving the Pokémon at Party Position and receiving the offered Pokémon of the current trade data | |
| 01DA | StopTrade | EndTrade | \- | Frees the current trade data from the memory | |
| 01DB | | DummyInternationalDex | \- | Nothing | |
| 01DC | | DummyDimorphismDex | \- | Nothing | In fact it does activate a dimorphism flag in the Pokédex data, but since the HGSS Pokédex has the gender comparision by default, command's actual purpose is not noticeable. |
| 01DD | | NationalDex | Command format depends on the first parameter:<br>u8: 1; Var: Unused<br>u8: 2; Var: Variable | Function depends on the first parameter:<br>1: Activates the National Pokédex mode<br>2: Stores 1 in Variable if player has the National Pokédex, otherwise it stores 0 | |
| 01DE | | CountPokemonRibbons | Var: Variable; Flex: Party Position | Stores in Variable the amount of ribbons that the Pokémon in Party Position has | |
| 01DF | | CountPartyRibbons | Var: Variable | Stores in Variable the total amount of different ribbons in the current Pokémon party | |
| 01E0 | CheckRibbon | CheckRibbon | Var: Variable; Flex: Party Position; Flex: Ribbon | Stores 1 in Variable if the Pokémon in Party Position has the Ribbon ribbon, stores 0 otherwise | |
| 01E1 | GiveRibbon | GiveRibbon | Flex: Party Position; Flex: Ribbon | Gives the Ribbon ribbon to Pokémon in Party Position | |
| 01E2 | | TextRibbon | u8: String Buffer; Flex: Ribbon | Stores the name of the Ribbon in String Buffer | |
| 01E3 | CheckPokemonRibbon | CountPokemonEVs | Var: Variable; Flex: Party Position | Stores in Variable the total amount of effort values of Pokémon in Party Position | Predicted. |
| 01E4 | | GetDayOfWeek | Var: Variable | Stores in Variable the current day of the week | Value 0 is the first possible value and it's for Sunday. |
| 01E5 | | ShowRulesList | Var: Variable | ??? | |
| 01E6 | RBattleRecorder | DummyGetPokemonFootprint | \- | Nothing | |
| 01E7 | | PCHealAnimation | Flex: PokéBalls | Triggers the Pokémon Center healing animation with PokéBalls number of player's Pokémon | |
| 01E8 | | ElevatorAnimation | Flex: Direction; Flex: Count | Triggers the animation of building #208 up (if Direction is 0) or down (if Direction is 1) Count consecutive times | |
| 01E9 | | MysteryGiftGive | Command format depends on the first parameter:<br>u16: 0<br>u16: 1; Var: Variable<br>u16: 2; Var: Variable<br>u16: 3; Var: Variable<br>u16: 4<br>u16: 5; Var: Text File; Var: Text Line<br>u16: 6; Var: Text File; Var: Text Line<br>u16: 7<br>u16: 8 | Function depends on the first parameter:<br>0: Initializes the data for receiving a Mystery Gift<br>1: Checks if there is a Mystery Gift, stores answer in Variable<br>2: Stores the Mystery Gift ID in Variable<br>3: Checks if player can receive the Mystery Gift, stores answer in Variable<br>4: Gives the Mystery Gift to the player<br>5: Shows the succeed text at Text File file and Text Line slot<br>6: Shows the unable text at Text File file and Text Line slot<br>7: Ends the Mystery Gift process<br>8: Saves data and ends the Mystery Gift process | This one too. |
| 01EA | | | | | |
| 01EB | | | | | |
| 01EC | | | | | |
| 01ED | | | | | |
| 01EE | | | | | |
| 01EF | CheckVersion | CheckVersion | Var: Variable | Returns 0x7 to Variable if game is HeartGold, 0x8 if SoulSilver | |
| 01F0 | | FirstPokemonInParty | Var: Variable | Stores in Variable the slot of the first Pokémon in the party that is not an egg | |
| 01F1 | | CheckPokemonType \* | | | |
| 01F2 | | FirstPrimoPassword \* | | | |
| 01F3 | | SecondPrimoPassword \* | | | |
| 01F4 | | PreparePCAnimation \* | | | |
| 01F5 | | OpenPCAnimation \* | | | |
| 01F6 | | ClosePCAnimation \* | | | |
| 01F7 | | GetLottoNumber | Var: Variable | Stores Lotto random number in Variable | Supposed by analogy with Platinum. |
| 01F8 | | CheckWinLotto | Var: MatchPos; Var: Digits; Var: PC; Flex: Winning Number | Takes a Winning Number as input and responds as follows.<br>If no matching Pokémon could be found or an error occurs:<br>MatchPos: 0; Digits: 0; PC: 0.<br><br>For all other cases:<br><br>If the matching Pokémon is in the Player's party, PC will be assigned 0.<br>Otherwise, if it's in the Player's Storage System, PC will be assigned 1.<br><br>MatchPos stores the zero-based position of the winning Pokémon (either as Party pos or Storage System pos, depending on the value of PC).<br><br>When there's a match, the Digits var is assigned the number of matching digits of the Winning Pokémon's PID.<br>In case of multiple matches, priority is always given to the one with the most matching digits. | Supposed by analogy with Platinum.<br><br>To retrieve the exact position of a winning Pokémon in the Storage System, first make sure PC equals 1.<br><br>The zero-based PC Page and Position indices can be calculated:<br><br>PC Page index = MatchPos / 30<br>Position in page = MatchPos % 30<br><br>where % is the modulo operator. |
| 01F9 | | InitLotto | \- | Generates two random numbers and assigns them to two system lottery variables. | Supposed by analogy with Platinum. |
| 01FA | | BufferBoxPokemonNick \* | | | |
| 01FB | CheckBoxesNumber | CountPCFreeSpace | Var: Variable | Stores in Variable the amount of free Pokémon slots in PC boxes | |
| 01FC | | PalParkControl \* | | | |
| 01FD | | PalParkDepositCountCheck \* | | | |
| 01FE | | PalParkBoxPokemonCaught \* | | | |
| 01FF | StoreFriendParkResult | PalParkScoreResult \* | | | |
| 0200 | | PlayerMovementSavingSet \* | | | |
| 0201 | | PlayerMovementSavingClear \* | | | |
| 0202 | | HallOfFameAnime \* | | | |
| 0203 | | AddTrainerScore \* | | | |
| 0204 | | TextAccessory | u8: String Buffer; Flex: Accesory | Stores Accesory's name in String Buffer | |
| 0205 | | CheckPokemonInParty | Flex: Pokémon; Var: Variable | Stores 1 in Variable if Pokémon (or its egg) is currently in the Pokémon party, stores 0 otherwise | |
| 0206 | | SetDeoxysForm | Flex: Form | Sets every Deoxys in the Pokémon party the Form form | Form 0 is Normal, form 1 is Attack, form 2 is Defense and form 3 is Speed. |
| 0207 | | CheckBurmyForms | Var: Variable | Stores in Variable the number of current different Burmy forms in the Pokémon party | Returns 0 if player has no Burmy in the party, 1 if only one different form, 2 if two different forms and 3 if has three or more Burmy with three different forms. |
| 0208 | | | \- | ??? | Sets a internal flag. |
| 0209 | | | \- | ??? | Resets a internal flag. |
| 020A | | GetHour | Var: Variable | Stores current hour from RTC in Variable | |
| 020B | | ShakeOverworld | Flex: Event ID; Flex: Count; Flex: Time; Flex: X; Flex: Y | Makes Event ID overworld shake Count times in Time frames, moving X horizontally and Y vertically each shake | Event ID must be released before this command in order to see the animation. |
| 020C | | BlinkOverworld | Flex: ???; Flex: ???; Flex: ???; Flex: ???; Flex: ??? | ??? | |
| 020D | | CheckRegis | Var: Variable | Stores 1 in Variable if player has the 3 Regis in the party, stores 0 otherwise | |
| 020E | | | | | |
| 020F | | MessageUnown | u16: Text Slot | Display line Text Slot from the text file with the Unown font | Predicted. |
| 0210 | | CheckGBACartidge | Var: Variable | Stores the current GBA cartridge ID in Variable | Stores 0 if no cartridge, 1 if Pokémon Sapphire, 2 if Pokémon Ruby, 3 if Pokémon Emerald, 4 if Pokémon FireRed and 5 if Pokémon LeafGreen. Somehow it could also set 7 if Pokémon Gold, 8 if Pokémon Silver, 10 if Pokémon Diamond, 11 if Pokémon Pearl, 12 if Pokémon Platinum and 15 if Pokémon Colosseum. |
| 0211 | | GetFirstAlivePokemonSlot | Var: Variable | Stores in Variable the slot of the first Pokémon in the party that is not an egg nor is fainted | Predicted. |
| 0212 | | SetMatrixAlternativeMap | Flex: Alternative ID; u8: Status | Permanently changes a worldmap matrix cell corresponding to Alternative ID if Status is 1, reverts the change if 0 | It only changes the map file value in the matrix, not the map header nor the map height. Seems that the only Alternative ID available values are 0 and 1, corresponding to Mahogany Town and to the Lake of Rage. |
| 0213 | | TextBackgroundName \* | | | |
| 0214 | | CheckCoinsImmediate \* | | | |
| 0215 | | CheckCoins \* | | | |
| 0216 | | AddCoins \* | | | |
| 0217 | | GetPokemonLevel | Var: Result; Flex: Party Slot | Stores into Result the level of the Pokémon at a given Party Slot. | |
| 0218 | | | | | |
| 0219 | | | | | |
| 021A | | | | | |
| 021B | | | | | |
| 021C | | | | | |
| 021D | | TextNumberSp | u8: String Buffer; Flex: Number; u8: Alignment Type; u8: Digits | Stores a Number in String Buffer with Alignment Type alignment and Digits length | Predicted. Alignment Type 0 is left-alignment, 1 is right alignment padded with spaces and 2 is right alignment padded with zeros. Digits is used only in these last two types. |
| 021E | | MonGetContestValue \* | | | |
| 021F | | CheckBirthday | Var: Variable | Stores 1 in Variable if the current day is the player's birthday, stores 0 otherwise | |
| 0220 | | MusicVolumeSet | Flex: Music ID; Flex: Volume | Identifies the BGM Player which is playing Music ID and sets its Volume | |
| 0221 | | CountSeenUnown | Var: Variable | Stores in Variable the number of different seen Unown forms | |
| 0222 | | | | | |
| 0223 | | | | | |
| 0224 | | | | | |
| 0225 | | | | | |
| 0226 | | CountHallOfFameEntries \* | | | |
| 0227 | | | | | |
| 0228 | | | | | |
| 0229 | | | | | |
| 022A | | | | | |
| 022B | | | | | |
| 022C | | | | | Related to move tutor? Possibly BP price check? |
| 022D | | CheckBattlePoints \* | | | |
| 022E | | GiveBP \* | | | |
| 022F | | TakeBP \* | | | |
| 0230 | | CompareBP \* | Flex: ???; Var: ??? | | |
| 0231 | | ShakeCamera | Flex: X Magnitude; Flex: Y Magnitude; Flex: Count; Flex: Time | Shakes the screen vertically and/or horizontally, moving the camera X Magnitude pixels horizontally and Y Magnitude pixels vertically in each shake, with Count total shakes of Time frames each one | Don't abuse this command, as it seems that camera might end up 1 pixel up or down in each animation, especially when Count is an odd number. |
| 0232 | | Battle2vs2 | Flex: Partner Trainer ID; Flex: Trainer 1 ID; Flex: Trainer 2 ID; u8: ??? | Starts a double battle with Partner Trainer ID versus Trainer 1 ID and Trainer 2 ID | Last parameter seems to always be 0x1. |
| 0233 | | | | | |
| 0234 | | | | | |
| 0235 | | | Var: ??? | ??? | |
| 0236 | ChoosePokemonMenuTrade | PartyPokemonTradeScreen | \- | Opens the party Pokémon screen for a trade | |
| 0237 | | GetDPPtPrizeItemIdAndCost \* | | | |
| 0238 | | | | | |
| 0239 | | | | | |
| 023A | | CheckCoinsVar \* | | | |
| 023B | | | | | |
| 023C | | GetUniqueSealsQuantity \* | | | |
| 023D | | DummyActivateMysteryGift \* | | | |
| 023E | | GetOWMovement \* | | | |
| 023F | | | | | |
| 0240 | | | | | |
| 0241 | | | | | |
| 0242 | | | | | |
| 0243 | | | | | |
| 0244 | | TextSealSingular \* | u8: String Buffer; Flex: Seal ID | Stores Seal's singular noun in String Buffer | International release exclusive(supposed). Text archive 15. |
| 0245 | | DummyLockAll \* | | | |
| 0246 | | | | | |
| 0247 | | | | | |
| 0248 | | PartyLegalCheck \* | var: Result | Checks legality of party, at least for WIFI stuff. If RESULT is 1, party check failed and you have an "illegal" mon | Used by the attendants in the PC to check your Pokemon before going into the Union Room, may be used elsewhere too |
| 0249 | | | | | |
| 024A | | | | | |
| 024B | | | \- | ??? | |
| 024C | | LastBattleCheckCaught \* | Var ??? | | |
| 024D | LegendaryBattle | WildBattleSp | Flex: Pokémon; Flex: Level; u8: Shiny Flag | Starts a wild battle against a Pokémon of level Level, and shiny if Shiny Flag is 1 | |
| 024E | | CheckTrainerCardLevel | Var: Variable | Stores in Variable the current trainer card level | |
| 024F | | DummyRideBike | \- | Nothing | Seems to allocate the bike music in the RAM but doesn't play it. |
| 0250 | | | | | |
| 0251 | | ShowSaveBox | \- | Displays the save data box (current map name, player's name, the amount of badges, the Pokédex counter and the play time) | |
| 0252 | | HideSaveBox | \- | Hides the save data box | |
| 0253 | | ScopeMode | u8: Mode | If Mode is 1, activates the scope mode, otherwise the command deactivates the scope mode | The scope mode prevents the game to do certain actions (like reseting system flags) when changing map, and probably it's related with more things. |
| 0254 | | GetFollowingPokeSize | Var: Variable | Stores 0 in Variable if the current following Pokémon is small and can follow the player indoors, stores 1 if it's big and can't follow the player indoors | In fact it returns the second byte of the following Pokémon data files, stored in a/1/4/1.narc, which is the one that the game reads for allowing Pokémon entering in buildings. This command will work even if a SendBackFollowingPoke is used and the following Pokémon is hidden at that moment. |
| 0255 | | | \- | ??? | Draws a heart icon above the following Pokémon. Maybe a dummy command? |
| 0256 | | | u16: ??? | ??? | Parameter must be 1 or 2, otherwise command won't do anything. Seems to trigger a default movement for switching current player's and following Pokémon positions (for example, when using a HM). |
| 0257 | | FollowingPokePCAnimation | \- | Triggers the animation of sending the current following Pokémon back to its PokéBall over the Pokémon Center healing counter | |
| 0258 | StartFriendPark | SendBackFollowingPoke | \- | Triggers the animation of sending the current following Pokémon back to its PokéBall and deactivates the following Pokémon until the game is reset or a warp is used | |
| 0259 | | FollowingPokeFacePlayer | \- | Makes the invoking event look at the player, but with a size limitation | When the following Pokemon has a big size, it won't turn to the player if there is an overworld on the opposite side so it would collide. The checked flag is the second byte of the Parameter 1 field, which could be called "double size overworlds" flag, as it is also used for drawing two grass patches in the tall grass for the following Pokemon. |
| 025A | | LockFollowingPoke | u16: Operation | Releases the following Pokemon animation if Operation is 0, locks the animation otherwise | Predicted comparing ASM with Lock and Release commands. |
| 025B | | WaitFollowingPoke | \- | Waits the following Pokemon to end its last movement | Predicted comparing ASM with Lock and Release commands. |
| 025C | | SetFollowingPokeMovement | u16: Move Code | Changes the following Pokemon default movement to Move Code | The most important movement IDs are 0x30 and 0x38 (following and ghost-following behaviours respectively). |
| 025D | | SetFollowingPokePosition | u8: Position; u8: Direction | Moves the following Pokémon to one tile Position next to player and facing at Direction | For both parameters, up is 0, down is 1, left is 2 and right is 3. |
| 025E | EndFriendPark | BallResetFollowingPoke | \- | Moves the following Pokémon to the current player's position, and triggers the animation of sending the Pokémon out of its PokéBall after the player walks a step | This is commonly used after a different event following the player, so the player sends out the following Pokémon in the next step (instead of forcing it automatically with SendOutFollowingPoke). |
| 025F | | NoBallResetFollowingPoke | \- | Moves the following Pokémon to the current player's position | Almost same as BallResetFollowingPoke, but without the PokéBall animation (exactly like when a small Pokémon spawns after the player uses a warp). |
| 0260 | | SendOutFollowingPoke | \- | Triggers the animation of sending the first non-fainted Pokémon out of its PokéBall and spawns it on the last player position | Seems to be needed for refreshing/forcing its apparition after a Warp on the same map. |
| 0261 | MecScript | | \- | ??? | It's used in a lot of scripts that involve following Pokémon movements, placed at the top of them. Seems that it resets a lot of following Pokémon movement parameters and data. |
| 0262 | | | | | |
| 0263 | | Pokeathlon \* | | | |
| 0264 | | | | | |
| 0265 | | GetPokegearContactRandomGiftBerry \* | | | |
| 0266 | | GetPokegearContactGiftItem \* | | | |
| 0267 | MakePhoto | CameronPhotoScreen \* | | | |
| 0268 | | | | | |
| 0269 | | | | | |
| 026A | CheckAlbumPhoto | CheckAlbumIfFull \* | | | |
| 026B | | CheckRocketCostume \* | | | |
| 026C | | ActivateRocketCostume \* | | | |
| 026D | | | | | |
| 026E | | GetOWDirection | u16: Event ID; Var: Variable | Stores in Variable the current direction which Event ID is facing | Up is 0, Down is 1, Left is 2 and Right is 3. |
| 026F | | ApricornTreeAnimation \* | | | |
| 0270 | | ApricornTreeGetApricorn \* | | | |
| 0271 | | GiveApricornFromTree \* | | | |
| 0272 | | TextApricornName \* | | | |
| 0273 | | | | | |
| 0274 | | | | | |
| 0275 | | | | | |
| 0276 | | | | | |
| 0277 | | | | | |
| 0278 | | CountPartyMonsOfSpecies \* | | | |
| 0279 | | | | | |
| 027A | | | | | |
| 027B | | | | | |
| 027C | | | | | |
| 027D | | | | | |
| 027E | | | | | |
| 027F | | | | | |
| 0280 | | | | | |
| 0281 | | SaveWipeExtraChunks \* | | | |
| 0282 | | | Var: Variable | ??? | |
| 0283 | | | | | |
| 0284 | | | | | |
| 0285 | | | | | |
| 0286 | | | | | |
| 0287 | | GetPartySlotWithSpecies \* | var: Slot; u16 or Flex(???): Pokemon ID | Checks party for the presence of a Pokemon, and returns which slot they are in. | Assume that it checks for the first instance and then stops, so if you have multiple of the same Pokemon, it stops at the first instance and returns which slot it is in (0-5). Used in Silph Co. for Rotom |
| 0288 | | | | | |
| 0289 | | OpenScratchCardScreen \* | | | |
| 028A | | CloseScratchCard \* | | | |
| 028B | | GetScratchCardPrize \* | | | |
| 028C | | | | | |
| 028D | | MoveTutorChooseMove \* | | | |
| 028E | | TutorMoveTeachInSlot \* | | | |
| 028F | | TutorMoveGetPrice \* | | | |
| 0290 | | CheckHeadbuttCompatibility | Flex: Party Slot; Var: Variable | Stores 1 into Variable if the Pokémon at the given Party Slot can learn Headbutt. | Ilex Forest Tutor: Script File 92, Script 3 |
| 0291 | | IVCheckerJudge \* | | | |
| 0292 | | BufferStatName \* | | | |
| 0293 | | SetMonForme \* | | | |
| 0294 | | TextTrainerName \* | | | |
| 0295 | | | | | |
| 0296 | | | | | |
| 0297 | | | | | |
| 0298 | | | | | |
| 0299 | | | | | |
| 029A | | | | | |
| 029B | | | | | |
| 029C | | TextTypeName \* | | | |
| 029D | | GetItemQuantity \* | | | |
| 029E | | GetHiddenPowerType \* | | | |
| 029F | | SetFavoriteMon \* | | | |
| 02A0 | | GetFavoriteMon \* | | | |
| 02A1 | | GetOwnedRotomFormes \* | | | |
| 02A2 | | CountTranformedRotomsInParty \* | | | |
| 02A3 | | UpdateRotomForme \* | | | |
| 02A4 | | GetPartyPokemonForm \* | | | |
| 02A5 | | | | | |
| 02A6 | | | | | |
| 02A7 | | | | | |
| 02A8 | | | | | |
| 02A9 | | | | | |
| 02AA | | | | | |
| 02AB | | | | | |
| 02AC | | GetCurrentWeather | Var: Variable | Stores the current weather in Variable | |
| 02AD | | GetPlayerCoordinates \* | | | |
| 02AE | | | | | |
| 02AF | | | | | |
| 02B0 | | CheckFatefulEncounter \* | | | |
| 02B1 | | CommSanitizeParty \* | | | |
| 02B2 | | DayCareSanitizeMon \* | | | |
| 02B3 | | | | | |
| 02B4 | | TextBattleHallStreak \* | | | |
| 02B5 | | BattleHallCountUsedSpecies \* | | | |
| 02B6 | | BattleHallGetTotalStreak \* | | | |
| 02B7 | | | | | |
| 02B8 | | | | | |
| 02B9 | | | | | |
| 02BA | | FollowingPokemonIsEventTrigger \* | | | |
| 02BB | | | | | |
| 02BC | CheckWildBattle2 | | | | |
| 02BD | WildBattle2 | PokemonHasItem \* | | | |
| 02BE | | BattleTowerSetUpMultiBattle \* | | | |
| 02BF | | SetPlayerVolume \* | | | |
| 02C0 | | | | | |
| 02C1 | | | | | |
| 02C2 | | | | | |
| 02C3 | | CheckPokemonIsSeen \* | | | |
| 02C4 | | FloorTrapAnimation | | Triggers Team Rocket HQ trap-floor's graphical effect in the player's current position | |
| 02C5 | | | | | |
| 02C6 | | | | | |
| 02C7 | | TalkFollowingPoke | \- | The following Pokémon triggers a random movement, and then a random following message | This seems to be the command that executes when the player talks to the following Pokémon (at script #163). Files in a/2/2/0.narc link map names to possible texts. The following Pokémon ends up locked, so a Release should be used after this command. |
| 02C8 | | | | | |
| 02C9 | | OpenAlphPuzzle \* | u8: Puzzle ID | Loads the stone-panel puzzle of Puzzle ID. | ID 0 = Kabuto, ID 1 = Aerodactyl, ID 2 = Omanyte, ID 3 = Ho-Oh<br>Appears to check Flag 2423, 2424, 2425, 2426 for the completion of puzzles 0 to 3 respectively. |
| 02CA | | OpenRuinsofAlphHiddenRoom \* | u8: Room ID | Something to do with the secret room, not the puzzle trapdoor. | ID 0 = Kabuto Room, ID 1 = Aerodactyl Room, ID 2 = Omanyte Room, ID 3 = Ho-Oh Room |
| 02CB | | UpdateDayCareMonOverworlds \* | | | |
| 02CC | | | | | |
| 02CD | | | | | |
| 02CE | | | | | |
| 02CF | | | | | |
| 02D0 | | | | | |
| 02D1 | | | | | |
| 02D2 | | | u8: ???; u8: ???; u16: ???; u16: ???; u16: ??? | ??? | |
| 02D3 | | BoatAnimation | u8: Animation; u8: ???; u16: Header; u16: X coord; u16: Y coord | Plays the S.S. Aqua animation of leaving the port. Animation is either 0 or 1, with 0 being Olivine and 1 being Vermilion. X and Y coordinates are for the destination map | |
| 02D4 | | | | | |
| 02D5 | | | | | |
| 02D6 | | | | | |
| 02D7 | | | Var: Variable | ??? | |
| 02D8 | | | u8: ???; u8: ??? | ??? | |
| 02D9 | | CheckAlivePokemon | Var: Variable | Checks if player has at least 1 not fainted Pokémon, stores the result in Variable | Predicted. |
| 02DA | | CheckFollowingPoke | Var: Variable | Checks if player has a following Pokémon, stores the result in Variable | Supposed. |
| 02DB | | | \- | ??? | |
| 02DC | | | u8: ??? | ??? | |
| 02DD | | | u8: ???; Var: ??? | ??? | |
| 02DE | | | | | |
| 02DF | | CheckKurtApricorn \* | | | If not 0, script continues to check if daily flag is reset, then gives you the apricorns |
| 02E0 | | ClearKurtApricorn \* | | | |
| 02E1 | | GiveApricornBalls \* | | | |
| 02E2 | | CheckApricornCount \* | | | |
| 02E3 | | KurtApricornMenuScreen \* | | | |
| 02E4 | | StoreApricornJuice \* | | | |
| 02E5 | | CheckJuice \* | | | |
| 02E6 | | | | | |
| 02E7 | | | | | |
| 02E8 | | CreatePokeathlonFriendshipRoomStatues \* | | | |
| 02E9 | | TextPokeathlonCourseName \* | | | |
| 02EA | OpenLowScreen | OpenTouchScreen | \- | Changes the low screen design to the green Pokéball background | |
| 02EB | CloseLowScreen | CloseTouchScreen | \- | Sets the default low screen design | |
| 02EC | OpenLowYesNoBox | YesNoTouchScreen | Var: Variable | Opens a Yes-No selection, stores player's answer in Variable | Crashes if OpenTouchScreen is not used previously. |
| 02ED | Multi4 | MultiTouchStandardText | u8: ???; u8: ???; u8: ???; u8: ???; Var: Selection | Prepares a multiple selection menu with text bank #191, returns selected slot ID in Selection | |
| 02EE | Multi5 | MultiTouchLocalText | u8: ???; u8: ???; u8: ???; u8: ???; Var: Selection | Prepares a multiple selection menu with local texts, returns selected slot ID in Selection | |
| 02EF | TextScriptMulti4 | CreateMultiTouchBox | Flex: Text Slot; Flex: Top Screen Text;<br>Flex: Multi Box Slot | Adds a box with Multi Box Slot ID showing Text Slot text on the bottom screen and Top Screen Text on the top in a message box. Text depends on whether you use MultiTouchStandardText or MultiTouchLocalText | |
| 02F0 | CloseMulti4 | CloseMultiTouch | \- | Closes the multiple selection boxes | |
| 02F1 | | RockSmashItemCheck \* | Flex: ???; Var: ???; Var: ??? | ??? | |
| 02F2 | | | Var: ??? | ??? | |
| 02F3 | | | | | |
| 02F4 | | | | | |
| 02F5 | | | | | |
| 02F6 | | | | | |
| 02F7 | | | | | |
| 02F8 | | | | | |
| 02F9 | | | | | |
| 02FA | | | | | |
| 02FB | | | | | |
| 02FC | | | | | |
| 02FD | | | | | |
| 02FE | | | | | |
| 02FF | | | \- | ??? | |
| 0300 | | | | | |
| 0301 | | | | | |
| 0302 | | | | | |
| 0303 | | | | | |
| 0304 | | | | | |
| 0305 | | RenderCutscene \* | ???: ??? | Renders a cutscene<br>2 = Arceus stock image cutscene | |
| 0306 | | | | | |
| 0307 | | | | | |
| 0308 | | GiveTogepiEgg \* | | | |
| 0309 | | | | | |
| 030A | | GiveSpikyEaredPichu \* | \- | ??? | |
| 030B | | | | | |
| 030C | | OpenVoltorbFlip \* | | | |
| 030D | | KenyaCheckPartyOrMailbox \* | | | |
| 030E | | MartSell \* | \- | ??? | Related with the mart interface. |
| 030F | | SetFollowPokeInhibitState \* | | | |
| 0310 | | ScriptOverlayCmd \* | | | |
| 0311 | | BugContestAction \* | | | |
| 0312 | | TextBugContestWinner \* | | | |
| 0313 | | JudgeBugContest \* | | | |
| 0314 | | TextBugContestMonNick \* | | | |
| 0315 | | BugContestGetTimeLeft \* | | | |
| 0316 | | IsBugContestantRegistered \* | | | |
| 0317 | | | | | |
| 0318 | | | | | |
| 0319 | TakeMomMoney | TakeMomMoney \* | | | |
| 031A | GiveMomMoney | CheckMomMoneyBalance \* | | | |
| 031B | OpenMomMoneyBox | ShowMomMoney | Flex: X; Flex: Y | Shows mom savings money box at X and Y coordinates of the screen | |
| 031C | CloseMomMoneyBox | HideMomMoney | \- | Hides mom savings money box | |
| 031D | | | | | |
| 031E | | TextRulesetName \* | | | |
| 031F | | | | | |
| 0320 | | | | | |
| 0321 | | | | | |
| 0322 | | | | | |
| 0323 | | | | | |
| 0324 | | UpdateTownMap \* | u8(?): Map Type | Updates the town map to include Kanto<br>1 = Normal, Johto-only view<br>2 = Whole map, Kanto included | |
| 0325 | | | | | |
| 0326 | | | | | |
| 0327 | | | | | |
| 0328 | | | | | |
| 0329 | | | | | |
| 032A | | CelebiTimeTravelAnimation \* | | | |
| 032B | | | | | |
| 032C | | | | | |
| 032D | | MomGiftCheck \* | | | |
| 032E | | | | | |
| 032F | | | | | |
| 0330 | | UnownCircle \* | | | |
| 0331 | | | | | |
| 0332 | | InitMystriStageAnimation \* | | | |
| 0333 | | | | | |
| 0334 | | | | | |
| 0335 | | GetBuenasPassword \* | | | |
| 0336 | | | | | |
| 0337 | | | | | |
| 0338 | | | | | |
| 0339 | | GetShinyLeafCount \* | | | |
| 033A | | TryGiveShinyLeafCrown \* | | | |
| 033B | | CheckPokemonNickname \* | Flex: Party Slot; Var: Variable | Checks to see if the Pokémon at Party Slot position has a nickname. The variable will return 0 if the Pokémon does have a nickname. | Example: Script File 913, Function 35 |
| 033C | | | | | |
| 033D | | | Var: ??? | ??? | |
| 033E | | | | | |
| 033F | | | | | |
| 0340 | | | | | |
| 0341 | | | | | |
| 0342 | | | Var: Variable | ??? | |
| 0343 | | | Var: Variable | ??? | |
| 0344 | | CheckJadeOrbRequirements | Var: Variable | Stores 1 in Variable if player has both Kyogre and Groudon in the Pokémon party and they have been caught in Johto, stores 0 otherwise | |
| 0345 | | | Var: Variable | ??? | |
| 0346 | CheckMomMoneyNumber | CheckMoneyFull | u16: Money Account; Var: Variable | Stores 1 in Variable if the chosen money account is full.<br>Money account 0 = Mom's savings;<br>Money account 1 = Player; | |
| 0347 | | SystemSetSleepFlag \* | | | |
| 0348 | | | | | |
| 0349 | | | | | |
| 034A | | | | | |
| 034B | | TextItemLowercase | u8: String Buffer; Flex: Item | Stores Item's lowercase name in String Buffer | International release exclusive. |
| 034C | | TextItemPlural | u8: String Buffer; Flex: Item | Stores Item's plural noun in String Buffer | International release exclusive. |
| 034D | | TextPartyPokemonDefault | u8: String Buffer; Flex: Party position | Stores the name of the Pokémon in Party Position in String Buffer with default color tags encoding | International release exclusive. Names stored at text file 238. |
| 034E | | | | | International release exclusive. |
| 034F | | | u8: String Buffer | ??? | International release exclusive. |
| 0350 | | | u8: String Buffer; Flex: Accesory | ??? | International release exclusive. |
| 0351 | | TextTrainerClass | u8: String Buffer; Flex: Trainer class | Stores Trainer class' lowercase noun in String Buffer | International release exclusive. |
| 0352 | | TextSealPlural | u8: String Buffer; Flex: Seal | Stores Seal's plural noun in String Buffer | International release exclusive. Text archive 16. |
| 0353 | | TextCapitalize | u8: String Buffer | Capitalizes the string currently stored in String Buffer | International release exclusive. |
| 0354 | | TextFloor | u8: String Buffer; u8: Floor | Stores Floor's name in String Buffer | International release exclusive. Names stored at text file 191, lines 0x74 to 0x7A. |