From fbfda4551a9f115a65cca4ac6cce82f517007919 Mon Sep 17 00:00:00 2001 From: Remy Oukaour Date: Mon, 1 Jan 2018 18:44:08 -0500 Subject: Bold --- docs/battle_anim_commands.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'docs') diff --git a/docs/battle_anim_commands.md b/docs/battle_anim_commands.md index e7eb4a98f..4c29aea30 100644 --- a/docs/battle_anim_commands.md +++ b/docs/battle_anim_commands.md @@ -9,7 +9,8 @@ Defined in [macros/scripts/battle_anims.asm](/macros/scripts/battle_anims.asm) a ## `$D0`: `anim_obj` *object*, *x*, *y*, *param* -*Alternate*: `anim_obj` *object*, *x_tile*, *x*, *y_tile*, *y*, *param* + +***Alternate*: `anim_obj` *object*, *x_tile*, *x*, *y_tile*, *y*, *param*** Spawns an *object* at coordinate (*x*, *y*). -- cgit v1.2.3 From bc83768d8115810d581a5195a829d04e07af5c4a Mon Sep 17 00:00:00 2001 From: Remy Oukaour Date: Wed, 3 Jan 2018 02:02:15 -0500 Subject: Tileset images are 128px wide --- docs/images/hp_exp_bar_border.png | Bin 125 -> 116 bytes docs/images/hp_exp_bar_border_fix.png | Bin 124 -> 187 bytes docs/images/port.png | Bin 1055 -> 1048 bytes docs/images/port_fix.png | Bin 1056 -> 1547 bytes 4 files changed, 0 insertions(+), 0 deletions(-) (limited to 'docs') diff --git a/docs/images/hp_exp_bar_border.png b/docs/images/hp_exp_bar_border.png index 9d16a042b..f0f5d31a6 100644 Binary files a/docs/images/hp_exp_bar_border.png and b/docs/images/hp_exp_bar_border.png differ diff --git a/docs/images/hp_exp_bar_border_fix.png b/docs/images/hp_exp_bar_border_fix.png index 02d36f8a0..26135576f 100644 Binary files a/docs/images/hp_exp_bar_border_fix.png and b/docs/images/hp_exp_bar_border_fix.png differ diff --git a/docs/images/port.png b/docs/images/port.png index 8a18aad7d..3e05e0da7 100644 Binary files a/docs/images/port.png and b/docs/images/port.png differ diff --git a/docs/images/port_fix.png b/docs/images/port_fix.png index 055a377a5..3156b065d 100644 Binary files a/docs/images/port_fix.png and b/docs/images/port_fix.png differ -- cgit v1.2.3 From 9af6d8d0f1cdfe13d5b6b028b7da2965fddaab67 Mon Sep 17 00:00:00 2001 From: Remy Oukaour Date: Tue, 9 Jan 2018 23:53:58 -0500 Subject: Split tilesets/ into gfx/tilesets and data/tilesets/ --- docs/design_flaws.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'docs') diff --git a/docs/design_flaws.md b/docs/design_flaws.md index 21a222743..7dbe79cfb 100644 --- a/docs/design_flaws.md +++ b/docs/design_flaws.md @@ -471,7 +471,7 @@ GetNumberedTMHM: ; d417 ## `GetForestTreeFrame` works, but it's still bad -In [tilesets/animations.asm](/tilesets/animations.asm): +In [engine/tileset_anims.asm](/engine/tileset_anims.asm): ```asm GetForestTreeFrame: ; fc54c -- cgit v1.2.3 From e0088adb3f692e03e695f912bb0c4bf2e8189e75 Mon Sep 17 00:00:00 2001 From: Remy Oukaour Date: Wed, 10 Jan 2018 17:49:19 -0500 Subject: Other files belong in data/battle/ --- docs/move_effect_commands.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'docs') diff --git a/docs/move_effect_commands.md b/docs/move_effect_commands.md index b8b09c5c2..a7a779123 100644 --- a/docs/move_effect_commands.md +++ b/docs/move_effect_commands.md @@ -1,6 +1,6 @@ # Move Effect Commands -Defined in [macros/scripts/battle_commands.asm](/macros/scripts/battle_commands.asm) and [data/battle_command_pointers.asm:BattleCommandPointers](/data/battle_command_pointers.asm). +Defined in [macros/scripts/battle_commands.asm](/macros/scripts/battle_commands.asm) and [data/battle/effect_command_pointers.asm:BattleCommandPointers](/data/battle/effect_command_pointers.asm). ## `$01`: `checkturn` -- cgit v1.2.3 From d83aefb30af180eae03bbd65878e8de45166f3d0 Mon Sep 17 00:00:00 2001 From: Remy Oukaour Date: Fri, 12 Jan 2018 01:40:20 -0500 Subject: Use more constants in scripts --- docs/event_commands.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'docs') diff --git a/docs/event_commands.md b/docs/event_commands.md index b4314bd24..dfbe943f1 100644 --- a/docs/event_commands.md +++ b/docs/event_commands.md @@ -133,7 +133,7 @@ Defined in [macros/scripts/events.asm](/macros/scripts/events.asm) and [engine/s ## `$3E`: `readcoins` *memory* -## `$3F`: `RAM2MEM` *memory* +## `$3F`: `vartomem` *memory* ## `$40`: `pokenamemem` *mon_id*, *memory* @@ -151,7 +151,7 @@ Defined in [macros/scripts/events.asm](/macros/scripts/events.asm) and [engine/s ## `$47`: `opentext` -## `$48`: `refreshscreen` *dummy* +## `$48`: `refreshscreen` [*dummy*=0] ## `$49`: `closetext` -- cgit v1.2.3 From 5a3822fe863a7365735c1f5d1c007d98d7736f1b Mon Sep 17 00:00:00 2001 From: Remy Oukaour Date: Sat, 13 Jan 2018 00:47:38 -0500 Subject: Introduce callback, hiddenitem, conditional_event, and cmdqueue macros for map scripts --- docs/map_scripts.md | 28 ++++++++++++++++++++-------- 1 file changed, 20 insertions(+), 8 deletions(-) (limited to 'docs') diff --git a/docs/map_scripts.md b/docs/map_scripts.md index c6b1c58ba..e6794b543 100644 --- a/docs/map_scripts.md +++ b/docs/map_scripts.md @@ -16,7 +16,7 @@ ## `.MapCallbacks: db` *N* -- **`dbw` *type*, *script*** +- **`callback` *type*, *script*** Callback types: @@ -30,11 +30,21 @@ Callback types: - **`MAPCALLBACK_CMDQUEUE`** - **`dbw CMDQUEUE_STONETABLE,` *table_pointer*** - - **`stonetable` *warp_id*, *person*, *script*** - - **`db -1 ; end`** + +
+	callback MAPCALLBACK_CMDQUEUE, .Boulders
+
+.Boulders:
+	writecmdqueue .BoulderCmdQueue
+	return
+
+.BoulderCmdQueue:
+	cmdqueue CMDQUEUE_STONETABLE, .BoulderTable
+
+.BoulderTable:
+	stonetable warp_id, person, script
+	db -1 ; end
+
## Event scripts @@ -54,8 +64,10 @@ Callback types: ## `MapName_MapEventHeader:` +```asm ; filler db 0, 0 +``` ## `.Warps: db` *N* @@ -80,11 +92,11 @@ BG event types: - **`BGEVENT_IFSET/IFNOTSET`** - **`dw` *event_flag*, *script*** + **`conditional_event` *event_flag*, *script*** - **`BGEVENT_ITEM`** - **`dwb` *event_flag*, *item_id*** + **`hiddenitem` *event_flag*, *item_id*** - **`BGEVENT_COPY`** -- cgit v1.2.3 From d38ed29a4679936cb97bd95833e49700fee80030 Mon Sep 17 00:00:00 2001 From: mid-kid Date: Sun, 14 Jan 2018 12:08:49 +0100 Subject: Added menu documentation While slightly shitty, it's as complete as I'm able to get it. Any improvements are welcome. --- docs/menu.md | 272 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 272 insertions(+) create mode 100644 docs/menu.md (limited to 'docs') diff --git a/docs/menu.md b/docs/menu.md new file mode 100644 index 000000000..8d4bf32a8 --- /dev/null +++ b/docs/menu.md @@ -0,0 +1,272 @@ +### Everything you've ever wanted to know about menus* + +##### *but were afraid to ask + +## Contents + +- [ScrollingMenu](#scrollingmenu) +- [\_2DMenu](#_2dmenu) +- [DoNthMenu/SetUpMenu](#donthmenusetupmenu) +- [VerticalMenu](#verticalmenu) +- [Misc/Generic](#miscgeneric) + +## ScrollingMenu + +This is the only menu that does scrolling. It doesn't draw any TextBox around the menu. + +Structure: +``` +.MenuDataHeader: + db $40 ; flags + db 04, 02 ; start coords + db 13, 17 ; end coords + dw .MenuData2 + db 1 ; default option + +.MenuData2: + db $00 ; flags + db 5, 0 ; rows, columns + db 1 ; horizontal spacing + dba Items + dba Function1 + dba Function2 + dba Function3 +``` + +wMenuData2Flags: +``` +7: Select is functional +6: Start is functional +5: Call Function3 +4: Show arrows on the right-hand side +3: D-Left is functional +2: D-Right is functional +1: Call Function3 only if [wSwitchItem] is 0 +0: Call Function1 to display the cancel entry +``` + +If the columns entry in MenuDataHeader2 of a scrolling menu is 0, Function2 isn't called either. It doesn't affect the position of the arrows. + +Call state for functions in MenuDataHeader2 of ScrollingMenu: +``` +All of them: +[MenuSelection] = Current item. -1 is the CANCEL item. +[MenuSelectionQuantity] = Quantity of the current item. + +Function1: Called to display a menu entry. +de = Cursor position in TileMap + +Function2: Called to display the quantity of a menu entry. +de = Cursor position in TileMap + columns + +Function3: Called to display anything else, whenever the cursor is moved. +``` +There is no register of importance that should be preserved in any of these functions. + +The `; horizontal spacing` item in each MenuData2 is a misnomer. It changes how the Items struct looks. +If it's 1: +``` +db entries not including cancel +db entry1 +db entry2 +db -1 ; cancel +... +``` +If it's 2: +``` +db entries not including cancel +db entry1, quantity1 +db entry2, quantity2 +db -1 ; cancel +... +``` +In case it's 1, [MenuSelectionQuantity] will simply contain the next entry. + +## \_2DMenu + +This, like is implied by the name, is a 2-dimensional menu, where you can move your cursor in all 4 directions. It's only used for the battle menus as well as earl's academy. + +Structure: +``` +.MenuDataHeader: + db $40 ; flags + db 12, 08 ; start coords + db 17, 19 ; end coords + dw .MenuData2 + db 1 ; default option + +.MenuData2: + db $81 ; flags + dn 2, 2 ; rows, columns + db 6 ; spacing + dba Strings + dba Function +``` + +wMenuData2Flags: +``` +7: Leave one tile of spacing between the left textbox border and the text, enabling the cursor. +6: Don't leave one tile of spacing between the top textbox border and the text +5: Set bits 4 and 5 in w2DMenuFlags1 (Wrap around horizontally and vertically) +4: Unused +3: Unused +2: Unused +1: Select is functional +0: Disable B button +``` + +The bank for the Strings is generated when you call `_2DMenu`, and as such it doesn't really matter what bank you specify there (unless you callba `_2DMenu_` directly, of course). +`; spacing` is not a misnomer here, it's used to define how much space there is between columns. +`Function` is called after printing all the strings. `hl` will be pointed at the row below the last in the menu in TileMap. We don't know of its purpose, since it's never actually used anywhere. Only the bank number is always set to the same bank as the menu, but not used otherwise, since the address is 0. + +## DoNthMenu/SetUpMenu + +These are like the regular VerticalMenu, except they allow for creating slightly more "dynamic" menus, where the options aren't predefined, much like the ScrollingMenu. + +Structure: +``` +.MenuDataHeader: + db $40 ; flags + db 00, 00 ; start coords + db 07, 10 ; end coords + dw .MenuData2 + db 1 ; default option + +.MenuData2: + db $81 ; flags + db 0 ; items + dw Items + dw DisplayFunction + dw StringPointers +``` + +wMenuData2Flags: +``` +7: Unused +6: Unused +5: Set bit 5 in w2DMenuFlags1 (Wrap around vertically) +4: Unused +3: Start is functional +2: D-left and D-right are functional +1: Unused +0: Unused +``` + +The `; items` entry should be left empty, as it's autogenerated with the `Items` array in `GetMenuIndexSet`. +The bottom coord (`07` in the example) is autogenerated regardless of what you specify when building the MenuBox in `AutomaticGetMenuBottomCoord`, which also calculates the `bc` passed to MenuBox, which is useless because it's calculated again by MenuBox in `GetMenuBoxDims`. +[wWhichIndexSet] decides which menu is used through `GetMenuIndexSet`. You can define multiple menus at the Items pointer as such: +``` +Items: +db entries not including cancel +db entry1, entry2, entry3 +db -1 ; cancel +db entries not including cancel for 2nd menu +db entry1, entry2, entry3, entry4 +db -1 ; cancel +``` +This is actively used in MainMenu. + +StringPointers isn't handled by DoNthMenu internally. It's handled by different `DisplayFunction`s. +A custom one could choose to completely ignore it. + +StringPointers struct handled through `PlaceNthMenuStrings` as DisplayFunction and `MenuJumptable`: +``` +StringPointers: +dw FunctionToCall, PointerToString ; index 1 +dw FunctionToCall, PointerToString ; index 2 +... +``` + +StringPointers struct handled through `PlaceMenuStrings`: +``` +StringPointers: +db "STRING1@" +db "STRING2@" +... +``` + +Call state for DisplayFunction: +``` +[MenuSelection] = Current item. -1 is the CANCEL item. +de = Cursor position in TileMap +``` + +## VerticalMenu + +This is the simplest menu. Like, the most boring. Nothing special. Just normal. ...nooooooormal... + +Structure: +``` +.MenuDataHeader: + db %01010000 ; flags + db 12, 12 ; start coords + db 17, 19 ; end coords + dw .MenuData2 + db 1 ; default option + +.MenuData2: + db %10000000 ; flags + db 2 ; # items + db "GIVE@" + db "TAKE@" +``` + +wMenuData2Flags: +``` +7: Leave one tile of spacing between the left textbox border and the text +6: Don't leave one tile of spacing between the top textbox border and the text +5: Set bit 5 in w2DMenuFlags1 (Wrap around vertically) +4: Place menubox "title". See notes. +3: Unused +2: Unused +1: Select is functional +0: Disable B button +``` + +If bit 4 is set, a string at the end of the items array will be put at an offset from the start coord of the menu box. This string is defined like this: +``` + db 2 ; # items + db "GIVE@" + db "TAKE@" + db 2 ; x offset + db "TEST@" +``` +This is used in the menu for selecting the character's name. + +## Misc/Generic + +MenuDataHeader flags (wMenuFlags): +``` +7: Save a backup of the tiles +6: Save a backup of the tiles +5: Unused +4: Set bit 6 in w2DMenuFlags1 (Enable sprite animations) +3: Disable click sound +2: Unused +1: Unused +0: Call RestoreTileBackup when exiting the menu. This bit depends on whether bit 6 or 7 are set. +``` + +w2DMenuFlags1: +``` +7: Disable checking of wMenuJoypadFilter +6: Enable sprite animations +5: Wrap around vertically +4: Wrap around horizontally +3: Set bit 7 in w2DMenuFlags2 and exit the loop if bit 5 is disabled and we tried to go too far down +2: Set bit 7 in w2DMenuFlags2 and exit the loop if bit 5 is disabled and we tried to go too far up +1: Set bit 7 in w2DMenuFlags2 and exit the loop if bit 4 is disabled and we tried to go too far left +0: Set bit 7 in w2DMenuFlags2 and exit the loop if bit 4 is disabled and we tried to go too far right +``` + +w2DMenuFlags2: +``` +7: ????? +6: ????? +5: ????? +4: ????? +3: ????? +2: ????? +1: ????? +0: ????? +``` -- cgit v1.2.3 From f2dde1f4caf82622fe43cf6763ab8e0e9a40afa8 Mon Sep 17 00:00:00 2001 From: Remy Oukaour Date: Mon, 15 Jan 2018 00:05:20 -0500 Subject: Markdown formatting --- docs/menu.md | 110 +++++++++++++++++++++++++++++++++++++---------------------- 1 file changed, 70 insertions(+), 40 deletions(-) (limited to 'docs') diff --git a/docs/menu.md b/docs/menu.md index b8bb6fddf..71186a905 100644 --- a/docs/menu.md +++ b/docs/menu.md @@ -1,6 +1,7 @@ -### Everything you've ever wanted to know about menus* +# Everything you've ever wanted to know about menus* + +**\* but were afraid to ask** -##### *but were afraid to ask ## Contents @@ -10,12 +11,14 @@ - [VerticalMenu](#verticalmenu) - [Misc/Generic](#miscgeneric) -## ScrollingMenu -This is the only menu that does scrolling. It doesn't draw any TextBox around the menu. +## `ScrollingMenu` + +This is the only menu that does scrolling. It doesn't draw any `TextBox` around the menu. Structure: -``` + +```asm .MenuDataHeader: db MENU_BACKUP_TILES ; flags menu_coords 2, 4, SCREEN_WIDTH - 1, 13 @@ -32,7 +35,8 @@ Structure: dba Function3 ``` -wMenuData2Flags: +`wMenuData2Flags`: + ``` 7: Select is functional 6: Start is functional @@ -44,9 +48,10 @@ wMenuData2Flags: 0: Call Function1 to display the cancel entry ``` -If the columns entry in MenuDataHeader2 of a scrolling menu is 0, Function2 isn't called either. It doesn't affect the position of the arrows. +If the columns entry in `MenuDataHeader2` of a scrolling menu is 0, `Function2` isn't called either. It doesn't affect the position of the arrows. + +Call state for functions in `MenuDataHeader2` of `ScrollingMenu`: -Call state for functions in MenuDataHeader2 of ScrollingMenu: ``` All of them: [MenuSelection] = Current item. -1 is the CANCEL item. @@ -60,10 +65,13 @@ de = Cursor position in TileMap + columns Function3: Called to display anything else, whenever the cursor is moved. ``` + There is no register of importance that should be preserved in any of these functions. -The `; horizontal spacing` item in each MenuData2 is a misnomer. It changes how the Items struct looks. +The `; horizontal spacing` item in each `MenuData2` is a misnomer. It changes how the `Items` struct looks. + If it's 1: + ``` db entries not including cancel db entry1 @@ -71,7 +79,9 @@ db entry2 db -1 ; cancel ... ``` + If it's 2: + ``` db entries not including cancel db entry1, quantity1 @@ -79,14 +89,16 @@ db entry2, quantity2 db -1 ; cancel ... ``` -In case it's 1, [MenuSelectionQuantity] will simply contain the next entry. -## \_2DMenu +In case it's 1, `[MenuSelectionQuantity]` will simply contain the next entry. + +## `_2DMenu` -This, like is implied by the name, is a 2-dimensional menu, where you can move your cursor in all 4 directions. It's only used for the battle menus as well as earl's academy. +This, like is implied by the name, is a 2-dimensional menu, where you can move your cursor in all 4 directions. It's only used for the battle menus as well as Earl's academy. Structure: -``` + +```asm .MenuDataHeader: db MENU_BACKUP_TILES ; flags db 12, 08 ; start coords @@ -102,7 +114,8 @@ Structure: dba Function ``` -wMenuData2Flags: +`wMenuData2Flags`: + ``` 7: Leave one tile of spacing between the left textbox border and the text, enabling the cursor. 6: Don't leave one tile of spacing between the top textbox border and the text @@ -114,15 +127,19 @@ wMenuData2Flags: 0: Disable B button ``` -The bank for the Strings is generated when you call `_2DMenu`, and as such it doesn't really matter what bank you specify there (unless you callba `_2DMenu_` directly, of course). +The bank for the `Strings` is generated when you call `_2DMenu`, and as such it doesn't really matter what bank you specify there (unless you callba `_2DMenu_` directly, of course). + `; spacing` is not a misnomer here, it's used to define how much space there is between columns. -`Function` is called after printing all the strings. `hl` will be pointed at the row below the last in the menu in TileMap. We don't know of its purpose, since it's never actually used anywhere. Only the bank number is always set to the same bank as the menu, but not used otherwise, since the address is 0. -## DoNthMenu/SetUpMenu +`Function` is called after printing all the strings. `hl` will be pointed at the row below the last in the menu in `TileMap`. We don't know of its purpose, since it's never actually used anywhere. Only the bank number is always set to the same bank as the menu, but not used otherwise, since the address is 0. + -These are like the regular VerticalMenu, except they allow for creating slightly more "dynamic" menus, where the options aren't predefined, much like the ScrollingMenu. +## `DoNthMenu`/`SetUpMenu` + +These are like the regular `VerticalMenu`, except they allow for creating slightly more "dynamic" menus, where the options aren't predefined, much like the `ScrollingMenu`. Structure: + ``` .MenuDataHeader: db MENU_BACKUP_TILES ; flags @@ -138,7 +155,8 @@ Structure: dw StringPointers ``` -wMenuData2Flags: +`wMenuData2Flags`: + ``` 7: Unused 6: Unused @@ -151,8 +169,11 @@ wMenuData2Flags: ``` The `; items` entry should be left empty, as it's autogenerated with the `Items` array in `GetMenuIndexSet`. + The bottom coord (`07` in the example) is autogenerated regardless of what you specify when building the MenuBox in `AutomaticGetMenuBottomCoord`, which also calculates the `bc` passed to MenuBox, which is useless because it's calculated again by MenuBox in `GetMenuBoxDims`. -[wWhichIndexSet] decides which menu is used through `GetMenuIndexSet`. You can define multiple menus at the Items pointer as such: + +`[wWhichIndexSet]` decides which menu is used through `GetMenuIndexSet`. You can define multiple menus at the Items pointer as such: + ``` Items: db entries not including cancel @@ -162,39 +183,42 @@ db entries not including cancel for 2nd menu db entry1, entry2, entry3, entry4 db -1 ; cancel ``` -This is actively used in MainMenu. -StringPointers isn't handled by DoNthMenu internally. It's handled by different `DisplayFunction`s. -A custom one could choose to completely ignore it. +This is actively used in `MainMenu`. -StringPointers struct handled through `PlaceNthMenuStrings` as DisplayFunction and `MenuJumptable`: -``` +`StringPointers` isn't handled by `DoNthMenu` internally. It's handled by different `DisplayFunction`s. A custom one could choose to completely ignore it. + +`StringPointers` struct handled through `PlaceNthMenuStrings` as `DisplayFunction` and `MenuJumptable`: + +```asm StringPointers: -dw FunctionToCall, PointerToString ; index 1 -dw FunctionToCall, PointerToString ; index 2 + dw FunctionToCall, PointerToString ; index 1 + dw FunctionToCall, PointerToString ; index 2 ... ``` -StringPointers struct handled through `PlaceMenuStrings`: -``` +`StringPointers` struct handled through `PlaceMenuStrings`: + +```asm StringPointers: -db "STRING1@" -db "STRING2@" + db "STRING1@" + db "STRING2@" ... ``` -Call state for DisplayFunction: +Call state for `DisplayFunction`: ``` [MenuSelection] = Current item. -1 is the CANCEL item. de = Cursor position in TileMap ``` -## VerticalMenu +## `VerticalMenu` -This is the simplest menu. Like, the most boring. Nothing special. Just normal. ...nooooooormal... +This is the simplest menu. Like, the most boring. Nothing special. Just normal. …nooooooormal… Structure: -``` + +```asm .MenuDataHeader: db MENU_SPRITE_ANIMS | MENU_BACKUP_TILES ; flags menu_coords 12, 12, SCREEN_WIDTH - 1, SCREEN_HEIGHT - 1 @@ -208,7 +232,8 @@ Structure: db "TAKE@" ``` -wMenuData2Flags: +`wMenuData2Flags`: + ``` 7: Leave one tile of spacing between the left textbox border and the text 6: Don't leave one tile of spacing between the top textbox border and the text @@ -221,18 +246,21 @@ wMenuData2Flags: ``` If bit 4 is set, a string at the end of the items array will be put at an offset from the start coord of the menu box. This string is defined like this: -``` + +```asm db 2 ; # items db "GIVE@" db "TAKE@" db 2 ; x offset db "TEST@" ``` + This is used in the menu for selecting the character's name. ## Misc/Generic -MenuDataHeader flags (wMenuFlags): +`MenuDataHeader` flags (`wMenuFlags`): + ``` 7: Save a backup of the tiles 6: Save a backup of the tiles @@ -244,7 +272,8 @@ MenuDataHeader flags (wMenuFlags): 0: Call RestoreTileBackup when exiting the menu. This bit depends on whether bit 6 or 7 are set. ``` -w2DMenuFlags1: +`w2DMenuFlags1`: + ``` 7: Disable checking of wMenuJoypadFilter 6: Enable sprite animations @@ -256,7 +285,8 @@ w2DMenuFlags1: 0: Set bit 7 in w2DMenuFlags2 and exit the loop if bit 4 is disabled and we tried to go too far right ``` -w2DMenuFlags2: +`w2DMenuFlags2`: + ``` 7: ????? 6: ????? -- cgit v1.2.3 From 9180362211cf465c52798124baa5c5c06ba1d332 Mon Sep 17 00:00:00 2001 From: Remy Oukaour Date: Mon, 15 Jan 2018 11:06:17 -0500 Subject: Move code out of gfx/ (close #474) --- docs/design_flaws.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'docs') diff --git a/docs/design_flaws.md b/docs/design_flaws.md index 7dbe79cfb..c856e8b38 100644 --- a/docs/design_flaws.md +++ b/docs/design_flaws.md @@ -24,7 +24,7 @@ dba_pic: MACRO ; dbw bank, address ENDM ``` -The offset is translated into a correct bank by `FixPicBank` in [gfx/load_pics.asm](/gfx/load_pics.asm): +The offset is translated into a correct bank by `FixPicBank` in [engine/load_pics.asm](/engine/load_pics.asm): ```asm FixPicBank: ; 511c5 @@ -106,7 +106,7 @@ ROMX $49 "Pics 2" ``` -Two routines in [gfx/load_pics.asm](/gfx/load_pics.asm) make this assumption; `GetFrontpicPointer`: +Two routines in [engine/load_pics.asm](/engine/load_pics.asm) make this assumption; `GetFrontpicPointer`: ```asm ld a, [CurPartySpecies] -- cgit v1.2.3 From bf074f359886707d2ffb2e0b525b03dc7af0fe29 Mon Sep 17 00:00:00 2001 From: Remy Oukaour Date: Tue, 16 Jan 2018 22:57:19 -0500 Subject: =?UTF-8?q?map=5Fheader=20=E2=86=92=20map=5Fdef;=20map=5Fheader=5F?= =?UTF-8?q?2=20=E2=86=92=20map=5Fdata?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/map_scripts.md | 119 ++++++++++++++++++++++++++++++---------------------- 1 file changed, 70 insertions(+), 49 deletions(-) (limited to 'docs') diff --git a/docs/map_scripts.md b/docs/map_scripts.md index e6794b543..9eb924504 100644 --- a/docs/map_scripts.md +++ b/docs/map_scripts.md @@ -3,34 +3,39 @@ ## `const_value set 2` -- **`const` *`MAPNAME_OBJECTNAME`*** +
+	const MAPNAME_OBJECTNAME
+
-## `MapName_MapScriptHeader:` +## `MapName_MapScripts:` -## `.SceneScripts: db` *N* +### `.SceneScripts: db` *N* -- **`scene_script` *script*** +
+	scene_script script
+
-## `.MapCallbacks: db` *N* +### `.MapCallbacks: db` *N* -- **`callback` *type*, *script*** +
+	callback type, script
+
Callback types: -- **`MAPCALLBACK_NEWMAP`** +- `MAPCALLBACK_NEWMAP` -- **`MAPCALLBACK_TILES`** +- `MAPCALLBACK_TILES` -- **`MAPCALLBACK_OBJECTS`** +- `MAPCALLBACK_OBJECTS` -- **`MAPCALLBACK_SPRITES`** +- `MAPCALLBACK_SPRITES` -- **`MAPCALLBACK_CMDQUEUE`** +- `MAPCALLBACK_CMDQUEUE` -
 	callback MAPCALLBACK_CMDQUEUE, .Boulders
 
