summaryrefslogtreecommitdiff
path: root/engine/overworld/hidden_objects.asm
diff options
context:
space:
mode:
authorluckytyphlosion <alan.rj.huang@gmail.com>2015-08-30 17:55:02 -0400
committerluckytyphlosion <alan.rj.huang@gmail.com>2015-08-30 17:55:02 -0400
commitd2ed7674f499b1fd6c4059da40b8b42c6bf96995 (patch)
treef581489b522fc647477d7b36dee072d553c44fd1 /engine/overworld/hidden_objects.asm
parent3394d8320f35f524231aa13bd9cae34e22246a6d (diff)
parent1a987d1e1ab96ca9553d4253c72858057332a03a (diff)
Merge branch 'master' of https://github.com/iimarckus/pokered
Doesn't build.
Diffstat (limited to 'engine/overworld/hidden_objects.asm')
-rwxr-xr-xengine/overworld/hidden_objects.asm10
1 files changed, 5 insertions, 5 deletions
diff --git a/engine/overworld/hidden_objects.asm b/engine/overworld/hidden_objects.asm
index ae67aeed..cabfc093 100755
--- a/engine/overworld/hidden_objects.asm
+++ b/engine/overworld/hidden_objects.asm
@@ -1,4 +1,4 @@
-Func_46981: ; 46981 (11:6981)
+IsPlayerOnDungeonWarp: ; 46981 (11:6981)
xor a
ld [wWhichDungeonWarp], a
ld a, [wd72d]
@@ -6,7 +6,7 @@ Func_46981: ; 46981 (11:6981)
ret nz
call ArePlayerCoordsInArray
ret nc
- ld a, [wWhichTrade]
+ ld a, [wCoordIndex]
ld [wWhichDungeonWarp], a
ld hl, wd72d
set 4, [hl]
@@ -58,7 +58,7 @@ CheckForHiddenObject: ; 469a0 (11:69a0)
ld [wHiddenObjectX], a
ld c, a
call CheckIfCoordsInFrontOfPlayerMatch
- ld a, [$ffea]
+ ld a, [hCoordsInFrontOfPlayerMatch]
and a
jr z, .foundMatchingObject
inc hl
@@ -85,7 +85,7 @@ CheckForHiddenObject: ; 469a0 (11:69a0)
ret
; checks if the coordinates in front of the player's sprite match Y in b and X in c
-; [$ffea] = $00 if they match, $ff if they don't match
+; [hCoordsInFrontOfPlayerMatch] = $00 if they match, $ff if they don't match
CheckIfCoordsInFrontOfPlayerMatch: ; 46a01 (11:6a01)
ld a, [wSpriteStateData1 + 9] ; player's sprite facing direction
cp SPRITE_FACING_UP
@@ -127,7 +127,7 @@ CheckIfCoordsInFrontOfPlayerMatch: ; 46a01 (11:6a01)
.didNotMatch
ld a, $ff
.done
- ld [$ffea], a
+ ld [hCoordsInFrontOfPlayerMatch], a
ret
INCLUDE "data/hidden_objects.asm"