mirror of
https://github.com/pret/pokered.git
synced 2026-08-24 18:34:46 -05:00
Replace magic number $7 with SLP_MASK constant (#555)
This commit is contained in:
@@ -41,7 +41,7 @@ SleepEffect:
|
||||
; including the event where the target already has another status
|
||||
ld a, [de]
|
||||
ld b, a
|
||||
and $7
|
||||
and SLP_MASK
|
||||
jr z, .notAlreadySleeping ; can't affect a mon that is already asleep
|
||||
ld hl, AlreadyAsleepText
|
||||
jp PrintText
|
||||
@@ -58,7 +58,7 @@ SleepEffect:
|
||||
.setSleepCounter
|
||||
; set target's sleep counter to a random number between 1 and 7
|
||||
call BattleRandom
|
||||
and $7
|
||||
and SLP_MASK
|
||||
jr z, .setSleepCounter
|
||||
ld [de], a
|
||||
call PlayCurrentMoveAnimation2
|
||||
|
||||
Reference in New Issue
Block a user