@@ -62,7 +67,7 @@ Callback types:
 [Movement commands](movement_commands.md)
 
 
-## `MapName_MapEventHeader:`
+## `MapName_MapEvents:`
 
 ```asm
 	; filler
@@ -70,82 +75,98 @@ Callback types:
 ```
 
 
-## `.Warps: db` *N*
+### `.Warps: db` *N*
 
-- **`warp_def` *x*, *y*, *warp_id*, *map***
+
+	warp_def x, y, warp_id, map
+
-## `.CoordEvents: db` *N* +### `.CoordEvents: db` *N* -- **`coord_event` *x*, *y*, *scene_id*, *script*** +
+	coord_event x, y, scene_id, script
+
-## `.BGEvents: db` *N* +### `.BGEvents: db` *N* -- **`bg_event` *x*, *y*, *type*, *script*** +
+	bg_event x, y, type, script
+
BG event types: -- **`BGEVENT_READ`** +- `BGEVENT_READ` -- **`BGEVENT_UP/DOWN/LEFT/RIGHT`** +- `BGEVENT_UP/DOWN/LEFT/RIGHT` -- **`BGEVENT_IFSET/IFNOTSET`** +- `BGEVENT_IFSET/IFNOTSET` - **`conditional_event` *event_flag*, *script*** +
+	conditional_event event_flag, script
+
-- **`BGEVENT_ITEM`** +- `BGEVENT_ITEM` - **`hiddenitem` *event_flag*, *item_id*** +
+	hiddenitem event_flag, item_id
+
-- **`BGEVENT_COPY`** +- `BGEVENT_COPY` -## `.ObjectEvents: db` *N* +### `.ObjectEvents: db` *N* -- **`object_event` *x*, *y*, *sprite*, *movement*, *rx*, *ry*, *h1*, *h2*, *palette*, *type*, *range*, *script*, *event_flag*** +
+	object_event x, y, sprite, movement, rx, ry, h1, h2, palette, type, range, script, event_flag
+
Movement types: -- **`SPRITEMOVEDATA_ITEM_TREE`** +- `SPRITEMOVEDATA_ITEM_TREE` -- **`SPRITEMOVEDATA_WANDER`** +- `SPRITEMOVEDATA_WANDER` -- **`SPRITEMOVEDATA_SPINRANDOM_SLOW`** +- `SPRITEMOVEDATA_SPINRANDOM_SLOW` -- **`SPRITEMOVEDATA_WALK_UP_DOWN`** +- `SPRITEMOVEDATA_WALK_UP_DOWN` -- **`SPRITEMOVEDATA_WALK_LEFT_RIGHT`** +- `SPRITEMOVEDATA_WALK_LEFT_RIGHT` -- **`SPRITEMOVEDATA_STANDING_UP/DOWN/LEFT/RIGHT`** +- `SPRITEMOVEDATA_STANDING_UP/DOWN/LEFT/RIGHT` -- **`SPRITEMOVEDATA_SPINRANDOM_FAST`** +- `SPRITEMOVEDATA_SPINRANDOM_FAST` -- **`SPRITEMOVEDATA_SNORLAX`** +- `SPRITEMOVEDATA_SNORLAX` -- **`SPRITEMOVEDATA_POKEMON`** +- `SPRITEMOVEDATA_POKEMON` -- **`SPRITEMOVEDATA_SUDOWOODO`** +- `SPRITEMOVEDATA_SUDOWOODO` -- **`SPRITEMOVEDATA_SMASHABLE_ROCK`** +- `SPRITEMOVEDATA_SMASHABLE_ROCK` -- **`SPRITEMOVEDATA_STRENGTH_BOULDER`** +- `SPRITEMOVEDATA_STRENGTH_BOULDER` -- **`SPRITEMOVEDATA_SPINCOUNTERCLOCKWISE`** +- `SPRITEMOVEDATA_SPINCOUNTERCLOCKWISE` -- **`SPRITEMOVEDATA_SPINCLOCKWISE`** +- `SPRITEMOVEDATA_SPINCLOCKWISE` -- **`SPRITEMOVEDATA_BIGDOLL`** +- `SPRITEMOVEDATA_BIGDOLL` -- **`SPRITEMOVEDATA_LAPRAS`** +- `SPRITEMOVEDATA_LAPRAS` Object types: -- **`OBJECTTYPE_SCRIPT`** +- `OBJECTTYPE_SCRIPT` -- **`OBJECTTYPE_ITEMBALL`** +- `OBJECTTYPE_ITEMBALL` - **`itemball` *item_id*** +
+	itemball item_id
+
-- **`OBJECTTYPE_TRAINER`** +- `OBJECTTYPE_TRAINER` - **`trainer` *event_flag*, *group_id*, *trainer_id*, *seen_text*, *beaten_text*, *loss_text*, *script*** +
+	trainer event_flag, group_id, trainer_id, seen_text, beaten_text, loss_text, script
+
-- cgit v1.2.3 From 6d20cf3e80780af15ed15acea2f7feac1ffd9705 Mon Sep 17 00:00:00 2001 From: Remy Oukaour Date: Tue, 16 Jan 2018 23:47:45 -0500 Subject: =?UTF-8?q?"CryHeader"=20=E2=86=92=20"Cry";=20"Cry"=20=E2=86=92=20?= =?UTF-8?q?"MonCry"?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/bugs_and_glitches.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'docs') diff --git a/docs/bugs_and_glitches.md b/docs/bugs_and_glitches.md index 52d788987..ef3855407 100644 --- a/docs/bugs_and_glitches.md +++ b/docs/bugs_and_glitches.md @@ -1002,7 +1002,7 @@ The exact cause is unknown, but a workaround exists for `DexEntryScreen_MenuActi call GetCryIndex ld e, c ld d, b - call PlayCryHeader + call PlayCry ret ``` @@ -1011,7 +1011,7 @@ The exact cause is unknown, but a workaround exists for `DexEntryScreen_MenuActi ```asm .Cry: ; 40340 ld a, [CurPartySpecies] - call PlayCry + call PlayMonCry ret ``` -- cgit v1.2.3 From d2725c31040af3d54ea9b0f28f8fe89d6454e75b Mon Sep 17 00:00:00 2001 From: Remy Oukaour Date: Wed, 17 Jan 2018 13:58:50 -0500 Subject: Allow italics/bold within inline code --- docs/battle_anim_commands.md | 77 ++++++++----- docs/event_commands.md | 256 +++++++++++++++++++++---------------------- docs/map_scripts.md | 18 +-- docs/movement_commands.md | 40 +++---- docs/music_commands.md | 110 +++++++++++++------ docs/pic_animations.md | 6 +- docs/text_commands.md | 28 ++--- 7 files changed, 302 insertions(+), 233 deletions(-) (limited to 'docs') diff --git a/docs/battle_anim_commands.md b/docs/battle_anim_commands.md index 4c29aea30..6d9ff4113 100644 --- a/docs/battle_anim_commands.md +++ b/docs/battle_anim_commands.md @@ -3,14 +3,14 @@ Defined in [macros/scripts/battle_anims.asm](/macros/scripts/battle_anims.asm) and [engine/battle_anims/anim_commands.asm:BattleAnimCommands](/engine/battle_anims/anim_commands.asm). -## `$00`−`$CF`: `anim_wait` *length* +## `$00`−`$CF`: anim_wait length - *length*: duration in frames -## `$D0`: `anim_obj` *object*, *x*, *y*, *param* +## `$D0`: anim_obj object, x, y, param -***Alternate*: `anim_obj` *object*, *x_tile*, *x*, *y_tile*, *y*, *param*** +***Alternate*: anim_obj object, x_tile, x, y_tile, y, param** Spawns an *object* at coordinate (*x*, *y*). @@ -29,22 +29,26 @@ The y position also depends on the y offset defined by the object. - *TODO: document each object* -## `$D1`: `anim_1gfx` *gfx* +## `$D1`: anim_1gfx gfx -## `$D2`: `anim_2gfx` *gfx1*, *gfx2* -## `$D3`: `anim_3gfx` *gfx1*, *gfx2*, *gfx3* +## `$D2`: anim_2gfx gfx1, gfx2 -## `$D4`: `anim_4gfx` *gfx1*, *gfx2*, *gfx3*, *gfx4* -## `$D5`: `anim_5gfx` *gfx1*, *gfx2*, *gfx3*, *gfx4*, *gfx5* +## `$D3`: anim_3gfx gfx1, gfx2, gfx3 + + +## `$D4`: anim_4gfx gfx1, gfx2, gfx3, gfx4 + + +## `$D5`: anim_5gfx gfx1, gfx2, gfx3, gfx4, gfx5 Loads 1-5 sets of graphics. Will overwrite any previously loaded sets. - *gfx*: `ANIM_GFX` constants (see [constants/battle_anim_constants.asm](/constants/battle_anim_constants.asm)) -## `$D6`: `anim_incobj` *object_id* +## `$D6`: anim_incobj object_id Increments an object's state. @@ -52,7 +56,8 @@ Increments an object's state. Objects are state machines. `anim_incobj` progresses the state of an object. -## `$D7`: `anim_setobj` *object_id*, *state* + +## `$D7`: anim_setobj object_id, state Sets an object's state to a specific value. @@ -61,7 +66,8 @@ Sets an object's state to a specific value. Objects are state machines. `anim_setobj` changes the state of an object. -## `$D8`: `anim_incbgeffect` *bg_effect* + +## `$D8`: anim_incbgeffect bg_effect Increments a bg effect's state. @@ -74,6 +80,7 @@ Since there can't be two of the same bg effect, the effect type is used. This is Temporarily creates sprites from the bottom row of the enemy frontpic, so that the player backpic can be moved around without corrupting the enemy frontpic. + ## `$DA`: `anim_playerheadobj` Temporarily creates sprites from the top row of the player backpic, so that the enemy frontpic can be moved around without corrupting the player backpic. @@ -86,8 +93,10 @@ Sets `BattleAnimVar` to the result of [GetPokeBallWobble](/engine/battle_anims/g ## `$DC`: `anim_transform` + ## `$DD`: `anim_raisesub` + ## `$DE`: `anim_dropsub` @@ -96,11 +105,12 @@ Sets `BattleAnimVar` to the result of [GetPokeBallWobble](/engine/battle_anims/g Resets rOBP0 to the default (`q0123` or `%00011011`). -## `$E0`: `anim_sound` *duration*, *tracks*, *sound_id* +## `$E0`: anim_sound duration, tracks, sound_id Plays a sound. -## `$E1`: `anim_cry` *pitch* + +## `$E1`: anim_cry pitch Plays the user's cry. @@ -110,6 +120,7 @@ Plays the user's cry. ## `$E3`: `anim_oamon` + ## `$E4`: `anim_oamoff` @@ -128,6 +139,7 @@ Does nothing. Unused. ## `$E8`: `anim_updateactorpic` + ## `$E9`: `anim_minimize` @@ -135,40 +147,46 @@ Does nothing. Unused. Does nothing. Unused. + ## `$EB`: `anim_0xeb` Does nothing. Unused. + ## `$EC`: `anim_0xec` Does nothing. Unused. + ## `$ED`: `anim_0xed` Does nothing. Unused. -## `$EE`: `anim_if_param_and` *value*, *address* +## `$EE`: anim_if_param_and value, address + -## `$EF`: `anim_jumpuntil` *address* +## `$EF`: anim_jumpuntil address Jumps to another script and decrements `param` until it reaches 0. Similar to `anim_loop`. -## `$F0`: `anim_bgeffect` *bg_effect*, *unknown1*, *unknown2*, *unknown3* +## `$F0`: anim_bgeffect bg_effect, unknown1, unknown2, unknown3 - *bg_effect*: `ANIM_BG` constants (see [constants/battle_anim_constants.asm](/constants/battle_anim_constants.asm)) -## `$F1`: `anim_bgp` *colors* +## `$F1`: anim_bgp colors Sets `rBGP` to *colors*. -## `$F2`: `anim_obp0` *colors* + +## `$F2`: anim_obp0 colors Sets `rOBP0` to *colors*. -## `$F3`: `anim_obp1` *colors* + +## `$F3`: anim_obp1 colors Sets `rOBP1` to *colors*. @@ -180,45 +198,54 @@ Sets `rOBP1` to *colors*. Does nothing. Unused. + ## `$F6`: `anim_0xf6` Does nothing. Unused. + ## `$F7`: `anim_0xf7` Does nothing. Unused. -## `$F8`: `anim_if_param_equal` *value*, *address* +## `$F8`: anim_if_param_equal value, address Jumps to another script if `wBattleAnimParam` (aka `wKickCounter` or `wPresentPower`) is equal to *value*. -## `$F9`: `anim_setvar` *value* + +## `$F9`: anim_setvar value Sets `BattleAnimVar` to *value*. + ## `$FA`: `anim_incvar` Increments `BattleAnimVar` by 1. -## `$FB`: `anim_if_var_equal` *value*, *address* + +## `$FB`: anim_if_var_equal value, address Jumps to another script if `BattleAnimVar` is equal to *value*. -## `$FC`: `anim_jump` *address* + +## `$FC`: anim_jump address Jumps to another script. -## `$FD`: `anim_loop` *count*, *address* + +## `$FD`: anim_loop count, address Jumps to another script up to *count* times. Then does nothing, allowing execution to continue. -## `$FE`: `anim_call` *address* + +## `$FE`: anim_call address Calls a script. There is no call stack. The return address is overwritten, so the maximum call depth is 1. + ## `$FF`: `anim_ret` Ends the script and returns to where it was called from. If there was no caller, the animation ends. diff --git a/docs/event_commands.md b/docs/event_commands.md index dfbe943f1..91486ad06 100644 --- a/docs/event_commands.md +++ b/docs/event_commands.md @@ -3,147 +3,147 @@ Defined in [macros/scripts/events.asm](/macros/scripts/events.asm) and [engine/scripting.asm:ScriptCommandTable](/engine/scripting.asm). -## `$00`: `scall` *script* +## `$00`: scall script -## `$01`: `farscall` *script* +## `$01`: farscall script -## `$02`: `ptcall` *script* +## `$02`: ptcall script -## `$03`: `jump` *script* +## `$03`: jump script -## `$04`: `farjump` *script* +## `$04`: farjump script -## `$05`: `ptjump` *script* +## `$05`: ptjump script -## `$06`: `if_equal` *byte*, *script* +## `$06`: if_equal byte, script -## `$07`: `if_not_equal` *byte*, *script* +## `$07`: if_not_equal byte, script -## `$08`: `iffalse` *script* +## `$08`: iffalse script -## `$09`: `iftrue` *script* +## `$09`: iftrue script -## `$0A`: `if_greater_than` *byte*, *script* +## `$0A`: if_greater_than byte, script -## `$0B`: `if_less_than` *byte*, *script* +## `$0B`: if_less_than byte, script -## `$0C`: `jumpstd` *std_script* +## `$0C`: jumpstd std_script -## `$0D`: `callstd` *std_script* +## `$0D`: callstd std_script -## `$0E`: `callasm` *asm* +## `$0E`: callasm asm -## `$0F`: `special` *special_pointer* +## `$0F`: special special_pointer -## `$10`: `ptcallasm` *asm* +## `$10`: ptcallasm asm -## `$11`: `checkmapscene` *map* +## `$11`: checkmapscene map -## `$12`: `setmapscene` *map*, *scene_id* +## `$12`: setmapscene map, scene_id ## `$13`: `checkscene` -## `$14`: `setscene` *scene_id* +## `$14`: setscene scene_id -## `$15`: `writebyte` *value* +## `$15`: writebyte value -## `$16`: `addvar` *value* +## `$16`: addvar value -## `$17`: `random` *value* +## `$17`: random value ## `$18`: `checkver` -## `$19`: `copybytetovar` *address* +## `$19`: copybytetovar address -## `$1A`: `copyvartobyte` *address* +## `$1A`: copyvartobyte address -## `$1B`: `loadvar` *address*, *value* +## `$1B`: loadvar address, value -## `$1C`: `checkcode` *variable* +## `$1C`: checkcode variable -## `$1D`: `writevarcode` *variable* +## `$1D`: writevarcode variable -## `$1E`: `writecode` *variable*, *value* +## `$1E`: writecode variable, value -## `$1F`: `giveitem` *item_id*[, *quantity*=1] +## `$1F`: giveitem item_id[, quantity=1] -## `$20`: `takeitem` *item_id*[, *quantity*=1] +## `$20`: takeitem item_id[, quantity=1] -## `$21`: `checkitem` *item_id* +## `$21`: checkitem item_id -## `$22`: `givemoney` *account*, *value* +## `$22`: givemoney account, value -## `$23`: `takemoney` *account*, *value* +## `$23`: takemoney account, value -## `$24`: `checkmoney` *account*, *value* +## `$24`: checkmoney account, value -## `$25`: `givecoins` *value* +## `$25`: givecoins value -## `$26`: `takecoins` *value* +## `$26`: takecoins value -## `$27`: `checkcoins` *value* +## `$27`: checkcoins value -## `$28`: `addcellnum` *contact_id* +## `$28`: addcellnum contact_id -## `$29`: `delcellnum` *contact_id* +## `$29`: delcellnum contact_id -## `$2A`: `checkcellnum` *contact_id* +## `$2A`: checkcellnum contact_id -## `$2B`: `checktime` *time* +## `$2B`: checktime time - **`checkmorn`:** `checktime MORN` - **`checkday`:** `checktime DAY` - **`checknite`:** `checktime NITE` -## `$2C`: `checkpoke` *mon_id* +## `$2C`: checkpoke mon_id -## `$2D`: `givepoke` *mon_id*, *level*[, *item*=0[, *trainer*=0, *ot_name*, *nickname*]] +## `$2D`: givepoke mon_id, level[, item=0[, trainer=0, ot_name, nickname]] -## `$2E`: `giveegg` *mon_id*, *level* +## `$2E`: giveegg mon_id, level -## `$2F`: `givepokeitem` *pointer* +## `$2F`: givepokeitem pointer -## `$30`: `checkpokeitem` *pointer* +## `$30`: checkpokeitem pointer -## `$31`: `checkevent` *event_flag* +## `$31`: checkevent event_flag -## `$32`: `clearevent` *event_flag* +## `$32`: clearevent event_flag -## `$33`: `setevent` *event_flag* +## `$33`: setevent event_flag -## `$34`: `checkflag` *engine_flag* +## `$34`: checkflag engine_flag -## `$35`: `clearflag` *engine_flag* +## `$35`: clearflag engine_flag -## `$36`: `setflag` *engine_flag* +## `$36`: setflag engine_flag ## `$37`: `wildon` ## `$38`: `wildoff` -## `$39`: `xycompare` *pointer* +## `$39`: xycompare pointer -## `$3A`: `warpmod` *warp_id*, *map* +## `$3A`: warpmod warp_id, map -## `$3B`: `blackoutmod` *map* +## `$3B`: blackoutmod map -## `$3C`: `warp` *map*, *x*, *y* +## `$3C`: warp map, x, y -## `$3D`: `readmoney` *account*, *memory* +## `$3D`: readmoney account, memory -## `$3E`: `readcoins` *memory* +## `$3E`: readcoins memory -## `$3F`: `vartomem` *memory* +## `$3F`: vartomem memory -## `$40`: `pokenamemem` *mon_id*, *memory* +## `$40`: pokenamemem mon_id, memory -## `$41`: `itemtotext` *item_id*, *memory* +## `$41`: itemtotext item_id, memory -## `$42`: `mapnametotext` *memory* +## `$42`: mapnametotext memory -## `$43`: `trainertotext` *trainer_id*, *trainer_group*, *memory* +## `$43`: trainertotext trainer_id, trainer_group, memory -## `$44`: `stringtotext` *text_pointer*, *memory* +## `$44`: stringtotext text_pointer, memory ## `$45`: `itemnotify` @@ -151,35 +151,35 @@ Defined in [macros/scripts/events.asm](/macros/scripts/events.asm) and [engine/s ## `$47`: `opentext` -## `$48`: `refreshscreen` [*dummy*=0] +## `$48`: refreshscreen [dummy=0] ## `$49`: `closetext` -## `$4A`: `loadbytec2cf` *byte* +## `$4A`: loadbytec2cf byte -## `$4B`: `farwritetext` *text_pointer* +## `$4B`: farwritetext text_pointer -## `$4C`: `writetext` *text_pointer* +## `$4C`: writetext text_pointer -## `$4D`: `repeattext` *byte1*, *byte2* +## `$4D`: repeattext byte1, byte2 ## `$4E`: `yesorno` -## `$4F`: `loadmenudata` *data_pointer* +## `$4F`: loadmenudata data_pointer ## `$50`: `closewindow` -## `$51`: `jumptextfaceplayer` *text_pointer* +## `$51`: jumptextfaceplayer text_pointer -## `$52`: `farjumptext` *text_pointer* +## `$52`: farjumptext text_pointer -## `$53`: `jumptext` *text_pointer* +## `$53`: jumptext text_pointer ## `$54`: `waitbutton` ## `$55`: `buttonsound` -## `$56`: `pokepic` *mon_id* +## `$56`: pokepic mon_id ## `$57`: `closepokepic` @@ -193,21 +193,21 @@ Defined in [macros/scripts/events.asm](/macros/scripts/events.asm) and [engine/s ## `$5C`: `loadmemtrainer` -## `$5D`: `loadwildmon` *mon_id*, *level* +## `$5D`: loadwildmon mon_id, level -## `$5E`: `loadtrainer` *trainer_group*, *trainer_id* +## `$5E`: loadtrainer trainer_group, trainer_id ## `$5F`: `startbattle` ## `$60`: `reloadmapafterbattle` -## `$61`: `catchtutorial` *byte* +## `$61`: catchtutorial byte -## `$62`: `trainertext` *which_text* +## `$62`: trainertext which_text -## `$63`: `trainerflagaction` *action* +## `$63`: trainerflagaction action -## `$64`: `winlosstext` *win_text_pointer*, *loss_text_pointer* +## `$64`: winlosstext win_text_pointer, loss_text_pointer ## `$65`: `scripttalkafter` @@ -215,65 +215,65 @@ Defined in [macros/scripts/events.asm](/macros/scripts/events.asm) and [engine/s ## `$67`: `check_just_battled` -## `$68`: `setlasttalked` *object_id* +## `$68`: setlasttalked object_id -## `$69`: `applymovement` *object_id*, *data_pointer* +## `$69`: applymovement object_id, data_pointer -## `$6A`: `applymovement2` *data_pointer* +## `$6A`: applymovement2 data_pointer ## `$6B`: `faceplayer` -## `$6C`: `faceobject` *object1*, *object2* +## `$6C`: faceobject object1, object2 -## `$6D`: `variablesprite` *variable_sprite_id*, *sprite_id* +## `$6D`: variablesprite variable_sprite_id, sprite_id -## `$6E`: `disappear` *object_id* +## `$6E`: disappear object_id -## `$6F`: `appear` *object_id* +## `$6F`: appear object_id -## `$70`: `follow` *object2*, *object1* +## `$70`: follow object2, object1 ## `$71`: `stopfollow` -## `$72`: `moveobject` *object_id*, *x*, *y* +## `$72`: moveobject object_id, x, y -## `$73`: `writeobjectxy` *object_id* +## `$73`: writeobjectxy object_id -## `$74`: `loademote` *emote_id* +## `$74`: loademote emote_id -## `$75`: `showemote` *emote_id*, *object_id*, *length* +## `$75`: showemote emote_id, object_id, length -## `$76`: `spriteface` *object_id*, *facing* +## `$76`: spriteface object_id, facing -## `$77`: `follownotexact` *object2*, *object1* +## `$77`: follownotexact object2, object1 -## `$78`: `earthquake` *param* +## `$78`: earthquake param -## `$79`: `changemap` *bank*, *blockdata_pointer* +## `$79`: changemap bank, blockdata_pointer -## `$7A`: `changeblock` *x*, *y*, *block* +## `$7A`: changeblock x, y, block ## `$7B`: `reloadmap` ## `$7C`: `reloadmappart` -## `$7D`: `writecmdqueue` *queue_pointer* +## `$7D`: writecmdqueue queue_pointer -## `$7E`: `delcmdqueue` *byte* +## `$7E`: delcmdqueue byte -## `$7F`: `playmusic` *music_id* +## `$7F`: playmusic music_id ## `$80`: `encountermusic` -## `$81`: `musicfadeout` *music_id*, *length* +## `$81`: musicfadeout music_id, length ## `$82`: `playmapmusic` ## `$83`: `dontrestartmapmusic` -## `$84`: `cry` *mon_id* +## `$84`: cry mon_id -## `$85`: `playsound` *sfx_id* +## `$85`: playsound sfx_id ## `$86`: `waitsfx` @@ -281,68 +281,68 @@ Defined in [macros/scripts/events.asm](/macros/scripts/events.asm) and [engine/s ## `$88`: `specialsound` -## `$89`: `passtoengine` *data_pointer* +## `$89`: passtoengine data_pointer -## `$8A`: `newloadmap` *which_method* +## `$8A`: newloadmap which_method -## `$8B`: `pause` *length* +## `$8B`: pause length -## `$8C`: `deactivatefacing` *length* +## `$8C`: deactivatefacing length -## `$8D`: `priorityjump` *script* +## `$8D`: priorityjump script ## `$8E`: `warpcheck` -## `$8F`: `ptpriorityjump` *script* +## `$8F`: ptpriorityjump script ## `$90`: `return` ## `$91`: `end` -## `$92`: `reloadandreturn` *which_method* +## `$92`: reloadandreturn which_method ## `$93`: `end_all` -## `$94`: `pokemart` *dialog_id*, *mart_id* +## `$94`: pokemart dialog_id, mart_id -## `$95`: `elevator` *floor_list* +## `$95`: elevator floor_list -## `$96`: `trade` *trade_id* +## `$96`: trade trade_id -## `$97`: `askforphonenumber` *contact_id* +## `$97`: askforphonenumber contact_id -## `$98`: `phonecall` *call_id* +## `$98`: phonecall call_id ## `$99`: `hangup` -## `$9A`: `describedecoration` *byte* +## `$9A`: describedecoration byte -## `$9B`: `fruittree` *tree_id* +## `$9B`: fruittree tree_id -## `$9C`: `specialphonecall` *call_id* +## `$9C`: specialphonecall call_id ## `$9D`: `checkphonecall` -## `$9E`: `verbosegiveitem` *item_id*[, *quantity*=1] +## `$9E`: verbosegiveitem item_id[, quantity=1] -## `$9F`: `verbosegiveitem2` *item_id*, *variable* +## `$9F`: verbosegiveitem2 item_id, variable -## `$A0`: `swarm` *swarm_id*, *map* +## `$A0`: swarm swarm_id, map ## `$A1`: `halloffame` ## `$A2`: `credits` -## `$A3`: `warpfacing` *facing*, *map*, *x*, *y* +## `$A3`: warpfacing facing, map, x, y -## `$A4`: `battletowertext` *memory* +## `$A4`: battletowertext memory -## `$A5`: `landmarktotext` *landmark_id*, *memory* +## `$A5`: landmarktotext landmark_id, memory -## `$A6`: `trainerclassname` *trainer_group*, *memory* +## `$A6`: trainerclassname trainer_group, memory -## `$A7`: `name` *type*, *id*, *memory* +## `$A7`: name type, id, memory -## `$A8`: `wait` *duration* +## `$A8`: wait duration ## `$A9`: `check_save` diff --git a/docs/map_scripts.md b/docs/map_scripts.md index 9eb924504..d9396ed5b 100644 --- a/docs/map_scripts.md +++ b/docs/map_scripts.md @@ -1,24 +1,24 @@ # Map Scripts -## `const_value set 2` +## const_value set 2
 	const MAPNAME_OBJECTNAME
 
-## `MapName_MapScripts:` +## MapName_MapScripts: -### `.SceneScripts: db` *N* +### .SceneScripts: db N
 	scene_script script
 
-### `.MapCallbacks: db` *N* +### .MapCallbacks: db N
 	callback type, script
@@ -67,7 +67,7 @@ Callback types:
 [Movement commands](movement_commands.md)
 
 
-## `MapName_MapEvents:`
+## MapName_MapEvents:
 
 ```asm
 	; filler
