diff options
| author | Yoann Fievez <yoann.fievez@gmail.com> | 2026-06-24 20:43:48 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-06-24 14:43:48 -0400 |
| commit | d150f7f4f49e9dda08c52199159b30ae9b4f00e8 (patch) | |
| tree | e0c81ae315ccdf2952c10713312427f2c55e1fea /scripts/BillsHouse_2.asm | |
| parent | Use OAM constants and decimal coordinates in surfing_pikachu_oam.asm (#157) (diff) | |
| download | pokeyellow-d150f7f4f49e9dda08c52199159b30ae9b4f00e8.tar.gz pokeyellow-d150f7f4f49e9dda08c52199159b30ae9b4f00e8.tar.xz pokeyellow-d150f7f4f49e9dda08c52199159b30ae9b4f00e8.zip | |
Identify `wPikachuSpawnStateFlags` and `wPikachuMapScriptFlags` bits, and `PIKAMOVEMENT_*` constants (#158)
- Rename `wd471` to` wPikachuSpawnStateFlags`, with `BIT_PIKACHU_SPAWN_*` bits
- Rename `wd492` to `wPikachuMapScriptFlags`, with `BIT_PIKACHU_MAP_*` bits
- Introduce `PIKAMOVEMENT_*` constants for `ApplyPikachuMovementData`
- Refactor `BillsHouse` scripts and Pikachu/Bill movement data
Diffstat (limited to 'scripts/BillsHouse_2.asm')
| -rw-r--r-- | scripts/BillsHouse_2.asm | 60 |
1 files changed, 30 insertions, 30 deletions
diff --git a/scripts/BillsHouse_2.asm b/scripts/BillsHouse_2.asm index 4a897d87..b8c7997d 100644 --- a/scripts/BillsHouse_2.asm +++ b/scripts/BillsHouse_2.asm @@ -81,12 +81,12 @@ BillsHousePrintBillCheckOutMyRarePokemonText:: text_far _BillsHouseBillCheckOutMyRarePokemonText text_end -Func_f24ae:: +BillsHouse_CheckPikachuEmotion:: ld a, [wCurMap] cp BILLS_HOUSE - jr nz, .asm_f24d2 + jr nz, .noEmotion call CheckPikachuFollowingPlayer - jr z, .asm_f24d2 + jr z, .noEmotion ld a, [wBillsHouseCurScript] cp SCRIPT_BILLSHOUSE_SCRIPT5 ldpikaemotion e, PikachuEmotion27 @@ -100,18 +100,18 @@ Func_f24ae:: ldpikaemotion e, PikachuEmotion31 ret -.asm_f24d2 +.noEmotion ld e, $ff ret -Func_f24d5:: +BillsHousePikachuConfused:: ld a, PAD_BUTTONS | PAD_CTRL_PAD ld [wJoyIgnore], a xor a ld [wPlayerMovingDirection], a call UpdateSprites call UpdateSprites - ld hl, Data_f2505 + ld hl, PikachuMovement_Confused call ApplyPikachuMovementData ld a, $f ; pikachu ld [wEmotionBubbleSpriteIndex], a @@ -122,35 +122,35 @@ Func_f24d5:: callfar InitializePikachuTextID ret -Data_f2505: - db $00 - db $20 - db $20 - db $20 - db $1e - db $3f +PikachuMovement_Confused: + db PIKAMOVEMENT_DELAY + db PIKAMOVEMENT_STEP_RIGHT + db PIKAMOVEMENT_STEP_RIGHT + db PIKAMOVEMENT_STEP_RIGHT + db PIKAMOVEMENT_STEP_UP + db PIKAMOVEMENT_END -Func_f250b:: - ld hl, Data_f251c +BillsHousePikachuWatchPlayer:: + ld hl, PikachuMovement_WatchPlayer1 ld b, SPRITE_FACING_UP call TryApplyPikachuMovementData - ld hl, Data_f2521 + ld hl, PikachuMovement_WatchPlayer2 ld b, SPRITE_FACING_RIGHT call TryApplyPikachuMovementData ret -Data_f251c: - db $00 - db $1f - db $1d - db $38 - db $3f +PikachuMovement_WatchPlayer1: + db PIKAMOVEMENT_DELAY + db PIKAMOVEMENT_STEP_LEFT + db PIKAMOVEMENT_STEP_DOWN + db PIKAMOVEMENT_LOOK_RIGHT + db PIKAMOVEMENT_END -Data_f2521: - db $00 - db $1e - db $1f - db $1f - db $1d - db $38 - db $3f +PikachuMovement_WatchPlayer2: + db PIKAMOVEMENT_DELAY + db PIKAMOVEMENT_STEP_UP + db PIKAMOVEMENT_STEP_LEFT + db PIKAMOVEMENT_STEP_LEFT + db PIKAMOVEMENT_STEP_DOWN + db PIKAMOVEMENT_LOOK_RIGHT + db PIKAMOVEMENT_END |
