Merge branch 'mistress' into renewables

This commit is contained in:
Thorn Avery 2024-01-20 12:35:08 +13:00
commit 467432e564
2 changed files with 14 additions and 11 deletions

View file

@ -6981,6 +6981,9 @@ PlayMoveAnimation:
predef_jump MoveAnimation
InitBattle::
xor a
ld [wWasTrainerBattle], a ;Remember to clear wWasTrainerBattle from any previous battles,
;because this new battle could be a static wild encounter.
ld a, [wCurOpponent]
and a
jr z, DetermineWildOpponent

View file

@ -142,20 +142,20 @@ HideObject:
ld c, a
ld b, FLAG_SET
call MissableObjectFlagAction ; set "removed" flag
call VerifyObjectState
jr z, HideObject
; call VerifyObjectState
; jr z, HideObject
jp UpdateSprites
;returns z flag set if shown and z flag cleared if hidden
VerifyObjectState:
ld hl, wMissableObjectFlags
ld a, [wMissableObjectIndex]
ld c, a
ld b, FLAG_TEST
call MissableObjectFlagAction
ld a, c
and a
ret
;VerifyObjectState:
; ld hl, wMissableObjectFlags
; ld a, [wMissableObjectIndex]
; ld c, a
; ld b, FLAG_TEST
; call MissableObjectFlagAction
; ld a, c
; and a
; ret
MissableObjectFlagAction:
; identical to FlagAction