@@ -75,21 +75,21 @@ Callback types:
 ```
 
 
-### `.Warps: db` *N*
+### .Warps: db N
 
 
 	warp_def x, y, warp_id, map
 
-### `.CoordEvents: db` *N* +### .CoordEvents: db N
 	coord_event x, y, scene_id, script
 
-### `.BGEvents: db` *N* +### .BGEvents: db N
 	bg_event x, y, type, script
@@ -115,7 +115,7 @@ BG event types:
 
 - `BGEVENT_COPY`
 
-### `.ObjectEvents: db` *N*
+### .ObjectEvents: db N
 
 
 	object_event x, y, sprite, movement, rx, ry, h1, h2, palette, type, range, script, event_flag
diff --git a/docs/movement_commands.md b/docs/movement_commands.md
index 56b55f53e..10792c88b 100644
--- a/docs/movement_commands.md
+++ b/docs/movement_commands.md
@@ -3,33 +3,33 @@
 Defined in [macros/scripts/movement.asm](/macros/scripts/movement.asm) and [engine/movement.asm:MovementPointers](/engine/movement.asm).
 
 
-## `$00`−`$03`: `turn_head` *direction*
+## `$00`−`$03`: turn_head direction
 
-## `$04`−`$07`: `turn_step` *direction*
+## `$04`−`$07`: turn_step direction
 
-## `$08`−`$0B`: `slow_step` *direction*
+## `$08`−`$0B`: slow_step direction
 
-## `$0C`−`$0F`: `step` *direction*
+## `$0C`−`$0F`: step direction
 
-## `$10`−`$13`: `big_step` *direction*
+## `$10`−`$13`: big_step direction
 
-## `$14`−`$17`: `slow_slide_step` *direction*
+## `$14`−`$17`: slow_slide_step direction
 
-## `$18`−`$1B`: `slide_step` *direction*
+## `$18`−`$1B`: slide_step direction
 
-## `$1C`−`$1F`: `fast_slide_step` *direction*
+## `$1C`−`$1F`: fast_slide_step direction
 
-## `$20`−`$23`: `turn_away` *direction*
+## `$20`−`$23`: turn_away direction
 
-## `$24`−`$27`: `turn_in` *direction*
+## `$24`−`$27`: turn_in direction
 
-## `$28`−`$2B`: `turn_waterfall` *direction*
+## `$28`−`$2B`: turn_waterfall direction
 
-## `$2C`−`$2F`: `slow_jump_step` *direction*
+## `$2C`−`$2F`: slow_jump_step direction
 
-## `$30`−`$33`: `jump_step` *direction*
+## `$30`−`$33`: jump_step direction
 
-## `$34`−`$37`: `fast_jump_step` *direction*
+## `$34`−`$37`: fast_jump_step direction
 
 ## `$38`: `remove_sliding`
 
@@ -43,11 +43,11 @@ Defined in [macros/scripts/movement.asm](/macros/scripts/movement.asm) and [engi
 
 ## `$3D`: `hide_object`
 
-## `$3E`−`$46`: `step_sleep` *length*
+## `$3E`−`$46`: step_sleep length
 
 ## `$47`: `step_end`
 
-## `$48`: `step_48` *param*
+## `$48`: step_48 param
 
 ## `$49`: `remove_object`
 
@@ -61,7 +61,7 @@ Defined in [macros/scripts/movement.asm](/macros/scripts/movement.asm) and [engi
 
 ## `$4E`: `skyfall`
 
-## `$4F`: `step_dig` *length*
+## `$4F`: step_dig length
 
 ## `$50`: `step_bump`
 
@@ -73,12 +73,12 @@ Defined in [macros/scripts/movement.asm](/macros/scripts/movement.asm) and [engi
 
 ## `$54`: `show_emote`
 
-## `$55`: `step_shake` *displacement*
+## `$55`: step_shake displacement
 
 ## `$56`: `tree_shake`
 
-## `$57`: `rock_smash` *length*
+## `$57`: rock_smash length
 
-## `$58`: `return_dig` *length*
+## `$58`: return_dig length
 
 ## `$59`: `skyfall_top`
diff --git a/docs/music_commands.md b/docs/music_commands.md
index 7f7bd8b32..3329f8df1 100644
--- a/docs/music_commands.md
+++ b/docs/music_commands.md
@@ -5,27 +5,32 @@ Defined in [macros/scripts/audio.asm](/macros/scripts/audio.asm) and [audio/engi
 *See also: [Sound Engine Commands](https://github.com/pret/pokecrystal/wiki/Sound-Engine-Commands)*
 
 
-## `musicheader` *n*, *index*, *address*
+## musicheader n, index, address
 
-## `note` *pitch*, *length*
+
+## note pitch, length
 
 (Used on all channels)
 
 The high nibble is the note to play. 0 is rest, 1 is `C_`, 2 is `C#`, etc; `$C` is `B_`.
 The low nibble is the length of the note. 1 gets added to this, so 0 still has a length.
 
