summaryrefslogtreecommitdiff
path: root/data/maps/BattleFrontier_BattleTowerLobby
diff options
context:
space:
mode:
authorGriffinR <griffin.g.richards@gmail.com>2021-11-18 23:06:30 -0500
committerGriffinR <griffin.g.richards@gmail.com>2021-11-18 23:06:51 -0500
commite66ea0cb996c70093fe3f250cafb7f1f87e84d4d (patch)
tree162e07afa059e7683e4aa991a1a82205c16b3025 /data/maps/BattleFrontier_BattleTowerLobby
parentc57efdba5d3cc475f75c5909c31f96bbce6190b8 (diff)
Reformat compare + goto_if/call_if to single statements
Diffstat (limited to 'data/maps/BattleFrontier_BattleTowerLobby')
-rw-r--r--data/maps/BattleFrontier_BattleTowerLobby/scripts.inc183
1 files changed, 61 insertions, 122 deletions
diff --git a/data/maps/BattleFrontier_BattleTowerLobby/scripts.inc b/data/maps/BattleFrontier_BattleTowerLobby/scripts.inc
index 3d10a08a0..40936936a 100644
--- a/data/maps/BattleFrontier_BattleTowerLobby/scripts.inc
+++ b/data/maps/BattleFrontier_BattleTowerLobby/scripts.inc
@@ -19,8 +19,7 @@ BattleFrontier_BattleTowerLobby_OnResume:
BattleFrontier_BattleTowerLobby_OnTransition:
call BattleFrontier_BattleTowerLobby_EventScript_ShowOrHideReporter
apprentice_shouldcheckgone
- compare VAR_0x8004, FALSE @ Always TRUE here
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_ShowApprentice
+ goto_if_eq VAR_0x8004, FALSE, BattleFrontier_BattleTowerLobby_EventScript_ShowApprentice @ VAR_0x8004 always TRUE here
goto_if_set FLAG_DAILY_APPRENTICE_LEAVES, BattleFrontier_BattleTowerLobby_EventScript_HideApprentice
BattleFrontier_BattleTowerLobby_EventScript_ShowApprentice::
clearflag FLAG_HIDE_APPRENTICE
@@ -69,8 +68,7 @@ BattleFrontier_BattleTowerLobby_EventScript_WonChallenge::
lock
faceplayer
frontier_isbrain
- compare VAR_RESULT, TRUE
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_DefeatedMaiden
+ goto_if_eq VAR_RESULT, TRUE, BattleFrontier_BattleTowerLobby_EventScript_DefeatedMaiden
message BattleFrontier_BattleTowerLobby_Text_CongratsBeatenSeven
waitmessage
goto BattleFrontier_BattleTowerLobby_EventScript_GiveRibbons
@@ -79,8 +77,7 @@ BattleFrontier_BattleTowerLobby_EventScript_DefeatedMaiden::
msgbox BattleFrontier_BattleTowerLobby_Text_CongratsDefeatedMaiden, MSGBOX_DEFAULT
BattleFrontier_BattleTowerLobby_EventScript_GiveRibbons::
tower_giveribbons
- compare VAR_RESULT, FALSE
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_GiveBattlePoints
+ goto_if_eq VAR_RESULT, FALSE, BattleFrontier_BattleTowerLobby_EventScript_GiveBattlePoints
message BattleFrontier_BattleTowerLobby_Text_HereAreSomeRibbons
waitmessage
playfanfare MUS_OBTAIN_ITEM
@@ -92,8 +89,7 @@ BattleFrontier_BattleTowerLobby_EventScript_GiveBattlePoints::
msgbox BattleFrontier_Text_ObtainedXBattlePoints, MSGBOX_GETPOINTS
call BattleFrontier_BattleTowerLobby_EventScript_AskSaveBattle
tower_get TOWER_DATA_WIN_STREAK
- compare VAR_RESULT, 49
- goto_if_ne BattleFrontier_BattleTowerLobby_EventScript_LookForwardToChallenge
+ goto_if_ne VAR_RESULT, 49, BattleFrontier_BattleTowerLobby_EventScript_LookForwardToChallenge
msgbox BattleFrontier_BattleTowerLobby_Text_AboutToFace50thTrainer, MSGBOX_DEFAULT
BattleFrontier_BattleTowerLobby_EventScript_LookForwardToChallenge::
msgbox BattleFrontier_BattleTowerLobby_Text_LookForwardToAnotherChallenge, MSGBOX_DEFAULT
@@ -103,12 +99,10 @@ BattleFrontier_BattleTowerLobby_EventScript_LookForwardToChallenge::
end
BattleFrontier_BattleTowerLobby_EventScript_LostChallenge::
- compare VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_MULTIS
- goto_if_ne BattleFrontier_BattleTowerLobby_EventScript_CancelWinStreak
+ goto_if_ne VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_MULTIS, BattleFrontier_BattleTowerLobby_EventScript_CancelWinStreak
goto_if_set FLAG_CHOSEN_MULTI_BATTLE_NPC_PARTNER, BattleFrontier_BattleTowerLobby_EventScript_CancelWinStreak
tower_get TOWER_DATA_WIN_STREAK
- compare VAR_RESULT, 0
- goto_if_ne BattleFrontier_BattleTowerLobby_EventScript_LostThanksForPlaying
+ goto_if_ne VAR_RESULT, 0, BattleFrontier_BattleTowerLobby_EventScript_LostThanksForPlaying
BattleFrontier_BattleTowerLobby_EventScript_CancelWinStreak::
tower_set TOWER_DATA_WIN_STREAK_ACTIVE, FALSE
BattleFrontier_BattleTowerLobby_EventScript_LostThanksForPlaying::
@@ -133,8 +127,7 @@ BattleFrontier_BattleTowerLobby_EventScript_AskSaveBattle::
playse SE_SAVE
waitse
call BattleFrontier_EventScript_GetCantRecordBattle
- compare VAR_RESULT, TRUE
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_EndSaveBattle
+ goto_if_eq VAR_RESULT, TRUE, BattleFrontier_BattleTowerLobby_EventScript_EndSaveBattle
message BattleFrontier_BattleTowerLobby_Text_RecordLastMatch
waitmessage
multichoicedefault 20, 8, MULTI_YESNO, 1, FALSE
@@ -145,8 +138,7 @@ BattleFrontier_BattleTowerLobby_EventScript_AskSaveBattle::
BattleFrontier_EventScript_SaveBattle::
frontier_savebattle
- compare VAR_RESULT, FALSE
- goto_if_eq BattleFrontier_EventScript_BattleSaveFailed
+ goto_if_eq VAR_RESULT, FALSE, BattleFrontier_EventScript_BattleSaveFailed
playse SE_SAVE
msgbox BattleFrontier_BattleTowerLobby_Text_BattleRecordedOnPass, MSGBOX_DEFAULT
goto BattleFrontier_BattleTowerLobby_EventScript_EndSaveBattle
@@ -163,8 +155,7 @@ BattleFrontier_EventScript_GetCantRecordBattle::
BattleFrontier_BattleTowerLobby_EventScript_ResumeChallenge::
lock
faceplayer
- compare VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_SINGLES
- call_if_eq BattleFrontier_BattleTowerLobby_EventScript_SetBravoTrainerOn
+ call_if_eq VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_SINGLES, BattleFrontier_BattleTowerLobby_EventScript_SetBravoTrainerOn
message BattleFrontier_BattleTowerLobby_Text_WeveBeenWaitingForYou
waitmessage
message BattleFrontier_BattleTowerLobby_Text_ProgressWillBeSaved
@@ -205,8 +196,7 @@ BattleFrontier_BattleTowerLobby_EventScript_TryEnterSinglesChallenge::
case FRONTIER_LVL_TENT, BattleFrontier_BattleTowerLobby_EventScript_CancelChallenge
case MULTI_B_PRESSED, BattleFrontier_BattleTowerLobby_EventScript_CancelChallenge
frontier_checkineligible
- compare VAR_0x8004, TRUE
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_NotEnoughValidMons
+ goto_if_eq VAR_0x8004, TRUE, BattleFrontier_BattleTowerLobby_EventScript_NotEnoughValidMons
frontier_set FRONTIER_DATA_LVL_MODE, VAR_RESULT
msgbox BattleFrontier_BattleTowerLobby_Text_SelectThreeMons, MSGBOX_DEFAULT
fadescreen FADE_TO_BLACK
@@ -215,8 +205,7 @@ BattleFrontier_BattleTowerLobby_EventScript_TryEnterSinglesChallenge::
setvar VAR_0x8005, FRONTIER_PARTY_SIZE
special ChoosePartyForBattleFrontier
waitstate
- compare VAR_RESULT, 0
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_LoadPartyCancelChallenge
+ goto_if_eq VAR_RESULT, 0, BattleFrontier_BattleTowerLobby_EventScript_LoadPartyCancelChallenge
msgbox BattleFrontier_BattleTowerLobby_Text_OkayToSaveBeforeEntering, MSGBOX_YESNO
switch VAR_RESULT
case NO, BattleFrontier_BattleTowerLobby_EventScript_LoadPartyCancelChallenge
@@ -234,8 +223,7 @@ BattleFrontier_BattleTowerLobby_EventScript_SaveBeforeSinglesChallenge::
delay 2
call Common_EventScript_SaveGame
setvar VAR_TEMP_0, 255
- compare VAR_RESULT, 0
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_CancelChallengeSaveFailed
+ goto_if_eq VAR_RESULT, 0, BattleFrontier_BattleTowerLobby_EventScript_CancelChallengeSaveFailed
incrementgamestat GAME_STAT_ENTERED_BATTLE_TOWER
setvar VAR_BRAVO_TRAINER_BATTLE_TOWER_ON, TRUE
goto BattleFrontier_BattleTowerLobby_EventScript_EnterElevator
@@ -271,8 +259,7 @@ BattleFrontier_BattleTowerLobby_EventScript_TryEnterDoublesChallenge::
case FRONTIER_LVL_TENT, BattleFrontier_BattleTowerLobby_EventScript_CancelChallenge
case MULTI_B_PRESSED, BattleFrontier_BattleTowerLobby_EventScript_CancelChallenge
frontier_checkineligible
- compare VAR_0x8004, TRUE
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_NotEnoughValidMons
+ goto_if_eq VAR_0x8004, TRUE, BattleFrontier_BattleTowerLobby_EventScript_NotEnoughValidMons
frontier_set FRONTIER_DATA_LVL_MODE, VAR_RESULT
msgbox BattleFrontier_BattleTowerLobby_Text_PleaseSelectFourMons, MSGBOX_DEFAULT
fadescreen FADE_TO_BLACK
@@ -281,8 +268,7 @@ BattleFrontier_BattleTowerLobby_EventScript_TryEnterDoublesChallenge::
setvar VAR_0x8005, FRONTIER_DOUBLES_PARTY_SIZE
special ChoosePartyForBattleFrontier
waitstate
- compare VAR_RESULT, 0
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_LoadPartyCancelChallenge
+ goto_if_eq VAR_RESULT, 0, BattleFrontier_BattleTowerLobby_EventScript_LoadPartyCancelChallenge
msgbox BattleFrontier_BattleTowerLobby_Text_OkayToSaveBeforeEntering, MSGBOX_YESNO
switch VAR_RESULT
case NO, BattleFrontier_BattleTowerLobby_EventScript_LoadPartyCancelChallenge
@@ -300,8 +286,7 @@ BattleFrontier_BattleTowerLobby_EventScript_SaveBeforeDoublesChallenge::
delay 2
call Common_EventScript_SaveGame
setvar VAR_TEMP_0, 255
- compare VAR_RESULT, 0
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_CancelChallengeSaveFailed
+ goto_if_eq VAR_RESULT, 0, BattleFrontier_BattleTowerLobby_EventScript_CancelChallengeSaveFailed
incrementgamestat GAME_STAT_ENTERED_BATTLE_TOWER
setvar VAR_BRAVO_TRAINER_BATTLE_TOWER_ON, FALSE
goto BattleFrontier_BattleTowerLobby_EventScript_EnterElevator
@@ -338,8 +323,7 @@ BattleFrontier_BattleTowerLobby_EventScript_TryEnterMultisChallenge::
case FRONTIER_LVL_TENT, BattleFrontier_BattleTowerLobby_EventScript_CancelChallenge
case MULTI_B_PRESSED, BattleFrontier_BattleTowerLobby_EventScript_CancelChallenge
frontier_checkineligible
- compare VAR_0x8004, TRUE
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_NotEnoughValidMons
+ goto_if_eq VAR_0x8004, TRUE, BattleFrontier_BattleTowerLobby_EventScript_NotEnoughValidMons
frontier_set FRONTIER_DATA_LVL_MODE, VAR_RESULT
msgbox BattleFrontier_BattleTowerLobby_Text_PleaseSelectTwoMons, MSGBOX_DEFAULT
fadescreen FADE_TO_BLACK
@@ -348,8 +332,7 @@ BattleFrontier_BattleTowerLobby_EventScript_TryEnterMultisChallenge::
setvar VAR_0x8005, FRONTIER_MULTI_PARTY_SIZE
special ChoosePartyForBattleFrontier
waitstate
- compare VAR_RESULT, 0
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_LoadPartyCancelChallenge
+ goto_if_eq VAR_RESULT, 0, BattleFrontier_BattleTowerLobby_EventScript_LoadPartyCancelChallenge
msgbox BattleFrontier_BattleTowerLobby_Text_OkayToSaveBeforeEntering, MSGBOX_YESNO
switch VAR_RESULT
case NO, BattleFrontier_BattleTowerLobby_EventScript_LoadPartyCancelChallenge
@@ -367,8 +350,7 @@ BattleFrontier_BattleTowerLobby_EventScript_SaveBeforeMultisChallenge::
delay 2
call Common_EventScript_SaveGame
setvar VAR_TEMP_0, 255
- compare VAR_RESULT, 0
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_CancelChallengeSaveFailed
+ goto_if_eq VAR_RESULT, 0, BattleFrontier_BattleTowerLobby_EventScript_CancelChallengeSaveFailed
incrementgamestat GAME_STAT_ENTERED_BATTLE_TOWER
setvar VAR_BRAVO_TRAINER_BATTLE_TOWER_ON, FALSE
goto BattleFrontier_BattleTowerLobby_EventScript_EnterElevator
@@ -404,8 +386,7 @@ BattleFrontier_BattleTowerLobby_EventScript_TryEnterLinkMultisChallenge::
case FRONTIER_LVL_TENT, BattleFrontier_BattleTowerLobby_EventScript_CancelChallenge
case MULTI_B_PRESSED, BattleFrontier_BattleTowerLobby_EventScript_CancelChallenge
frontier_checkineligible
- compare VAR_0x8004, TRUE
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_NotEnoughValidMons
+ goto_if_eq VAR_0x8004, TRUE, BattleFrontier_BattleTowerLobby_EventScript_NotEnoughValidMons
frontier_set FRONTIER_DATA_LVL_MODE, VAR_RESULT
msgbox BattleFrontier_BattleTowerLobby_Text_PleaseSelectTwoMons2, MSGBOX_DEFAULT
fadescreen FADE_TO_BLACK
@@ -414,8 +395,7 @@ BattleFrontier_BattleTowerLobby_EventScript_TryEnterLinkMultisChallenge::
setvar VAR_0x8005, FRONTIER_MULTI_PARTY_SIZE
special ChoosePartyForBattleFrontier
waitstate
- compare VAR_RESULT, 0
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_LoadPartyCancelChallenge
+ goto_if_eq VAR_RESULT, 0, BattleFrontier_BattleTowerLobby_EventScript_LoadPartyCancelChallenge
msgbox BattleFrontier_BattleTowerLobby_Text_OkayToSaveBeforeEntering, MSGBOX_YESNO
switch VAR_RESULT
case NO, BattleFrontier_BattleTowerLobby_EventScript_LoadPartyCancelChallenge
@@ -434,12 +414,10 @@ BattleFrontier_BattleTowerLobby_EventScript_SaveBeforeLinkMultisChallenge::
tower_save 0
call Common_EventScript_SaveGame
setvar VAR_TEMP_0, 255
- compare VAR_RESULT, 0
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_CancelChallengeSaveFailed
+ goto_if_eq VAR_RESULT, 0, BattleFrontier_BattleTowerLobby_EventScript_CancelChallengeSaveFailed
incrementgamestat GAME_STAT_ENTERED_BATTLE_TOWER
specialvar VAR_RESULT, IsWirelessAdapterConnected
- compare VAR_RESULT, TRUE
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_TryWirelessLink
+ goto_if_eq VAR_RESULT, TRUE, BattleFrontier_BattleTowerLobby_EventScript_TryWirelessLink
goto BattleFrontier_BattleTowerLobby_EventScript_TryCableLink
end
@@ -491,10 +469,8 @@ BattleFrontier_BattleTowerLobby_EventScript_FeelingsWontTell::
end
BattleFrontier_BattleTowerLobby_EventScript_CheckFeelings::
- compare VAR_RESULT, 0
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_CanceledEasyChat
- compare VAR_RESULT, 1
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_SubmittedFeelings
+ goto_if_eq VAR_RESULT, 0, BattleFrontier_BattleTowerLobby_EventScript_CanceledEasyChat
+ goto_if_eq VAR_RESULT, 1, BattleFrontier_BattleTowerLobby_EventScript_SubmittedFeelings
end
BattleFrontier_BattleTowerLobby_EventScript_CanceledEasyChat::
@@ -611,8 +587,7 @@ BattleFrontier_BattleTowerLobby_EventScript_EnterElevator::
BattleFrontier_BattleTowerLobby_EventScript_WaitForLinkOpponentLoad::
tower_loadlinkopponents
delay 1
- compare VAR_RESULT, 6
- goto_if_ne BattleFrontier_BattleTowerLobby_EventScript_WaitForLinkOpponentLoad
+ goto_if_ne VAR_RESULT, 6, BattleFrontier_BattleTowerLobby_EventScript_WaitForLinkOpponentLoad
call BattleFrontier_BattleTowerLobby_EventScript_ShowYouToBattleRoom
clearflag FLAG_CANCEL_BATTLE_ROOM_CHALLENGE
warp MAP_BATTLE_FRONTIER_BATTLE_TOWER_ELEVATOR, 1, 6
@@ -622,8 +597,7 @@ BattleFrontier_BattleTowerLobby_EventScript_WaitForLinkOpponentLoad::
BattleFrontier_BattleTowerLobby_EventScript_ShowYouToBattleRoom::
call BattleFrontier_BattleTowerLobby_EventScript_BufferModeText
- compare VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_LINK_MULTIS
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_ShowYouToLinkMultiBattleRoom
+ goto_if_eq VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_LINK_MULTIS, BattleFrontier_BattleTowerLobby_EventScript_ShowYouToLinkMultiBattleRoom
msgbox BattleFrontier_BattleTowerLobby_Text_ShowYouToBattleRoom, MSGBOX_DEFAULT
goto BattleFrontier_BattleTowerLobby_EventScript_WalkToElevator
@@ -675,14 +649,10 @@ BattleFrontier_BattleTowerLobby_Movement_UnusedEnterElevator:
step_end
BattleFrontier_BattleTowerLobby_EventScript_BufferModeText::
- compare VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_SINGLES
- call_if_eq BattleFrontier_BattleTowerLobby_EventScript_BufferTextSingle
- compare VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_DOUBLES
- call_if_eq BattleFrontier_BattleTowerLobby_EventScript_BufferTextDouble
- compare VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_MULTIS
- call_if_eq BattleFrontier_BattleTowerLobby_EventScript_BufferTextMulti
- compare VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_LINK_MULTIS
- call_if_eq BattleFrontier_BattleTowerLobby_EventScript_BufferTextLinkMulti
+ call_if_eq VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_SINGLES, BattleFrontier_BattleTowerLobby_EventScript_BufferTextSingle
+ call_if_eq VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_DOUBLES, BattleFrontier_BattleTowerLobby_EventScript_BufferTextDouble
+ call_if_eq VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_MULTIS, BattleFrontier_BattleTowerLobby_EventScript_BufferTextMulti
+ call_if_eq VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_LINK_MULTIS, BattleFrontier_BattleTowerLobby_EventScript_BufferTextLinkMulti
return
BattleFrontier_BattleTowerLobby_EventScript_BufferTextSingle::
@@ -702,14 +672,10 @@ BattleFrontier_BattleTowerLobby_EventScript_BufferTextLinkMulti::
return
BattleFrontier_BattleTowerLobby_EventScript_SetAttendantTalkedTo::
- compare VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_SINGLES
- call_if_eq BattleFrontier_BattleTowerLobby_EventScript_TalkedToSinglesAttendant
- compare VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_DOUBLES
- call_if_eq BattleFrontier_BattleTowerLobby_EventScript_TalkedToDoublesAttendant
- compare VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_MULTIS
- call_if_eq BattleFrontier_BattleTowerLobby_EventScript_TalkedToMultisAttendant
- compare VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_LINK_MULTIS
- call_if_eq BattleFrontier_BattleTowerLobby_EventScript_TalkedToLinkMultisAttendant
+ call_if_eq VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_SINGLES, BattleFrontier_BattleTowerLobby_EventScript_TalkedToSinglesAttendant
+ call_if_eq VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_DOUBLES, BattleFrontier_BattleTowerLobby_EventScript_TalkedToDoublesAttendant
+ call_if_eq VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_MULTIS, BattleFrontier_BattleTowerLobby_EventScript_TalkedToMultisAttendant
+ call_if_eq VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_LINK_MULTIS, BattleFrontier_BattleTowerLobby_EventScript_TalkedToLinkMultisAttendant
return
BattleFrontier_BattleTowerLobby_EventScript_TalkedToSinglesAttendant::
@@ -729,14 +695,10 @@ BattleFrontier_BattleTowerLobby_EventScript_TalkedToLinkMultisAttendant::
return
BattleFrontier_BattleTowerLobby_EventScript_GetDoorXCoord::
- compare VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_SINGLES
- call_if_eq BattleFrontier_BattleTowerLobby_EventScript_GetDoorXCoordSingles
- compare VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_DOUBLES
- call_if_eq BattleFrontier_BattleTowerLobby_EventScript_GetDoorXCoordDoubles
- compare VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_MULTIS
- call_if_eq BattleFrontier_BattleTowerLobby_EventScript_GetDoorXCoordMultis
- compare VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_LINK_MULTIS
- call_if_eq BattleFrontier_BattleTowerLobby_EventScript_GetDoorXCoordLinkMultis
+ call_if_eq VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_SINGLES, BattleFrontier_BattleTowerLobby_EventScript_GetDoorXCoordSingles
+ call_if_eq VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_DOUBLES, BattleFrontier_BattleTowerLobby_EventScript_GetDoorXCoordDoubles
+ call_if_eq VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_MULTIS, BattleFrontier_BattleTowerLobby_EventScript_GetDoorXCoordMultis
+ call_if_eq VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_LINK_MULTIS, BattleFrontier_BattleTowerLobby_EventScript_GetDoorXCoordLinkMultis
return
BattleFrontier_BattleTowerLobby_EventScript_GetDoorXCoordSingles::
@@ -756,14 +718,10 @@ BattleFrontier_BattleTowerLobby_EventScript_GetDoorXCoordLinkMultis::
return
BattleFrontier_BattleTowerLobby_EventScript_GetPartySize::
- compare VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_SINGLES
- call_if_eq BattleFrontier_BattleTowerLobby_EventScript_GetSinglesPartySize
- compare VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_DOUBLES
- call_if_eq BattleFrontier_BattleTowerLobby_EventScript_GetDoublesPartySize
- compare VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_MULTIS
- call_if_eq BattleFrontier_BattleTowerLobby_EventScript_GetMultisPartySize
- compare VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_LINK_MULTIS
- call_if_eq BattleFrontier_BattleTowerLobby_EventScript_GetLinkMultisPartySize
+ call_if_eq VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_SINGLES, BattleFrontier_BattleTowerLobby_EventScript_GetSinglesPartySize
+ call_if_eq VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_DOUBLES, BattleFrontier_BattleTowerLobby_EventScript_GetDoublesPartySize
+ call_if_eq VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_MULTIS, BattleFrontier_BattleTowerLobby_EventScript_GetMultisPartySize
+ call_if_eq VAR_FRONTIER_BATTLE_MODE, FRONTIER_MODE_LINK_MULTIS, BattleFrontier_BattleTowerLobby_EventScript_GetLinkMultisPartySize
return
BattleFrontier_BattleTowerLobby_EventScript_GetSinglesPartySize::
@@ -793,26 +751,18 @@ BattleFrontier_BattleTowerLobby_EventScript_TryCableLink::
setvar VAR_0x8005, 0
special TryBattleLinkup
waitstate
- compare VAR_RESULT, LINKUP_SUCCESS
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_CableLinkSuccessful
- compare VAR_RESULT, LINKUP_SOMEONE_NOT_READY
- goto_if_eq CableClub_EventScript_AbortLinkSomeoneNotReady
- compare VAR_RESULT, LINKUP_DIFF_SELECTIONS
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_AbortLinkDifferentSelections
- compare VAR_RESULT, LINKUP_WRONG_NUM_PLAYERS
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_AbortLinkIncorrectNumberOfPlayers
- compare VAR_RESULT, LINKUP_FAILED
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_CancelChallenge
- compare VAR_RESULT, LINKUP_CONNECTION_ERROR
- goto_if_eq CableClub_EventScript_AbortLinkConnectionError
- compare VAR_RESULT, LINKUP_FAILED_BATTLE_TOWER
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_AbortLink
+ goto_if_eq VAR_RESULT, LINKUP_SUCCESS, BattleFrontier_BattleTowerLobby_EventScript_CableLinkSuccessful
+ goto_if_eq VAR_RESULT, LINKUP_SOMEONE_NOT_READY, CableClub_EventScript_AbortLinkSomeoneNotReady
+ goto_if_eq VAR_RESULT, LINKUP_DIFF_SELECTIONS, BattleFrontier_BattleTowerLobby_EventScript_AbortLinkDifferentSelections
+ goto_if_eq VAR_RESULT, LINKUP_WRONG_NUM_PLAYERS, BattleFrontier_BattleTowerLobby_EventScript_AbortLinkIncorrectNumberOfPlayers
+ goto_if_eq VAR_RESULT, LINKUP_FAILED, BattleFrontier_BattleTowerLobby_EventScript_CancelChallenge
+ goto_if_eq VAR_RESULT, LINKUP_CONNECTION_ERROR, CableClub_EventScript_AbortLinkConnectionError
+ goto_if_eq VAR_RESULT, LINKUP_FAILED_BATTLE_TOWER, BattleFrontier_BattleTowerLobby_EventScript_AbortLink
end
BattleFrontier_BattleTowerLobby_EventScript_AbortLinkDifferentSelections::
special CloseLink
- compare VAR_0x8005, 3
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_FriendDifferentSelection
+ goto_if_eq VAR_0x8005, 3, BattleFrontier_BattleTowerLobby_EventScript_FriendDifferentSelection
msgbox Text_PlayersMadeDifferentSelections, MSGBOX_DEFAULT
release
end
@@ -832,12 +782,9 @@ BattleFrontier_BattleTowerLobby_EventScript_AbortLinkIncorrectNumberOfPlayers::
BattleFrontier_BattleTowerLobby_EventScript_AbortLink::
special CloseLink
- compare VAR_0x8005, 0
- call_if_eq BattleFrontier_BattleTowerLobby_EventScript_FriendChoseDifferentLvlMode
- compare VAR_0x8005, 1
- call_if_eq BattleFrontier_BattleTowerLobby_EventScript_FriendAlsoSelectedMon
- compare VAR_0x8005, 2
- call_if_eq BattleFrontier_BattleTowerLobby_EventScript_FriendAlsoSelectedMons
+ call_if_eq VAR_0x8005, 0, BattleFrontier_BattleTowerLobby_EventScript_FriendChoseDifferentLvlMode
+ call_if_eq VAR_0x8005, 1, BattleFrontier_BattleTowerLobby_EventScript_FriendAlsoSelectedMon
+ call_if_eq VAR_0x8005, 2, BattleFrontier_BattleTowerLobby_EventScript_FriendAlsoSelectedMons
msgbox BattleFrontier_BattleTowerLobby_Text_ChooseDifferentMonsMatchLvlMode, MSGBOX_DEFAULT
release
end
@@ -891,27 +838,19 @@ BattleFrontier_BattleTowerLobby_EventScript_ChooseLeader::
BattleFrontier_BattleTowerLobby_EventScript_TryBecomeLeader::
call CableClub_EventScript_TryBecomeLinkLeader
- compare VAR_RESULT, LINKUP_SUCCESS
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_WirelessLinkSuccessful
- compare VAR_RESULT, LINKUP_FAILED
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_ChooseLeader
- compare VAR_RESULT, LINKUP_RETRY_ROLE_ASSIGN
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_TryBecomeLeader
- compare VAR_RESULT, LINKUP_FAILED_BATTLE_TOWER
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_AbortLink
+ goto_if_eq VAR_RESULT, LINKUP_SUCCESS, BattleFrontier_BattleTowerLobby_EventScript_WirelessLinkSuccessful
+ goto_if_eq VAR_RESULT, LINKUP_FAILED, BattleFrontier_BattleTowerLobby_EventScript_ChooseLeader
+ goto_if_eq VAR_RESULT, LINKUP_RETRY_ROLE_ASSIGN, BattleFrontier_BattleTowerLobby_EventScript_TryBecomeLeader
+ goto_if_eq VAR_RESULT, LINKUP_FAILED_BATTLE_TOWER, BattleFrontier_BattleTowerLobby_EventScript_AbortLink
release
return
BattleFrontier_BattleTowerLobby_EventScript_TryJoinGroup::
call CableClub_EventScript_TryJoinLinkGroup
- compare VAR_RESULT, LINKUP_SUCCESS
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_WirelessLinkSuccessful
- compare VAR_RESULT, LINKUP_FAILED
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_ChooseLeader
- compare VAR_RESULT, LINKUP_RETRY_ROLE_ASSIGN
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_TryJoinGroup
- compare VAR_RESULT, LINKUP_FAILED_BATTLE_TOWER
- goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_AbortLink
+ goto_if_eq VAR_RESULT, LINKUP_SUCCESS, BattleFrontier_BattleTowerLobby_EventScript_WirelessLinkSuccessful
+ goto_if_eq VAR_RESULT, LINKUP_FAILED, BattleFrontier_BattleTowerLobby_EventScript_ChooseLeader
+ goto_if_eq VAR_RESULT, LINKUP_RETRY_ROLE_ASSIGN, BattleFrontier_BattleTowerLobby_EventScript_TryJoinGroup
+ goto_if_eq VAR_RESULT, LINKUP_FAILED_BATTLE_TOWER, BattleFrontier_BattleTowerLobby_EventScript_AbortLink
release
return