diff options
| author | Daniel Harding <33dannye@gmail.com> | 2020-06-23 19:06:14 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-06-23 19:06:14 -0500 |
| commit | ff927ba730e45a843c1e183b5f05646f96378af0 (patch) | |
| tree | 530f89782772bb76a76fbdd28247f1c6e3248483 /engine/overworld/player_state.asm | |
| parent | Merge pull request #243 from Nog-Frog/rename-unused-cd40 (diff) | |
| parent | Move more tables from engine/ to data/ (diff) | |
| download | pokeyellow-ff927ba730e45a843c1e183b5f05646f96378af0.tar.gz pokeyellow-ff927ba730e45a843c1e183b5f05646f96378af0.tar.xz pokeyellow-ff927ba730e45a843c1e183b5f05646f96378af0.zip | |
Merge pull request #250 from Rangi42/master
Move more tables from engine/ to data/
Diffstat (limited to 'engine/overworld/player_state.asm')
| -rw-r--r-- | engine/overworld/player_state.asm | 28 |
1 files changed, 6 insertions, 22 deletions
diff --git a/engine/overworld/player_state.asm b/engine/overworld/player_state.asm index 73c55da2..ba47f7eb 100644 --- a/engine/overworld/player_state.asm +++ b/engine/overworld/player_state.asm @@ -157,12 +157,12 @@ IsWarpTileInFrontOfPlayer: call _GetTileAndCoordsInFrontOfPlayer ld a, [wCurMap] cp SS_ANNE_BOW - jr z, .ssAnne5 + jr z, IsSSAnneBowWarpTileInFrontOfPlayer ld a, [wSpriteStateData1 + 9] ; player sprite's facing direction srl a ld c, a ld b, 0 - ld hl, .warpTileListPointers + ld hl, WarpTileListPointers add hl, bc ld a, [hli] ld h, [hl] @@ -176,33 +176,17 @@ IsWarpTileInFrontOfPlayer: pop hl ret -.warpTileListPointers: - dw .facingDownWarpTiles - dw .facingUpWarpTiles - dw .facingLeftWarpTiles - dw .facingRightWarpTiles +INCLUDE "data/warp_carpet_tile_ids.asm" -.facingDownWarpTiles - db $01,$12,$17,$3D,$04,$18,$33,$FF - -.facingUpWarpTiles - db $01,$5C,$FF - -.facingLeftWarpTiles - db $1A,$4B,$FF - -.facingRightWarpTiles - db $0F,$4E,$FF - -.ssAnne5 +IsSSAnneBowWarpTileInFrontOfPlayer: ld a, [wTileInFrontOfPlayer] cp $15 jr nz, .notSSAnne5Warp scf - jr .done + jr IsWarpTileInFrontOfPlayer.done .notSSAnne5Warp and a - jr .done + jr IsWarpTileInFrontOfPlayer.done IsPlayerStandingOnDoorTileOrWarpTile: push hl |