-## `sound` *pitch*, *octave*, *intensity*, *frequency*
 
-## `noise` *pitch*, *duration*, *intensity*, *frequency*
+## sound pitch, octave, intensity, frequency
+
+
+## noise pitch, duration, intensity, frequency
 
-## `$D0`−`$D7`: `octave` *n*
+
+## `$D0`−`$D7`: octave n
 
 (Used in channels 1-3)
 
 Sets the octave for the notes played on the channel.
 `$D7` is the lowest octave, whereas `$D0` is the highest.
 
-## `$D8`: `notetype` *length*[, *intensity*]
+
+## `$D8`: notetype length[, intensity]
 
 (Used in channels 1-4) (When using in channel 4, the *intensity* byte is not needed)
 
@@ -34,7 +39,8 @@ The first byte only reads the lower 4 bits, and multiplies it by the note length
 
 The second byte is identical to the first byte in the `intensity` command.
 
-## `$D9`: `pitchoffset` *octave*, *key*
+
+## `$D9`: pitchoffset octave, key
 
 (Used in channels 1-3)
 
@@ -42,7 +48,8 @@ Transposes all notes played on the channel by a value.
 The high nibble determins how many octaves to subtract, while the low nibble is how many note values to add.
 Ex: Setting a value of `$13` would make a `C_`4 play as a `D#`3.
 
