summaryrefslogtreecommitdiff
path: root/scripts/silphco3.asm
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/silphco3.asm')
-rwxr-xr-xscripts/silphco3.asm24
1 files changed, 11 insertions, 13 deletions
diff --git a/scripts/silphco3.asm b/scripts/silphco3.asm
index 4bd1edd1..0cb54726 100755
--- a/scripts/silphco3.asm
+++ b/scripts/silphco3.asm
@@ -16,8 +16,7 @@ SilphCo3Script_59f71: ; 59f71 (16:5f71)
ld hl, DataTable_59fa8
call SilphCo2Script_59d43
call SilphCo3Script_59fad
- ld a, [wd828]
- bit 0, a
+ CheckEvent EVENT_708
jr nz, .asm_59f98
push af
ld a, $5f
@@ -37,16 +36,16 @@ DataTable_59fa8: ; 59fa8 (16:5fa8)
db $04,$04,$04,$08,$FF
SilphCo3Script_59fad: ; 59fad (16:5fad)
- ld hl, wd828
+ EventFlagAddress hl, EVENT_708
ld a, [$ffe0]
and a
ret z
cp $1
- jr nz, .asm_59fbb
- set 0, [hl]
+ jr nz, .next
+ SetEventReuseHL EVENT_708
ret
-.asm_59fbb
- set 1, [hl]
+.next
+ SetEventAfterBranchReuseHL EVENT_709, EVENT_708
ret
SilphCo3ScriptPointers: ; 59fbe (16:5fbe)
@@ -62,18 +61,18 @@ SilphCo3TextPointers: ; 59fc4 (16:5fc4)
SilphCo3TrainerHeaders: ; 59fcc (16:5fcc)
SilphCo3TrainerHeader0: ; 59fcc (16:5fcc)
- db $2 ; flag's bit
+ dbEventFlagBit EVENT_BEAT_SILPH_CO_3F_TRAINER_0
db ($2 << 4) ; trainer's view range
- dw wd827 ; flag's byte
+ dwEventFlagAddress EVENT_BEAT_SILPH_CO_3F_TRAINER_0
dw SilphCo3BattleText1 ; TextBeforeBattle
dw SilphCo3AfterBattleText1 ; TextAfterBattle
dw SilphCo3EndBattleText1 ; TextEndBattle
dw SilphCo3EndBattleText1 ; TextEndBattle
SilphCo3TrainerHeader1: ; 59fd8 (16:5fd8)
- db $3 ; flag's bit
+ dbEventFlagBit EVENT_BEAT_SILPH_CO_3F_TRAINER_1
db ($3 << 4) ; trainer's view range
- dw wd827 ; flag's byte
+ dwEventFlagAddress EVENT_BEAT_SILPH_CO_3F_TRAINER_1
dw SilphCo3BattleText2 ; TextBeforeBattle
dw SilphCo3AfterBattleText2 ; TextAfterBattle
dw SilphCo3EndBattleText2 ; TextEndBattle
@@ -83,8 +82,7 @@ SilphCo3TrainerHeader1: ; 59fd8 (16:5fd8)
SilphCo3Text1: ; 59fe5 (16:5fe5)
TX_ASM
- ld a, [wd838]
- bit 7, a
+ CheckEvent EVENT_78F
ld hl, SilphCo3Text_59ffe
jr nz, .asm_59fee
ld hl, SilphCo3Text_59ff9