Welcome to Data Crystal's new home! Data Crystal is now part of the TCRF family (sort of).
The wiki has recently moved; please report any issues in Discord. Pardon the dust.

Pokémon Mystery Dungeon: Red Rescue Team/Scripting

From Data Crystal
< Pokémon Mystery Dungeon: Red Rescue Team
Revision as of 23:09, 10 April 2016 by BRNMan (talk | contribs) (Added Some Dialogue Commands)
Jump to navigation Jump to search

Much of the game uses it's own specific scripts to move along the plot and have characters interact.

Every script command is 16 byte (0x10) long. The first two bytes are the command identifier, and the rest are the arguments. The last four bytes in a statement are usually reserved for a pointer if needed.

Command identifier, argument, and pointer are in little-endian form.

Below are described the known script commands:

[01 00] Warp To Location

The 01 Command fades out the current screen, and warps the player to a new location.

Format: 01 00 XX XX YY YY 00 00 00 00 00 00 00 00 00 00
X = Time to fade out in frames
Y = Place to warp to

For a list of locations avaible, refer to the Location ID List in notes page.

[02 00] Warp To Dungeon

The 02 command warps the player directly into a dungeon.

Format: 02 00 XX XX YY YY 00 00 00 00 00 00 00 00 00 00
X = Time to fade out in frames
Y = Dungeon ID

[03 00] Warp To Friend Area Map

The 03 command warps the player directly to the friend area map.

Format: 03 00 XX XX YY YY YY YY 00 00 00 00 00 00 00 00
X = Time to fade out in frames
Y = Unknown; Command only works if set to zero or one.

[04 00] Warp To Dungeon With Map Walking Animation

The 04 command is similar to the 02 command. It warps the player into a dungeon, but plays a map walking animation first.

Format: 04 00 XX XX YY YY 00 00 00 00 00 00 00 00 00 00
X = Time to fade out in frames
Y = Dungeon ID [00 - 2C]

[05 00] Dungeon Rules Entering Confirm

Hmmm...
To do:
{{{1}}}

Displays dialogue that asks if it is OK to enter the dungeon with the following rules.

Format: 05 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00

[30 00] Close Textbox

Makes the textbox to disappear.

Format: 30 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00

[32 00]

Opens a textbox with a pokepic but without the name of the speaker, or scrolling text.

Format: 32 00 XX XX 00 00 00 00 00 00 00 00 YY YY YY YY
X = Pokepic/Speaker ID
Y = Pointer to text

[33 00]

Opens a textbox with a pokepic and scrolling text but without the name of the speaker or the text scrolling sound.

Format: 33 00 XX XX 00 00 00 00 00 00 00 00 YY YY YY YY
X = Pokepic/Speaker ID
Y = Pointer to text

[34 00]

The most widely used text command. Opens a textbox with a pokepic, the name of the speaker, scrolling letters, and the scrolling sound.

Format: 32 00 XX XX 00 00 00 00 00 00 00 00 YY YY YY YY
X = Pokepic/Speaker ID
Y = Pointer to text

[35 00]

Opens a textbox with a pokepic, scrolling letters, and the scrolling sound, but without the name of the speaker.

Format: 35 00 XX XX 00 00 00 00 00 00 00 00 YY YY YY YY
X = Pokepic/Speaker ID
Y = Pointer to text

[36 00]

Similar to [33 00] - has pokepic, and scrolling letters, but no sound. Immediately closes after finishing scrolling.

Format: 32 00 XX XX 00 00 00 00 00 00 00 00 YY YY YY YY
X = Pokepic/Speaker ID
Y = Pointer to text

[37 00]

Prints text out in the center of the screen. Generally to be used with a black bacground (in conjunction with [23 00] or [23 01]).

Format: 37 00 00 00 00 00 00 00 00 00 00 00 XX XX XX XX
X = Pointer to text

[39 00]

Prints text out in the center of the screen. Fades from black to white upon entrance and then back to black when done.

Format: 39 00 00 00 00 00 00 00 00 00 00 00 XX XX XX XX
X = Pointer to text

[3A 00]

Displays text box with Yes or No Selection Box above. Bound to an event.

Format: 32 00 XX XX YY YY 00 00 00 00 00 00 ZZ ZZ ZZ ZZ
X = Event ID
Y = Pokepic/Speaker ID
Z = Pointer to text

[DB 00] Pause Script Reading

Indicates a pause to wait before executing the next command.

Format: DB 00 XX XX 00 00 00 00 00 00 00 00 00 00 00 00

X = Delay amount in frames