summaryrefslogtreecommitdiff
path: root/data/maps/Route104/scripts.inc
diff options
context:
space:
mode:
Diffstat (limited to 'data/maps/Route104/scripts.inc')
-rw-r--r--data/maps/Route104/scripts.inc60
1 files changed, 20 insertions, 40 deletions
diff --git a/data/maps/Route104/scripts.inc b/data/maps/Route104/scripts.inc
index 4cbe5c045..68aeb0a21 100644
--- a/data/maps/Route104/scripts.inc
+++ b/data/maps/Route104/scripts.inc
@@ -33,8 +33,7 @@ Route104_EventScript_HideWhiteHerbFlorist::
return
Route104_EventScript_TrySetRivalPos::
- compare VAR_BOARD_BRINEY_BOAT_STATE, 1
- goto_if_ge Route104_EventScript_DontSetRivalPos
+ goto_if_ge VAR_BOARD_BRINEY_BOAT_STATE, 1, Route104_EventScript_DontSetRivalPos
goto_if_set FLAG_MET_RIVAL_RUSTBORO, Route104_EventScript_DontSetRivalPos
goto_if_unset FLAG_REGISTER_RIVAL_POKENAV, Route104_EventScript_DontSetRivalPos
setobjectxyperm LOCALID_RIVAL, 17, 52
@@ -77,10 +76,8 @@ Route104_EventScript_RivalTrigger::
@ Unused, shares script with Rustboro encounter instead
Route104_EventScript_PlayRivalMusic::
checkplayergender
- compare VAR_RESULT, MALE
- goto_if_eq Route104_EventScript_PlayMayMusic
- compare VAR_RESULT, FEMALE
- goto_if_eq Route104_EventScript_PlayBrendanMusic
+ goto_if_eq VAR_RESULT, MALE, Route104_EventScript_PlayMayMusic
+ goto_if_eq VAR_RESULT, FEMALE, Route104_EventScript_PlayBrendanMusic
return
Route104_EventScript_PlayMayMusic::
@@ -93,10 +90,8 @@ Route104_EventScript_PlayBrendanMusic::
Route104_EventScript_RivalEncounter::
checkplayergender
- compare VAR_RESULT, MALE
- goto_if_eq Route104_EventScript_MayEncounter
- compare VAR_RESULT, FEMALE
- goto_if_eq Route104_EventScript_BrendanEncounter
+ goto_if_eq VAR_RESULT, MALE, Route104_EventScript_MayEncounter
+ goto_if_eq VAR_RESULT, FEMALE, Route104_EventScript_BrendanEncounter
end
Route104_EventScript_MayEncounter::
@@ -121,8 +116,7 @@ Route104_EventScript_MayEncounter::
waitmovement 0
copyobjectxytoperm LOCALID_RIVAL
msgbox Route104_Text_MayMinesDecentLetsBattle, MSGBOX_YESNO
- compare VAR_RESULT, YES
- goto_if_eq Route104_EventScript_BattleMay
+ goto_if_eq VAR_RESULT, YES, Route104_EventScript_BattleMay
msgbox Route104_Text_MayHaventRaisedPokemon, MSGBOX_DEFAULT
call Route104_EventScript_RestoreMusic
releaseall
@@ -144,8 +138,7 @@ Route104_Movement_PlayerFaceRival:
Route104_EventScript_MayAskToBattle::
msgbox Route104_Text_MayLetsBattle, MSGBOX_YESNO
- compare VAR_RESULT, YES
- goto_if_eq Route104_EventScript_BattleMay
+ goto_if_eq VAR_RESULT, YES, Route104_EventScript_BattleMay
msgbox Route104_Text_MayHaventRaisedPokemon, MSGBOX_DEFAULT
releaseall
end
@@ -160,8 +153,7 @@ Route104_EventScript_BattleMay::
Route104_EventScript_MayDefeated::
msgbox Route104_Text_MayPostBattle, MSGBOX_DEFAULT
- compare VAR_0x8008, 0
- call_if_eq Route104_EventScript_RestoreMusic
+ call_if_eq VAR_0x8008, 0, Route104_EventScript_RestoreMusic
releaseall
end
@@ -210,8 +202,7 @@ Route104_EventScript_BrendanEncounter::
waitmovement 0
copyobjectxytoperm LOCALID_RIVAL
msgbox Route104_Text_BrendanDoingGreatLetsBattle, MSGBOX_YESNO
- compare VAR_RESULT, YES
- goto_if_eq Route104_EventScript_BattleBrendan
+ goto_if_eq VAR_RESULT, YES, Route104_EventScript_BattleBrendan
msgbox Route104_Text_BrendanNoConfidence, MSGBOX_DEFAULT
call Route104_EventScript_RestoreMusic
releaseall
@@ -219,8 +210,7 @@ Route104_EventScript_BrendanEncounter::
Route104_EventScript_BrendanAskToBattle::
msgbox Route104_Text_BrendanLetsBattle, MSGBOX_YESNO
- compare VAR_RESULT, YES
- goto_if_eq Route104_EventScript_BattleBrendan
+ goto_if_eq VAR_RESULT, YES, Route104_EventScript_BattleBrendan
msgbox Route104_Text_BrendanNoConfidence, MSGBOX_DEFAULT
releaseall
end
@@ -235,8 +225,7 @@ Route104_EventScript_BattleBrendan::
Route104_EventScript_BrendanDefeated::
msgbox Route104_Text_BrendanPostBattle, MSGBOX_DEFAULT
- compare VAR_0x8008, 0
- call_if_eq Route104_EventScript_RestoreMusic
+ call_if_eq VAR_0x8008, 0, Route104_EventScript_RestoreMusic
releaseall
end
@@ -274,8 +263,7 @@ Route104_EventScript_ExpertF::
goto_if_set FLAG_RECEIVED_CHESTO_BERRY_ROUTE_104, Route104_EventScript_ReceivedBerry
msgbox Route104_Text_PlantBerriesInSoilTakeThis, MSGBOX_DEFAULT
giveitem ITEM_CHESTO_BERRY
- compare VAR_RESULT, FALSE
- goto_if_eq Common_EventScript_ShowBagIsFull
+ goto_if_eq VAR_RESULT, FALSE, Common_EventScript_ShowBagIsFull
setflag FLAG_RECEIVED_CHESTO_BERRY_ROUTE_104
msgbox Route104_Text_TrainersOftenMakeMonHoldBerries, MSGBOX_DEFAULT
release
@@ -292,8 +280,7 @@ Route104_EventScript_WhiteHerbFlorist::
goto_if_set FLAG_RECEIVED_WHITE_HERB, Route104_EventScript_ReceivedWhiteHerb
msgbox Route104_Text_DontNeedThisTakeIt, MSGBOX_DEFAULT
giveitem ITEM_WHITE_HERB
- compare VAR_RESULT, FALSE
- goto_if_eq Common_EventScript_ShowBagIsFull
+ goto_if_eq VAR_RESULT, FALSE, Common_EventScript_ShowBagIsFull
setflag FLAG_RECEIVED_WHITE_HERB
release
end
@@ -345,8 +332,7 @@ Route104_EventScript_Boy2::
goto_if_set FLAG_RECEIVED_TM09, Route104_EventScript_ReceivedBulletSeed
msgbox Route104_Text_LikeFillingMouthWithSeedsTakeThis, MSGBOX_DEFAULT
giveitem ITEM_TM09
- compare VAR_RESULT, FALSE
- goto_if_eq Common_EventScript_ShowBagIsFull
+ goto_if_eq VAR_RESULT, FALSE, Common_EventScript_ShowBagIsFull
setflag FLAG_RECEIVED_TM09
release
end
@@ -873,12 +859,10 @@ Route104_EventScript_Billy::
Route104_EventScript_Haley::
trainerbattle_single TRAINER_HALEY_1, Route104_Text_HaleyIntro, Route104_Text_HaleyDefeat, Route104_EventScript_TryRegisterHaleyAfterBattle
specialvar VAR_RESULT, ShouldTryRematchBattle
- compare VAR_RESULT, TRUE
- goto_if_eq Route104_EventScript_RematchHaley
+ goto_if_eq VAR_RESULT, TRUE, Route104_EventScript_RematchHaley
setvar VAR_0x8004, TRAINER_HALEY_1
specialvar VAR_RESULT, IsTrainerRegistered
- compare VAR_RESULT, FALSE
- goto_if_eq Route104_EventScript_TryRegisterHaley
+ goto_if_eq VAR_RESULT, FALSE, Route104_EventScript_TryRegisterHaley
msgbox Route104_Text_HaleyPostBattle, MSGBOX_DEFAULT
release
end
@@ -916,12 +900,10 @@ Route104_EventScript_RematchHaley::
Route104_EventScript_Winston::
trainerbattle_single TRAINER_WINSTON_1, Route104_Text_WinstonIntro, Route104_Text_WinstonDefeat, Route104_EventScript_TryRegisterWinstonAfterBattle
specialvar VAR_RESULT, ShouldTryRematchBattle
- compare VAR_RESULT, TRUE
- goto_if_eq Route104_EventScript_RematchWinston
+ goto_if_eq VAR_RESULT, TRUE, Route104_EventScript_RematchWinston
setvar VAR_0x8004, TRAINER_WINSTON_1
specialvar VAR_RESULT, IsTrainerRegistered
- compare VAR_RESULT, FALSE
- goto_if_eq Route104_EventScript_TryRegisterWinston
+ goto_if_eq VAR_RESULT, FALSE, Route104_EventScript_TryRegisterWinston
msgbox Route104_Text_WinstonPostBattle, MSGBOX_DEFAULT
release
end
@@ -959,12 +941,10 @@ Route104_EventScript_RematchWinston::
Route104_EventScript_Cindy::
trainerbattle_single TRAINER_CINDY_1, Route104_Text_CindyIntro, Route104_Text_CindyDefeat, Route104_EventScript_TryRegisterCindyAfterBattle
specialvar VAR_RESULT, ShouldTryRematchBattle
- compare VAR_RESULT, TRUE
- goto_if_eq Route104_EventScript_RematchCindy
+ goto_if_eq VAR_RESULT, TRUE, Route104_EventScript_RematchCindy
setvar VAR_0x8004, TRAINER_CINDY_1
specialvar VAR_RESULT, IsTrainerRegistered
- compare VAR_RESULT, FALSE
- goto_if_eq Route104_EventScript_TryRegisterCindy
+ goto_if_eq VAR_RESULT, FALSE, Route104_EventScript_TryRegisterCindy
msgbox Route104_Text_CindyPostBattle, MSGBOX_DEFAULT
release
end