2017-12-12 10:51:07 -08:00
|
|
|
# Text Commands
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
Defined in [macros/scripts/text.asm](/macros/scripts/text.asm) and [home/text.asm:TextCommands](/home/text.asm).
|
|
|
|
|
|
|
|
|
2018-01-17 10:58:50 -08:00
|
|
|
## `$00`: <code>text <i>text</i></code>
|
2017-12-12 10:51:07 -08:00
|
|
|
|
|
|
|
Start writing text until `"@"`.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2018-01-17 10:58:50 -08:00
|
|
|
## `$4E`: <code>next <i>text</i></code>
|
2017-12-12 10:51:07 -08:00
|
|
|
|
|
|
|
Move a line down.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2018-01-17 10:58:50 -08:00
|
|
|
## `$4F`: <code>line <i>text</i></code>
|
2017-12-12 10:51:07 -08:00
|
|
|
|
|
|
|
Start writing at the bottom line.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2018-01-17 10:58:50 -08:00
|
|
|
## `$50`: <code>page <i>text</i></code>
|
2017-12-12 10:51:07 -08:00
|
|
|
|
|
|
|
Start a new Pokédex page.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2018-01-17 10:58:50 -08:00
|
|
|
## `$51`: <code>para <i>text</i></code>
|
2017-12-12 10:51:07 -08:00
|
|
|
|
|
|
|
Start a new paragraph.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2018-01-17 10:58:50 -08:00
|
|
|
## `$55`: <code>cont <i>text</i></code>
|
2017-12-12 10:51:07 -08:00
|
|
|
|
|
|
|
Scroll to the next line.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2017-12-12 10:51:07 -08:00
|
|
|
## `$57`: `done`
|
|
|
|
|
|
|
|
End a text box.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2017-12-12 10:51:07 -08:00
|
|
|
## `$58`: `prompt`
|
|
|
|
|
|
|
|
Prompt the player to end a text box (initiating some other event).
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2018-01-17 10:58:50 -08:00
|
|
|
## `$01`: <code>text_from_ram <i>address</i></code>
|
2017-12-12 10:51:07 -08:00
|
|
|
|
|
|
|
Write text from a RAM address.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2018-01-17 10:58:50 -08:00
|
|
|
## `$02`: <code>text_bcd <i>address</i>, <i>flags</i></code>
|
2017-12-12 10:51:07 -08:00
|
|
|
|
2017-12-24 18:27:20 -08:00
|
|
|
Write [BCD][bcd] from an address, typically RAM.
|
2017-12-12 15:50:39 -08:00
|
|
|
|
|
|
|
[bcd]: https://en.wikipedia.org/wiki/Binary-coded_decimal
|
2017-12-12 10:51:07 -08:00
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2018-01-17 10:58:50 -08:00
|
|
|
## `$03`: <code>text_move <i>address</i></code>
|
2017-12-12 10:51:07 -08:00
|
|
|
|
|
|
|
Move to a new tile.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2018-01-17 10:58:50 -08:00
|
|
|
## `$04`: <code>text_box <i>address</i>, <i>height</i>, <i>width</i></code>
|
2017-12-12 10:51:07 -08:00
|
|
|
|
|
|
|
Draw a box.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2017-12-12 10:51:07 -08:00
|
|
|
## `$05`: `text_low`
|
|
|
|
|
|
|
|
Write text at (1, 16).
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2017-12-12 10:51:07 -08:00
|
|
|
## `$06`: `text_waitbutton`
|
|
|
|
|
|
|
|
Wait for button press; show arrow.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2017-12-12 10:51:07 -08:00
|
|
|
## `$07`: `text_scroll`
|
|
|
|
|
|
|
|
Pushes text up two lines and sets the `bc` cursor to the border tile below the
|
|
|
|
first character column of the text box.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2017-12-12 10:51:07 -08:00
|
|
|
## `$08`: `start_asm`
|
|
|
|
|
|
|
|
Start interpreting assembly code.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2018-01-17 10:58:50 -08:00
|
|
|
## `$09`: <code>deciram <i>address</i>, <i>bytes</i>, <i>digits</i></code>
|
2017-12-12 10:51:07 -08:00
|
|
|
|
|
|
|
Read *bytes* bytes from *address* and print them as a *digits*-digit number.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2017-12-12 10:51:07 -08:00
|
|
|
## `$0A`: `interpret_data`
|
|
|
|
|
|
|
|
Exit.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2017-12-12 10:51:07 -08:00
|
|
|
## `$0B`: `sound_dex_fanfare_50_79`
|
|
|
|
|
|
|
|
Play `SFX_DEX_FANFARE_50_79`.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2018-01-17 10:58:50 -08:00
|
|
|
## `$0C`: <code>limited_interpret_data <i>number</i></code>
|
2017-12-12 10:51:07 -08:00
|
|
|
|
|
|
|
Print *number* `"…"`s.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2017-12-12 10:51:07 -08:00
|
|
|
## `$0D`: `link_wait_button`
|
|
|
|
|
|
|
|
Wait for button press; show arrow.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2017-12-12 10:51:07 -08:00
|
|
|
## `$0E`: `sound_dex_fanfare_20_49`
|
|
|
|
|
|
|
|
Play `SFX_DEX_FANFARE_20_49`.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2017-12-12 10:51:07 -08:00
|
|
|
## `$0F`: `sound_item`
|
|
|
|
|
|
|
|
Play `SFX_ITEM`.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2017-12-12 10:51:07 -08:00
|
|
|
## `$10`: `sound_caught_mon`
|
|
|
|
|
|
|
|
Play `SFX_CAUGHT_MON`.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2017-12-12 10:51:07 -08:00
|
|
|
## `$11`: `sound_dex_fanfare_80_109`
|
|
|
|
|
|
|
|
Play `SFX_DEX_FANFARE_80_109`.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2017-12-12 10:51:07 -08:00
|
|
|
## `$12`: `sound_fanfare`
|
|
|
|
|
|
|
|
Play `SFX_FANFARE`.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2017-12-12 10:51:07 -08:00
|
|
|
## `$13`: `sound_slot_machine_start`
|
|
|
|
|
|
|
|
Play `SFX_SLOT_MACHINE_START`.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2018-01-17 10:58:50 -08:00
|
|
|
## `$14`: <code>text_buffer <i>id</i></code>
|
2017-12-12 10:51:07 -08:00
|
|
|
|
|
|
|
Write text from one of the following addresses (listed in `StringBufferPointers`):
|
|
|
|
|
|
|
|
0. `StringBuffer3`
|
|
|
|
1. `StringBuffer4`
|
|
|
|
2. `StringBuffer5`
|
|
|
|
3. `StringBuffer2`
|
|
|
|
4. `StringBuffer1`
|
|
|
|
5. `EnemyMonNick`
|
|
|
|
6. `BattleMonNick`
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2017-12-12 10:51:07 -08:00
|
|
|
## `$15`: `current_day`
|
|
|
|
|
|
|
|
Print the weekday.
|
|
|
|
|
2017-12-14 16:04:44 -08:00
|
|
|
|
2018-01-17 10:58:50 -08:00
|
|
|
## `$16`: <code>text_jump <i>address</i></code>
|
2017-12-12 10:51:07 -08:00
|
|
|
|
|
|
|
Write text from a different bank.
|