-## `$DA`: `tempo` *tempo*
+
+## `$DA`: tempo tempo
 
 (Used in channel 1)
 
@@ -53,7 +60,8 @@ This formula also works backwards to convert BPM to tempo: Tempo = 19200 / BPM
 
 Only set or change this value when all playing channels are triggering a note or rest at the same time, otherwise desyncs may happen.
 
-## `$DB`: `dutycycle` *duty_cycle*
+
+## `$DB`: dutycycle duty_cycle
 
 (Used on channels 1&2)
 
@@ -64,7 +72,8 @@ Sets the square duty (sound) for the current channel. To change the sound for ch
 - 2 = 50% waveform: `____¯¯¯¯`
 - 3 = 75% waveform: `__¯¯¯¯¯¯` (sounds the same as 25%)
 
-## `$DC`: `intensity` *intensity*
+
+## `$DC`: intensity intensity
 
 (Used on channels 1-3) (Used to set instrument on channel 3)
 
@@ -74,9 +83,11 @@ This sets the volume and fade of the notes. The high nibble is the starting volu
 For channel 3:
 The high nibble sets the volume of channel 3. Only 4 values are accepted (0=Mute, 1=100% volume, 2=50% volume, 3=25% volume). The low nibble sets the instrument/waveform for channel 3 to play. Crystal natively has 10 instruments, values 0-9.
 
