Rename the object_struct field labels and constants (#1005)

Fixes #990
This commit is contained in:
Rangi
2022-09-12 09:15:44 -04:00
committed by GitHub
parent 4c239a6f65
commit 41d5ea0482
30 changed files with 442 additions and 431 deletions

View File

@@ -138,19 +138,19 @@ FacingPlayerDistance::
; Return carry if the sprite at bc is facing the player,
; its distance in d, and its direction in e.
ld hl, OBJECT_NEXT_MAP_X ; x
ld hl, OBJECT_MAP_X ; x
add hl, bc
ld d, [hl]
ld hl, OBJECT_NEXT_MAP_Y ; y
ld hl, OBJECT_MAP_Y ; y
add hl, bc
ld e, [hl]
ld a, [wPlayerStandingMapX]
ld a, [wPlayerMapX]
cp d
jr z, .CheckY
ld a, [wPlayerStandingMapY]
ld a, [wPlayerMapY]
cp e
jr z, .CheckX
@@ -158,7 +158,7 @@ FacingPlayerDistance::
ret
.CheckY:
ld a, [wPlayerStandingMapY]
ld a, [wPlayerMapY]
sub e
jr z, .NotFacing
jr nc, .Above
@@ -176,7 +176,7 @@ FacingPlayerDistance::
jr .CheckFacing
.CheckX:
ld a, [wPlayerStandingMapX]
ld a, [wPlayerMapX]
sub d
jr z, .NotFacing
jr nc, .Left