diff options
| author | dannye <33dannye@gmail.com> | 2021-03-25 17:39:44 -0500 |
|---|---|---|
| committer | dannye <33dannye@gmail.com> | 2021-03-25 17:39:44 -0500 |
| commit | eb47bda8ee5c1f002236200df36012de9e243a97 (patch) | |
| tree | fc69fc5435582efebd36fc54414673dd8ac7f646 /constants | |
| parent | Merge remote-tracking branch 'remotes/pokered/master' (diff) | |
| parent | Verify data table and name list sizes with assertion macros (diff) | |
| download | pokeyellow-eb47bda8ee5c1f002236200df36012de9e243a97.tar.gz pokeyellow-eb47bda8ee5c1f002236200df36012de9e243a97.tar.xz pokeyellow-eb47bda8ee5c1f002236200df36012de9e243a97.zip | |
Merge branch 'master' of https://github.com/pret/pokered
Diffstat (limited to 'constants')
| -rw-r--r-- | constants/audio_constants.asm | 1 | ||||
| -rw-r--r-- | constants/battle_constants.asm | 35 | ||||
| -rw-r--r-- | constants/credits_constants.asm | 1 | ||||
| -rw-r--r-- | constants/gfx_constants.asm | 1 | ||||
| -rw-r--r-- | constants/hide_show_constants.asm | 1 | ||||
| -rw-r--r-- | constants/item_constants.asm | 4 | ||||
| -rw-r--r-- | constants/map_constants.asm | 1 | ||||
| -rw-r--r-- | constants/menu_constants.asm | 1 | ||||
| -rw-r--r-- | constants/move_animation_constants.asm | 3 | ||||
| -rw-r--r-- | constants/move_constants.asm | 6 | ||||
| -rw-r--r-- | constants/move_effect_constants.asm | 1 | ||||
| -rw-r--r-- | constants/palette_constants.asm | 1 | ||||
| -rw-r--r-- | constants/pokemon_data_constants.asm | 31 | ||||
| -rw-r--r-- | constants/script_constants.asm | 1 | ||||
| -rw-r--r-- | constants/sprite_constants.asm | 1 | ||||
| -rw-r--r-- | constants/tileset_constants.asm | 1 | ||||
| -rw-r--r-- | constants/trainer_constants.asm | 1 | ||||
| -rw-r--r-- | constants/type_constants.asm | 2 |
18 files changed, 86 insertions, 7 deletions
diff --git a/constants/audio_constants.asm b/constants/audio_constants.asm index e36d2d5f..69ec4e74 100644 --- a/constants/audio_constants.asm +++ b/constants/audio_constants.asm @@ -13,6 +13,7 @@ const A_ ; 9 const A# ; A const B_ ; B +NUM_NOTES EQU const_value ; channel ; Audio[1|2|3]_HWChannelBaseAddresses, Audio[1|2|3]_HWChannelDisableMasks, diff --git a/constants/battle_constants.asm b/constants/battle_constants.asm index 15ba42eb..8db305a5 100644 --- a/constants/battle_constants.asm +++ b/constants/battle_constants.asm @@ -1,9 +1,36 @@ MAX_LEVEL EQU 100 -NUM_MOVES EQU 4 -NUM_STATS EQU 5 -NUM_STAT_MODS EQU 8 -NUM_DVS EQU 2 +NUM_MOVES EQU 4 + +; VitaminStats indexes (see data/battle/stat_names.asm) + const_def + const STAT_HEALTH + const STAT_ATTACK + const STAT_DEFENSE + const STAT_SPEED + const STAT_SPECIAL +NUM_STATS EQU const_value + +; StatModTextStrings indexes (see data/battle/stat_mod_names.asm) + const_def + const MOD_ATTACK + const MOD_DEFENSE + const MOD_SPEED + const MOD_SPECIAL + const MOD_ACCURACY + const MOD_EVASION + const_skip 2 +NUM_STAT_MODS EQU const_value + +; Moves struct fields (see data/moves/moves.asm) +rsreset +MOVE_ANIM rb +MOVE_EFFECT rb +MOVE_POWER rb +MOVE_TYPE rb +MOVE_ACC rb +MOVE_PP rb +MOVE_LENGTH EQU _RS ; D733 flags BIT_TEST_BATTLE EQU 0 diff --git a/constants/credits_constants.asm b/constants/credits_constants.asm index b04ec0b8..ff2a5179 100644 --- a/constants/credits_constants.asm +++ b/constants/credits_constants.asm @@ -86,6 +86,7 @@ const CRED_NAKAMICHI ; 53 const CRED_YOSHIMURA ; 54 const CRED_YAMAZAKI ; 55 +NUM_CRED_STRINGS EQU const_value const_def -1, -1 const CRED_TEXT_FADE_MON ; $FF diff --git a/constants/gfx_constants.asm b/constants/gfx_constants.asm index 483bafa9..099ff2d7 100644 --- a/constants/gfx_constants.asm +++ b/constants/gfx_constants.asm @@ -42,3 +42,4 @@ REDRAW_ROW EQU 2 const TILEMAP_GENGAR_INTRO_3 const TILEMAP_GAME_BOY const TILEMAP_LINK_CABLE +NUM_TILEMAPS EQU const_value diff --git a/constants/hide_show_constants.asm b/constants/hide_show_constants.asm index 08bb2607..91205861 100644 --- a/constants/hide_show_constants.asm +++ b/constants/hide_show_constants.asm @@ -245,3 +245,4 @@ SHOW EQU $15 const HS_DAISY_SITTING_COPY ; EC const HS_DAISY_WALKING_COPY ; ED const HS_TOWN_MAP_COPY ; EE +NUM_HS_OBJECTS EQU const_value diff --git a/constants/item_constants.asm b/constants/item_constants.asm index 4cbc8534..e7cea725 100644 --- a/constants/item_constants.asm +++ b/constants/item_constants.asm @@ -92,6 +92,9 @@ SAFARI_ROCK EQU $16 ; overload const MAX_ETHER ; $51 const ELIXER ; $52 const MAX_ELIXER ; $53 +NUM_ITEMS EQU const_value - 1 + +; elevator floors use item IDs const FLOOR_B2F ; $54 const FLOOR_B1F ; $55 const FLOOR_1F ; $56 @@ -106,6 +109,7 @@ SAFARI_ROCK EQU $16 ; overload const FLOOR_10F ; $5F const FLOOR_11F ; $60 const FLOOR_B4F ; $61 +NUM_FLOORS EQU const_value - 1 - NUM_ITEMS const_next $C4 diff --git a/constants/map_constants.asm b/constants/map_constants.asm index b495552d..c365cd5b 100644 --- a/constants/map_constants.asm +++ b/constants/map_constants.asm @@ -267,6 +267,7 @@ FIRST_INDOOR_MAP EQU const_value mapconst BRUNOS_ROOM, 6, 5 ; $F6 mapconst AGATHAS_ROOM, 6, 5 ; $F7 mapconst SUMMER_BEACH_HOUSE, 4, 7 ; $F8 +NUM_MAPS EQU const_value ; Indoor maps, such as houses, use this as the Map ID in their exit warps ; This map ID takes the player back to the last outdoor map they were on, stored in wLastMap diff --git a/constants/menu_constants.asm b/constants/menu_constants.asm index a53adfdc..eafebe97 100644 --- a/constants/menu_constants.asm +++ b/constants/menu_constants.asm @@ -42,6 +42,7 @@ PC_ITEM_CAPACITY EQU 50 const TRADE_CANCEL_MENU ; 5 const HEAL_CANCEL_MENU ; 6 const NO_YES_MENU ; 7 +NUM_TWO_OPTION_MENUS EQU const_value ; menu exit method constants for list menus and the buy/sell/quit menu CHOSE_MENU_ITEM EQU 1 ; pressed A diff --git a/constants/move_animation_constants.asm b/constants/move_animation_constants.asm index f7617544..dc8c94fb 100644 --- a/constants/move_animation_constants.asm +++ b/constants/move_animation_constants.asm @@ -132,6 +132,7 @@ FIRST_SE_ID EQU const_value const SUBANIM_53 const SUBANIM_54 const SUBANIM_55 +NUM_SUBANIMS EQU const_value ; types of subanimations const_def @@ -267,6 +268,7 @@ FIRST_SE_ID EQU const_value const FRAMEBLOCK_77 const FRAMEBLOCK_78 const FRAMEBLOCK_79 +NUM_FRAMEBLOCKS EQU const_value ; base coordinates that are part of subanimations ; FrameBlockBaseCoords indexes (see data/battle_anims/base_coords.asm) @@ -448,6 +450,7 @@ FIRST_SE_ID EQU const_value const BASECOORD_AE const BASECOORD_AF const BASECOORD_B0 +NUM_BASECOORDS EQU const_value ; frame block modes that are part of subanimations const_def diff --git a/constants/move_constants.asm b/constants/move_constants.asm index ecc28078..52c44210 100644 --- a/constants/move_constants.asm +++ b/constants/move_constants.asm @@ -170,10 +170,8 @@ const SUPER_FANG ; a2 const SLASH ; a3 const SUBSTITUTE ; a4 - -NUM_ATTACKS EQU const_value - 1 - const STRUGGLE ; a5 +NUM_ATTACKS EQU const_value - 1 ; Moves do double duty as animation identifiers. @@ -214,3 +212,5 @@ NUM_ATTACKS EQU const_value - 1 const HIDEPIC_ANIM ; monster disappears const ROCK_ANIM ; throw rock const BAIT_ANIM ; throw bait + +NUM_ATTACK_ANIMS EQU const_value - 1 diff --git a/constants/move_effect_constants.asm b/constants/move_effect_constants.asm index 4c6d0c38..9b895490 100644 --- a/constants/move_effect_constants.asm +++ b/constants/move_effect_constants.asm @@ -91,3 +91,4 @@ const LEECH_SEED_EFFECT ; $54 const SPLASH_EFFECT ; $55 const DISABLE_EFFECT ; $56 +NUM_MOVE_EFFECTS EQU const_value - 1 diff --git a/constants/palette_constants.asm b/constants/palette_constants.asm index 00b5748d..0fb63b74 100644 --- a/constants/palette_constants.asm +++ b/constants/palette_constants.asm @@ -75,3 +75,4 @@ SET_PAL_DEFAULT EQU $ff const PAL_25 ; $25 const PAL_26 ; $26 const PAL_27 ; $27 +NUM_SGB_PALS EQU const_value diff --git a/constants/pokemon_data_constants.asm b/constants/pokemon_data_constants.asm index a0e5b257..6670f777 100644 --- a/constants/pokemon_data_constants.asm +++ b/constants/pokemon_data_constants.asm @@ -1,3 +1,29 @@ +; base data struct members (see data/pokemon/base_stats/*.asm) +rsreset +BASE_DEX_NO rb +BASE_STATS rb NUM_STATS +rsset BASE_STATS +BASE_HP rb +BASE_ATK rb +BASE_DEF rb +BASE_SPD rb +BASE_SPC rb +BASE_TYPES rw +rsset BASE_TYPES +BASE_TYPE_1 rb +BASE_TYPE_2 rb +BASE_CATCH_RATE rb +BASE_EXP rb +BASE_PIC_SIZE rb +BASE_FRONTPIC rw +BASE_BACKPIC rw +BASE_MOVES rb NUM_MOVES +BASE_GROWTH_RATE rb +BASE_TMHM rb (NUM_TM_HM + 7) / 8 + rb_skip +BASE_DATA_SIZE EQU _RS + + PARTY_LENGTH EQU 6 MONS_PER_BOX EQU 20 @@ -39,3 +65,8 @@ EVOLUTION_SIZE EQU 4 const GROWTH_MEDIUM_SLOW const GROWTH_FAST const GROWTH_SLOW +NUM_GROWTH_RATES EQU const_value + +; wild data (see data/wild/maps/*.asm) +NUM_WILDMONS EQU 10 +WILDDATA_LENGTH EQU 1 + NUM_WILDMONS * 2 diff --git a/constants/script_constants.asm b/constants/script_constants.asm index e7d23e97..3195e7f4 100644 --- a/constants/script_constants.asm +++ b/constants/script_constants.asm @@ -35,6 +35,7 @@ SLOTS_SOMEONESKEYS EQU $ff const TRADE_FOR_DORIS const TRADE_FOR_CRINKLES const TRADE_FOR_SPOT +NUM_NPC_TRADES EQU const_value ; in game trade dialog sets ; InGameTradeTextPointers indexes (see engine/events/in_game_trades.asm) diff --git a/constants/sprite_constants.asm b/constants/sprite_constants.asm index 2613f707..2807663e 100644 --- a/constants/sprite_constants.asm +++ b/constants/sprite_constants.asm @@ -85,3 +85,4 @@ FIRST_STILL_SPRITE EQU const_value const SPRITE_UNUSED_GAMBLER_ASLEEP_1 ; $50 const SPRITE_UNUSED_GAMBLER_ASLEEP_2 ; $51 const SPRITE_GAMBLER_ASLEEP ; $52 +NUM_SPRITES EQU const_value - 1 diff --git a/constants/tileset_constants.asm b/constants/tileset_constants.asm index 3991ac4d..a07f9eb9 100644 --- a/constants/tileset_constants.asm +++ b/constants/tileset_constants.asm @@ -26,3 +26,4 @@ const FACILITY ; 22 const PLATEAU ; 23 const BEACH_HOUSE ; 24 +NUM_TILESETS EQU const_value diff --git a/constants/trainer_constants.asm b/constants/trainer_constants.asm index 6fdc5d4e..14b662f3 100644 --- a/constants/trainer_constants.asm +++ b/constants/trainer_constants.asm @@ -62,3 +62,4 @@ ENDM trainer_const CHANNELER ; $2D trainer_const AGATHA ; $2E trainer_const LANCE ; $2F +NUM_TRAINERS EQU const_value - 1 diff --git a/constants/type_constants.asm b/constants/type_constants.asm index 6ae3408d..24817c20 100644 --- a/constants/type_constants.asm +++ b/constants/type_constants.asm @@ -22,3 +22,5 @@ SPECIAL EQU const_value const PSYCHIC_TYPE ; $18 const ICE ; $19 const DRAGON ; $1A + +NUM_TYPES EQU const_value |