-## `$DD`: `soundinput` *input*
 
-## `$DE`: `sound_duty` *a*, *b*, *c*, *d*
+## `$DD`: soundinput input
+
+
+## `$DE`: sound_duty a, b, c, d
 
 (Used on channels 1&2)
 
@@ -84,9 +95,11 @@ This cycles the channel through 4 duty definitions, one per frame.
 Each pair of bits defines a duty, same as the `dutycycle` command.
 This is mostly only used in cries, SFX, and Jigglypuff's song in RBY.
 
+
 ## `$DF`: `togglesfx`
 
-## `$E0`: `slidepitchto` *duration*, *octave*, *pitch*
+
+## `$E0`: slidepitchto duration, octave, pitch
 
 (Used on channel 1)
 
@@ -95,7 +108,8 @@ The first byte tells how many frames to play the destination note for, before th
 The high nibble of the second byte is the octave of the destination note.
 The low nibble of the second byte is the destination note. If rest is used as the destination note, then the whole destination pitch becomes `$0000` (the lowest pitch).
 
-## `$E1`: `vibrato` *delay*, *extent*
+
+## `$E1`: vibrato delay, extent
 
 (Used on channels 1-3)
 
@@ -105,20 +119,23 @@ Second byte, high nibble is the speed timer. It will decrement by one each frame
 Second byte, low nibble is the pitch depth. Half of this value will alternate between adding to the pitch, and subtracting from the pitch each time speed timer resets. When this is an odd number, the value added to the pitch will be greater than the value subtracted from the pitch.
 Ex: normal pitch of 405, if pitch depth = 3, it will alternate between 407 and 404. Speed timer does NOT reset when a new note is played. only when the song stops or changes. (Also, because a timer counts 0, a timer of 5 will take 6 frames to change.)
 
