diff options
| author | Sylvie <35663410+Rangi42@users.noreply.github.com> | 2024-07-16 13:02:54 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-07-16 13:02:54 -0400 |
| commit | 8fafca714c07500d1d87bba224f12cf9cc2c8789 (patch) | |
| tree | 273ca88fcfcd80df9c318c9cb8d17a1f7aa240cb /constants | |
| parent | Build with RGBDS 0.8.0, though it is not yet required (diff) | |
| download | pokeyellow-8fafca714c07500d1d87bba224f12cf9cc2c8789.tar.gz pokeyellow-8fafca714c07500d1d87bba224f12cf9cc2c8789.tar.xz pokeyellow-8fafca714c07500d1d87bba224f12cf9cc2c8789.zip | |
Identify various flag labels and bit constants (#454)
Diffstat (limited to 'constants')
| -rw-r--r-- | constants/battle_constants.asm | 9 | ||||
| -rw-r--r-- | constants/input_constants.asm | 16 | ||||
| -rw-r--r-- | constants/misc_constants.asm | 12 | ||||
| -rw-r--r-- | constants/ram_constants.asm | 119 | ||||
| -rw-r--r-- | constants/script_constants.asm | 13 |
5 files changed, 130 insertions, 39 deletions
diff --git a/constants/battle_constants.asm b/constants/battle_constants.asm index 44a85e8d..9349bb75 100644 --- a/constants/battle_constants.asm +++ b/constants/battle_constants.asm @@ -37,9 +37,6 @@ DEF MOVE_ACC rb DEF MOVE_PP rb DEF MOVE_LENGTH EQU _RS -; D733 flags -DEF BIT_TEST_BATTLE EQU 0 - ; battle type constants (wBattleType values) const_def const BATTLE_TYPE_NORMAL ; 0 @@ -78,7 +75,7 @@ DEF SPDSPCDV_TRAINER EQU $88 ; wPlayerBattleStatus1 or wEnemyBattleStatus1 bit flags const_def const STORING_ENERGY ; 0 ; Bide - const THRASHING_ABOUT ; 1 ; e.g. Thrash + const THRASHING_ABOUT ; 1 ; Thrash, Petal Dance const ATTACKING_MULTIPLE_TIMES ; 2 ; e.g. Double Kick, Fury Attack const FLINCHED ; 3 const CHARGING_UP ; 4 ; e.g. Solar Beam, Fly @@ -95,11 +92,11 @@ DEF SPDSPCDV_TRAINER EQU $88 const HAS_SUBSTITUTE_UP ; 4 const NEEDS_TO_RECHARGE ; 5 ; Hyper Beam const USING_RAGE ; 6 - const SEEDED ; 7 + const SEEDED ; 7 ; Leech Seed ; wPlayerBattleStatus3 or wEnemyBattleStatus3 bit flags const_def - const BADLY_POISONED ; 0 + const BADLY_POISONED ; 0 ; Toxic const HAS_LIGHT_SCREEN_UP ; 1 const HAS_REFLECT_UP ; 2 const TRANSFORMED ; 3 diff --git a/constants/input_constants.asm b/constants/input_constants.asm index f9070cba..68233dea 100644 --- a/constants/input_constants.asm +++ b/constants/input_constants.asm @@ -1,13 +1,13 @@ ; joypad buttons const_def - const BIT_A_BUTTON - const BIT_B_BUTTON - const BIT_SELECT - const BIT_START - const BIT_D_RIGHT - const BIT_D_LEFT - const BIT_D_UP - const BIT_D_DOWN + const BIT_A_BUTTON ; 0 + const BIT_B_BUTTON ; 1 + const BIT_SELECT ; 2 + const BIT_START ; 3 + const BIT_D_RIGHT ; 4 + const BIT_D_LEFT ; 5 + const BIT_D_UP ; 6 + const BIT_D_DOWN ; 7 DEF NO_INPUT EQU 0 DEF A_BUTTON EQU 1 << BIT_A_BUTTON diff --git a/constants/misc_constants.asm b/constants/misc_constants.asm index a230b3d7..3562042b 100644 --- a/constants/misc_constants.asm +++ b/constants/misc_constants.asm @@ -7,15 +7,3 @@ DEF TRUE EQU 1 const FLAG_RESET ; 0 const FLAG_SET ; 1 const FLAG_TEST ; 2 - -; wOptions -DEF TEXT_DELAY_FAST EQU %001 ; 1 -DEF TEXT_DELAY_MEDIUM EQU %011 ; 3 -DEF TEXT_DELAY_SLOW EQU %101 ; 5 - - const_def 6 - const BIT_BATTLE_SHIFT ; 6 - const BIT_BATTLE_ANIMATION ; 7 - -; wd732 flags -DEF BIT_DEBUG_MODE EQU 1 diff --git a/constants/ram_constants.asm b/constants/ram_constants.asm new file mode 100644 index 00000000..42956cc6 --- /dev/null +++ b/constants/ram_constants.asm @@ -0,0 +1,119 @@ +; wMiscFlags + const_def + const BIT_SEEN_BY_TRAINER ; 0 + const BIT_BOULDER_DUST ; 1 + const BIT_TURNING ; 2 + const BIT_USING_GENERIC_PC ; 3 + const BIT_NO_SPRITE_UPDATES ; 4 + const BIT_NO_MENU_BUTTON_SOUND ; 5 + const BIT_TRIED_PUSH_BOULDER ; 6 + const BIT_PUSHED_BOULDER ; 7 + +; wOptions +DEF TEXT_DELAY_MASK EQU %111 + const_def 6 + const BIT_BATTLE_SHIFT ; 6 + const BIT_BATTLE_ANIMATION ; 7 + +DEF TEXT_DELAY_FAST EQU %001 ; 1 +DEF TEXT_DELAY_MEDIUM EQU %011 ; 3 +DEF TEXT_DELAY_SLOW EQU %101 ; 5 + +; wLetterPrintingDelayFlags + const_def + const BIT_FAST_TEXT_DELAY ; 0 + const BIT_TEXT_DELAY ; 1 + +; wObtainedBadges, wBeatGymFlags + const_def + const BIT_BOULDERBADGE ; 0 + const BIT_CASCADEBADGE ; 1 + const BIT_THUNDERBADGE ; 2 + const BIT_RAINBOWBADGE ; 3 + const BIT_SOULBADGE ; 4 + const BIT_MARSHBADGE ; 5 + const BIT_VOLCANOBADGE ; 6 + const BIT_EARTHBADGE ; 7 +DEF NUM_BADGES EQU const_value + +; wStatusFlags1 + const_def + const BIT_STRENGTH_ACTIVE ; 0 + const BIT_SURF_ALLOWED ; 1 + const_skip ; 2 ; unused + const BIT_GOT_OLD_ROD ; 3 + const BIT_GOT_GOOD_ROD ; 4 + const BIT_GOT_SUPER_ROD ; 5 + const BIT_GAVE_SAFFRON_GUARDS_DRINK ; 6 + const BIT_UNUSED_CARD_KEY ; 7 + +; wStatusFlags2 + const_def + const BIT_WILD_ENCOUNTER_COOLDOWN ; 0 + const BIT_NO_AUDIO_FADE_OUT ; 1 + +; wStatusFlags3 + const_def + const BIT_INIT_TRADE_CENTER_FACING ; 0 + const_skip 2 ; 1-2 ; unused + const BIT_WARP_FROM_CUR_SCRIPT ; 3 + const BIT_ON_DUNGEON_WARP ; 4 + const BIT_NO_NPC_FACE_PLAYER ; 5 + const BIT_TALKED_TO_TRAINER ; 6 + const BIT_PRINT_END_BATTLE_TEXT ; 7 + +; wStatusFlags4 + const_def + const BIT_GOT_LAPRAS ; 0 + const BIT_UNKNOWN_4_1 ; 1 + const BIT_USED_POKECENTER ; 2 + const BIT_GOT_STARTER ; 3 + const BIT_NO_BATTLES ; 4 + const BIT_BATTLE_OVER_OR_BLACKOUT ; 5 + const BIT_LINK_CONNECTED ; 6 + const BIT_INIT_SCRIPTED_MOVEMENT ; 7 + +; wStatusFlags5 + const_def + const BIT_SCRIPTED_NPC_MOVEMENT ; 0 + const BIT_UNKNOWN_5_1 ; 1 + const BIT_UNKNOWN_5_2 ; 2 + const_skip ; 3 ; unused + const BIT_UNKNOWN_5_4 ; 4 + const BIT_DISABLE_JOYPAD ; 5 + const BIT_NO_TEXT_DELAY ; 6 + const BIT_SCRIPTED_MOVEMENT_STATE ; 7 + +; wStatusFlags6 + const_def + const BIT_GAME_TIMER_COUNTING ; 0 + const BIT_DEBUG_MODE ; 1 + const BIT_FLY_OR_DUNGEON_WARP ; 2 + const BIT_FLY_WARP ; 3 + const BIT_DUNGEON_WARP ; 4 + const BIT_ALWAYS_ON_BIKE ; 5 + const BIT_ESCAPE_WARP ; 6 + +; wStatusFlags7 + const_def + const BIT_TEST_BATTLE ; 0 + const BIT_NO_MAP_MUSIC ; 1 + const BIT_FORCED_WARP ; 2 + const BIT_TRAINER_BATTLE ; 3 + const BIT_USE_CUR_MAP_SCRIPT ; 4 + const_skip 2 ; 5-6 ; unused + const BIT_USED_FLY ; 7 + +; wElite4Flags + const_def + const BIT_UNUSED_BEAT_ELITE_4 ; 0 + const BIT_STARTED_ELITE_4 ; 1 + +; wMovementFlags + const_def + const BIT_STANDING_ON_DOOR ; 0 + const BIT_EXITING_DOOR ; 1 + const BIT_STANDING_ON_WARP ; 2 + const_skip 3 ; 3-5 ; unused + const BIT_LEDGE_OR_FISHING ; 6 + const BIT_SPINNING ; 7 diff --git a/constants/script_constants.asm b/constants/script_constants.asm index afd1258b..24ad93f2 100644 --- a/constants/script_constants.asm +++ b/constants/script_constants.asm @@ -39,19 +39,6 @@ DEF NUM_NPC_TRADES EQU const_value const TRADE_DIALOGSET_EVOLUTION const TRADE_DIALOGSET_HAPPY -; badges -; wObtainedBadges and wBeatGymFlags bits - const_def - const BIT_BOULDERBADGE ; 0 - const BIT_CASCADEBADGE ; 1 - const BIT_THUNDERBADGE ; 2 - const BIT_RAINBOWBADGE ; 3 - const BIT_SOULBADGE ; 4 - const BIT_MARSHBADGE ; 5 - const BIT_VOLCANOBADGE ; 6 - const BIT_EARTHBADGE ; 7 -DEF NUM_BADGES EQU const_value - ; OaksAideScript results DEF OAKS_AIDE_BAG_FULL EQU $00 DEF OAKS_AIDE_GOT_ITEM EQU $01 |
