summaryrefslogtreecommitdiff
path: root/data/maps/SouthernIsland_Interior/scripts.inc
diff options
context:
space:
mode:
Diffstat (limited to 'data/maps/SouthernIsland_Interior/scripts.inc')
-rw-r--r--data/maps/SouthernIsland_Interior/scripts.inc30
1 files changed, 10 insertions, 20 deletions
diff --git a/data/maps/SouthernIsland_Interior/scripts.inc b/data/maps/SouthernIsland_Interior/scripts.inc
index 4ce90e249..c46cefefc 100644
--- a/data/maps/SouthernIsland_Interior/scripts.inc
+++ b/data/maps/SouthernIsland_Interior/scripts.inc
@@ -11,16 +11,13 @@ SouthernIsland_Interior_OnResume:
SouthernIsland_Interior_EventScript_TryRemoveLati::
specialvar VAR_RESULT, GetBattleOutcome
- compare VAR_RESULT, B_OUTCOME_CAUGHT
- goto_if_ne Common_EventScript_NopReturn
+ goto_if_ne VAR_RESULT, B_OUTCOME_CAUGHT, Common_EventScript_NopReturn
removeobject LOCALID_LATI
return
SouthernIsland_Interior_OnTransition:
- compare VAR_ROAMER_POKEMON, 0
- call_if_eq SouthernIsland_Interior_EventScript_SetUpLatios
- compare VAR_ROAMER_POKEMON, 0
- call_if_ne SouthernIsland_Interior_EventScript_SetUpLatias
+ call_if_eq VAR_ROAMER_POKEMON, 0, SouthernIsland_Interior_EventScript_SetUpLatios
+ call_if_ne VAR_ROAMER_POKEMON, 0, SouthernIsland_Interior_EventScript_SetUpLatias
call SouthernIsland_Interior_EventScript_SetUpPlayerGfx
end
@@ -36,10 +33,8 @@ SouthernIsland_Interior_EventScript_SetUpLatias::
SouthernIsland_Interior_EventScript_SetUpPlayerGfx::
checkplayergender
- compare VAR_RESULT, MALE
- goto_if_eq SouthernIsland_Interior_EventScript_SetBrendanGfx
- compare VAR_RESULT, FEMALE
- goto_if_eq SouthernIsland_Interior_EventScript_SetMayGfx
+ goto_if_eq VAR_RESULT, MALE, SouthernIsland_Interior_EventScript_SetBrendanGfx
+ goto_if_eq VAR_RESULT, FEMALE, SouthernIsland_Interior_EventScript_SetMayGfx
end
SouthernIsland_Interior_EventScript_SetBrendanGfx::
@@ -79,21 +74,16 @@ SouthernIsland_Interior_EventScript_Lati::
delay 50
special RemoveCameraObject
setvar VAR_LAST_TALKED, LOCALID_LATI
- compare VAR_ROAMER_POKEMON, 0
- call_if_eq SouthernIsland_Interior_EventScript_SetLatiosBattleVars
- compare VAR_ROAMER_POKEMON, 0
- call_if_ne SouthernIsland_Interior_EventScript_SetLatiasBattleVars
+ call_if_eq VAR_ROAMER_POKEMON, 0, SouthernIsland_Interior_EventScript_SetLatiosBattleVars
+ call_if_ne VAR_ROAMER_POKEMON, 0, SouthernIsland_Interior_EventScript_SetLatiasBattleVars
setflag FLAG_SYS_CTRL_OBJ_DELETE
special BattleSetup_StartLatiBattle
waitstate
clearflag FLAG_SYS_CTRL_OBJ_DELETE
specialvar VAR_RESULT, GetBattleOutcome
- compare VAR_RESULT, B_OUTCOME_WON
- goto_if_eq SouthernIsland_Interior_EventScript_LatiDefeated
- compare VAR_RESULT, B_OUTCOME_RAN
- goto_if_eq SouthernIsland_Interior_EventScript_RanFromLati
- compare VAR_RESULT, B_OUTCOME_PLAYER_TELEPORTED
- goto_if_eq SouthernIsland_Interior_EventScript_RanFromLati
+ goto_if_eq VAR_RESULT, B_OUTCOME_WON, SouthernIsland_Interior_EventScript_LatiDefeated
+ goto_if_eq VAR_RESULT, B_OUTCOME_RAN, SouthernIsland_Interior_EventScript_RanFromLati
+ goto_if_eq VAR_RESULT, B_OUTCOME_PLAYER_TELEPORTED, SouthernIsland_Interior_EventScript_RanFromLati
setflag FLAG_CAUGHT_LATIAS_OR_LATIOS
releaseall
end