-## `$E2`: `unknownmusic0xe2` *unknown*
 
-## `$E3`: `togglenoise` *id*
+## `$E2`: unknownmusic0xe2 unknown
+
+
+## `$E3`: togglenoise id
 
 (Used on channel 4)
 
 Sets the "drum kit" to be used. This needs to be called before channel 4 can make any noise.
 Calling it more than once in a song will mute the channel. (Keep it out of loops!)
 
-## `$E4`: `panning` *tracks*
 
-## `$E5`: `volume` *volume*
+## `$E4`: panning tracks
 
-## `$E6`: `tone` *tone*
+## `$E5`: volume volume
+
+## `$E6`: tone tone
 
 (Used on channel 1-3)
 
@@ -126,52 +143,77 @@ This modifies the pitch of the notes (fine tuning).
 It makes notes sound better if multiple channels play the same note simultaneously.
 A lot of GSC songs set the main melody channel with a value of 1, and the secondary channel (not bass) as 2.
 
-## `$E7`: `unknownmusic0xe7` *unknown*
 
-## `$E8`: `unknownmusic0xe8` *unknown*
+## `$E7`: unknownmusic0xe7 unknown
+
+
+## `$E8`: unknownmusic0xe8 unknown
+
+
+## `$E9`: tempo_relative value
 
-## `$E9`: `tempo_relative` *value*
 
-## `$EA`: `restartchannel` *address*
+## `$EA`: restartchannel address
 
-## `$EB`: `newsong` *id*
 
-## `$EC`: `sfxpriorityon`
+## `$EB`: newsong id
 
-## `$ED`: `sfxpriorityoff`
 
-## `$EE`: `unknownmusic0xee` *address*
+## `$EC`: sfxpriorityon
 
-## `$EF`: `stereopanning` *tracks*
 
-## `$F0`: `sfxtogglenoise` *id*
+## `$ED`: sfxpriorityoff
+
+
+## `$EE`: unknownmusic0xee address
+
+
+## `$EF`: stereopanning tracks
+
+
+## `$F0`: sfxtogglenoise id
+
 
 ## `$F1`: `music0xf1`
 
+
 ## `$F2`: `music0xf2`
 
+
 ## `$F3`: `music0xf3`
 
+
 ## `$F4`: `music0xf4`
 
+
 ## `$F5`: `music0xf5`
 
+
 ## `$F6`: `music0xf6`
 
+
 ## `$F7`: `music0xf7`
 
+
 ## `$F8`: `music0xf8`
 
+
 ## `$F9`: `unknownmusic0xf9`
 
-## `$FA`: `setcondition` *condition*
 
-## `$FB`: `jumpif` *condition*, *address*
+## `$FA`: setcondition condition
+
+
+## `$FB`: jumpif condition, address
+
+
+## `$FC`: jumpchannel address
+
+
+## `$FD`: loopchannel count, address
 
-## `$FC`: `jumpchannel` *address*
 
-## `$FD`: `loopchannel` *count*, *address*
+## `$FE`: callchannel address
 
-## `$FE`: `callchannel` *address*
 
 ## `$FF`: `endchannel`
diff --git a/docs/pic_animations.md b/docs/pic_animations.md
index ba11a1dc1..1075eb25b 100644
--- a/docs/pic_animations.md
+++ b/docs/pic_animations.md
@@ -5,9 +5,9 @@ Defined in [macros/scripts/gfx_anims.asm](/macros/scripts/gfx_anims.asm).
 Pic animations are assembled in 3 parts:
 
 - Top-level animations:
-   - `frame` *#*, *duration*: Frame 0 is the original pic (no change)
-   - `setrepeat` *#*: Sets the number of times to repeat
-   - `dorepeat` *#*: Repeats from command *#* (starting from 0)
+   - frame N, duration: Frame #0 is the original pic (no change)
+   - setrepeat N: Sets the number of times to repeat
+   - dorepeat I: Repeats from command #I (starting from 0)
    - `end`
 
 - Bitmasks:
diff --git a/docs/text_commands.md b/docs/text_commands.md
index b198d405d..801ce95e0 100644
--- a/docs/text_commands.md
+++ b/docs/text_commands.md
@@ -3,32 +3,32 @@
 Defined in [macros/scripts/text.asm](/macros/scripts/text.asm) and [home/text.asm:TextCommands](/home/text.asm).
 
 
