Identify some more map object labels and constants

This commit is contained in:
Rangi
2020-10-22 17:41:48 -04:00
parent 15f6a0af43
commit d8310c166d
7 changed files with 199 additions and 184 deletions

View File

@@ -1,5 +1,6 @@
ObjectActionPairPointers:
; entries correspond to OBJECT_ACTION_* constants
; normal action, frozen action
dw SetFacingStanding, SetFacingStanding
dw SetFacingStandAction, SetFacingCurrent
dw SetFacingStepAction, SetFacingCurrent
@@ -163,7 +164,7 @@ CounterclockwiseSpinAction:
swap e
ld d, 0
ld hl, .Directions
ld hl, .facings
add hl, de
ld a, [hl]
ld hl, OBJECT_FACING
@@ -171,8 +172,11 @@ CounterclockwiseSpinAction:
ld [hl], a
ret
.Directions:
db OW_DOWN, OW_RIGHT, OW_UP, OW_LEFT
.facings:
db OW_DOWN
db OW_RIGHT
db OW_UP
db OW_LEFT
SetFacingFish:
call GetSpriteDirection

File diff suppressed because it is too large Load Diff

View File

@@ -131,7 +131,7 @@ Movement_step_dig:
ld [hl], a
ld hl, OBJECT_STEP_TYPE
add hl, bc
ld [hl], STEP_TYPE_03
ld [hl], STEP_TYPE_SLEEP
ld hl, OBJECT_DIRECTION_WALKING
add hl, bc
ld [hl], STANDING
@@ -184,7 +184,7 @@ Movement_fish_cast_rod:
ld [hl], OBJECT_ACTION_FISHING
ld hl, OBJECT_STEP_TYPE
add hl, bc
ld [hl], STEP_TYPE_SLEEP
ld [hl], STEP_TYPE_FROM_MOVEMENT
ret
Movement_step_loop:
@@ -208,7 +208,7 @@ Movement_step_end:
ld hl, OBJECT_STEP_TYPE
add hl, bc
ld [hl], STEP_TYPE_SLEEP
ld [hl], STEP_TYPE_FROM_MOVEMENT
ret
Movement_48:
@@ -228,7 +228,7 @@ Movement_48:
ld hl, OBJECT_STEP_TYPE
add hl, bc
ld [hl], STEP_TYPE_03
ld [hl], STEP_TYPE_SLEEP
ld hl, wVramState
res 7, [hl]
@@ -254,7 +254,7 @@ Movement_4b:
ld hl, OBJECT_STEP_TYPE
add hl, bc
ld [hl], STEP_TYPE_04
ld [hl], STEP_TYPE_STANDING
ld hl, wVramState
res 7, [hl]
@@ -306,7 +306,7 @@ Movement_step_sleep_common:
ld hl, OBJECT_STEP_TYPE
add hl, bc
ld [hl], STEP_TYPE_03
ld [hl], STEP_TYPE_SLEEP
ld hl, OBJECT_ACTION
add hl, bc
@@ -344,7 +344,7 @@ Movement_tree_shake:
ld hl, OBJECT_STEP_TYPE
add hl, bc
ld [hl], STEP_TYPE_03
ld [hl], STEP_TYPE_SLEEP
ld hl, OBJECT_ACTION
add hl, bc
@@ -656,7 +656,7 @@ TurnStep:
ld hl, OBJECT_STEP_TYPE
add hl, bc
ld [hl], STEP_TYPE_HALF_STEP
ld [hl], STEP_TYPE_TURN
ret
NormalStep:

View File

@@ -446,7 +446,7 @@ CopyTempObjectToObjectStruct:
ld hl, OBJECT_STEP_TYPE
add hl, de
ld [hl], STEP_TYPE_00
ld [hl], STEP_TYPE_RESET
ld hl, OBJECT_FACING_STEP
add hl, de
@@ -689,7 +689,7 @@ FollowNotExact::
ld [hl], SPRITEMOVEDATA_FOLLOWNOTEXACT
ld hl, OBJECT_STEP_TYPE
add hl, de
ld [hl], STEP_TYPE_00
ld [hl], STEP_TYPE_RESET
ret
GetRelativeFacing::