-## `$00`: `text` *text*
+## `$00`: text text
 
 Start writing text until `"@"`.
 
 
-## `$4E`: `next` *text*
+## `$4E`: next text
 
 Move a line down.
 
 
-## `$4F`: `line` *text*
+## `$4F`: line text
 
 Start writing at the bottom line.
 
 
-## `$50`: `page` *text*
+## `$50`: page text
 
 Start a new Pokédex page.
 
 
-## `$51`: `para` *text*
+## `$51`: para text
 
 Start a new paragraph.
 
 
-## `$55`: `cont` *text*
+## `$55`: cont text
 
 Scroll to the next line.
 
@@ -43,24 +43,24 @@ End a text box.
 Prompt the player to end a text box (initiating some other event).
 
 
-## `$01`: `text_from_ram` *address*
+## `$01`: text_from_ram address
 
 Write text from a RAM address.
 
 
-## `$02`: `text_bcd` *address*, *flags*
+## `$02`: text_bcd address, flags
 
 Write [BCD][bcd] from an address, typically RAM.
 
 [bcd]: https://en.wikipedia.org/wiki/Binary-coded_decimal
 
 
-## `$03`: `text_move` *address*
+## `$03`: text_move address
 
 Move to a new tile.
 
 
-## `$04`: `text_box` *address*, *height*, *width*
+## `$04`: text_box address, height, width
 
 Draw a box.
 
@@ -86,7 +86,7 @@ first character column of the text box.
 Start interpreting assembly code.
 
 
-## `$09`: `deciram` *address*, *bytes*, *digits*
+## `$09`: deciram address, bytes, digits
 
 Read *bytes* bytes from *address* and print them as a *digits*-digit number.
 
@@ -101,7 +101,7 @@ Exit.
 Play `SFX_DEX_FANFARE_50_79`.
 
 
-## `$0C`: `limited_interpret_data` *number*
+## `$0C`: limited_interpret_data number
 
 Print *number* `"…"`s.
 
@@ -141,7 +141,7 @@ Play `SFX_FANFARE`.
 Play `SFX_SLOT_MACHINE_START`.
 
 
-## `$14`: `text_buffer` *id*
+## `$14`: text_buffer id
 
 Write text from one of the following addresses (listed in `StringBufferPointers`):
 
@@ -159,6 +159,6 @@ Write text from one of the following addresses (listed in `StringBufferPointers`
 Print the weekday.
 
 
-## `$16`: `text_jump` *address*
+## `$16`: text_jump address
 
 Write text from a different bank.
-- 
cgit v1.2.3


From b1c808f9f85c215340daccf7dc8eaa3832f15ba6 Mon Sep 17 00:00:00 2001
From: Remy Oukaour 
Date: Wed, 17 Jan 2018 14:50:34 -0500
Subject: Rename some tilesets (close #467)

---
 docs/map_scripts.md | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'docs')

diff --git a/docs/map_scripts.md b/docs/map_scripts.md
index d9396ed5b..2302257e7 100644
--- a/docs/map_scripts.md
+++ b/docs/map_scripts.md
@@ -118,7 +118,7 @@ BG event types:
 ### .ObjectEvents: db N
 
 
-	object_event x, y, sprite, movement, rx, ry, h1, h2, palette, type, range, script, event_flag
+	object_event x, y, sprite, movement, rx, ry, h1, h2, palette, type, range, script, event_flag
 
Movement types: -- cgit v1.2.3 From 40125a7f4d6450f4cc903234957c22d734fd0a42 Mon Sep 17 00:00:00 2001 From: Remy Oukaour Date: Wed, 17 Jan 2018 14:53:08 -0500 Subject:
--- docs/battle_anim_commands.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'docs') diff --git a/docs/battle_anim_commands.md b/docs/battle_anim_commands.md index 6d9ff4113..bd40e8a6d 100644 --- a/docs/battle_anim_commands.md +++ b/docs/battle_anim_commands.md @@ -10,7 +10,7 @@ Defined in [macros/scripts/battle_anims.asm](/macros/scripts/battle_anims.asm) a ## `$D0`: anim_obj object, x, y, param -***Alternate*: anim_obj object, x_tile, x, y_tile, y, param** +***Alternate*: anim_obj object, x_tile, x, y_tile, y, param** Spawns an *object* at coordinate (*x*, *y*). -- cgit v1.2.3 From 2acaa96cf16ce953a7149f300d54e5440abc27d8 Mon Sep 17 00:00:00 2001 From: Remy Oukaour Date: Thu, 18 Jan 2018 18:34:20 -0500 Subject: More charmap and home/text.asm documentation for JP chars --- docs/bugs_and_glitches.md | 4 ++-- docs/text_commands.md | 11 ++++++++--- 2 files changed, 10 insertions(+), 5 deletions(-) (limited to 'docs') diff --git a/docs/bugs_and_glitches.md b/docs/bugs_and_glitches.md index ef3855407..2cd47c540 100644 --- a/docs/bugs_and_glitches.md +++ b/docs/bugs_and_glitches.md @@ -567,7 +567,7 @@ This is a bug with `Text_ABoostedStringBuffer2ExpPoints` and `Text_StringBuffer2 ```asm Text_ABoostedStringBuffer2ExpPoints:: - text "" + text_start line "a boosted" cont "@" deciram StringBuffer2, 2, 4 @@ -575,7 +575,7 @@ Text_ABoostedStringBuffer2ExpPoints:: prompt Text_StringBuffer2ExpPoints:: - text "" + text_start line "@" deciram StringBuffer2, 2, 4 text " EXP. Points!" diff --git a/docs/text_commands.md b/docs/text_commands.md index 801ce95e0..5c797d828 100644 --- a/docs/text_commands.md +++ b/docs/text_commands.md @@ -101,9 +101,9 @@ Exit. Play `SFX_DEX_FANFARE_50_79`. -## `$0C`: limited_interpret_data number +## `$0C`: limited_interpret_data n -Print *number* `"…"`s. +Print *n* `"…"`s. ## `$0D`: `link_wait_button` @@ -143,7 +143,7 @@ Play `SFX_SLOT_MACHINE_START`. ## `$14`: text_buffer id -Write text from one of the following addresses (listed in `StringBufferPointers`): +Write text from one of the following addresses (listed in [data/text_buffers.asm](/data/text_buffers.asm)): 0. `StringBuffer3` 1. `StringBuffer4` @@ -162,3 +162,8 @@ Print the weekday. ## `$16`: text_jump address Write text from a different bank. + + +## `$00`: `text_start` + +Start writing regular text again after a special command. -- cgit v1.2.3 From 05382d3e3c03616d6edf21833e89a8264a8cd10a Mon Sep 17 00:00:00 2001 From: Remy Oukaour Date: Sat, 20 Jan 2018 12:25:55 -0500 Subject: PARTY_LENGTH; MON_NAME; sgb_border.bin --- docs/bugs_and_glitches.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'docs') diff --git a/docs/bugs_and_glitches.md b/docs/bugs_and_glitches.md index 2cd47c540..54f22c3df 100644 --- a/docs/bugs_and_glitches.md +++ b/docs/bugs_and_glitches.md @@ -746,7 +746,7 @@ Data_DaisyMassage: ; 746b CopyPokemonName_Buffer1_Buffer3: ; 746e ld hl, StringBuffer1 ld de, StringBuffer3 - ld bc, PKMN_NAME_LENGTH + ld bc, MON_NAME_LENGTH jp CopyBytes ``` -- cgit v1.2.3 From 7f54df58bfb00564874f8b6b3acef52a9aff7442 Mon Sep 17 00:00:00 2001 From: Remy Oukaour Date: Sun, 21 Jan 2018 18:00:23 -0500 Subject: Group engine/pokedex files --- docs/bugs_and_glitches.md | 2 +- docs/design_flaws.md | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'docs') diff --git a/docs/bugs_and_glitches.md b/docs/bugs_and_glitches.md index 54f22c3df..5abf9d08a 100644 --- a/docs/bugs_and_glitches.md +++ b/docs/bugs_and_glitches.md @@ -993,7 +993,7 @@ This is a bug with `DoPlayerMovement.CheckWarp` in [engine/player_movement.asm]( ([Video](https://www.youtube.com/watch?v=z305e4sIO24)) -The exact cause is unknown, but a workaround exists for `DexEntryScreen_MenuActionJumptable.Cry` in [engine/pokedex.asm](/engine/pokedex.asm): +The exact cause is unknown, but a workaround exists for `DexEntryScreen_MenuActionJumptable.Cry` in [engine/pokedex/pokedex.asm](/engine/pokedex/pokedex.asm): ```asm .Cry: ; 40340 diff --git a/docs/design_flaws.md b/docs/design_flaws.md index c856e8b38..7dc4d13db 100644 --- a/docs/design_flaws.md +++ b/docs/design_flaws.md @@ -228,7 +228,7 @@ INCBIN "gfx/footprints/wartortle.1bpp", footprint_bottom ... ``` -`Pokedex_LoadAnyFootprint` in [engine/pokedex.asm](/engine/pokedex.asm): +`Pokedex_LoadAnyFootprint` in [engine/pokedex/pokedex.asm](/engine/pokedex/pokedex.asm): ```asm push hl @@ -282,7 +282,7 @@ Modify `Pokedex_LoadAnyFootprint`: `PokedexDataPointerTable` in [data/pokemon/dex_entry_pointers.asm](/data/pokemon/dex_entry_pointers.asm) is a table of `dw`, not `dba`, yet there are four banks used for Pokédex entries. The correct bank is derived from the species ID at the beginning of each Pokémon's base stats. (This is the only use the base stat species ID has.) -Three separate routines do the same derivation; `GetDexEntryPointer` in [engine/pokedex_2.asm](/engine/pokedex_2.asm): +Three separate routines do the same derivation; `GetDexEntryPointer` in [engine/pokedex/pokedex_2.asm](/engine/pokedex/pokedex_2.asm): ```asm GetDexEntryPointer: ; 44333 -- cgit v1.2.3