Use 'goto_if_eq VAR, value, Script' syntax

This commit is contained in:
GriffinR
2022-08-09 20:40:03 -04:00
parent 60fc8c5e22
commit f113da30ad
171 changed files with 1992 additions and 3453 deletions
@@ -8,10 +8,8 @@ ThreeIsland_DunsparceTunnel_OnTransition::
setworldmapflag FLAG_WORLD_MAP_THREE_ISLAND_DUNSPARCE_TUNNEL
specialvar VAR_RESULT, IsNationalPokedexEnabled
copyvar VAR_0x8008, VAR_RESULT
compare VAR_0x8008, TRUE
call_if_eq ThreeIsland_DunsparceTunnel_EventScript_SetLayoutDugOut
compare VAR_0x8008, FALSE
call_if_eq ThreeIsland_DunsparceTunnel_EventScript_MoveProspectorToWall
call_if_eq VAR_0x8008, TRUE, ThreeIsland_DunsparceTunnel_EventScript_SetLayoutDugOut
call_if_eq VAR_0x8008, FALSE, ThreeIsland_DunsparceTunnel_EventScript_MoveProspectorToWall
end
ThreeIsland_DunsparceTunnel_EventScript_SetLayoutDugOut::
@@ -28,8 +26,7 @@ ThreeIsland_DunsparceTunnel_EventScript_Prospector::
faceplayer
goto_if_set FLAG_GOT_NUGGET_FROM_DUNSPARCE_TUNNEL, ThreeIsland_DunsparceTunnel_EventScript_ProspectorAlreadyGaveNugget
specialvar VAR_RESULT, IsNationalPokedexEnabled
compare VAR_RESULT, TRUE
goto_if_eq ThreeIsland_DunsparceTunnel_EventScript_ProspectorStruckGold
goto_if_eq VAR_RESULT, TRUE, ThreeIsland_DunsparceTunnel_EventScript_ProspectorStruckGold
msgbox ThreeIsland_DunsparceTunnel_Text_ProspectingForGold
closemessage
applymovement LOCALID_PROSPECTOR, Movement_FaceOriginalDirection
@@ -40,8 +37,7 @@ ThreeIsland_DunsparceTunnel_EventScript_Prospector::
ThreeIsland_DunsparceTunnel_EventScript_ProspectorStruckGold::
msgbox ThreeIsland_DunsparceTunnel_Text_StruckGoldThisIsForYou
giveitem ITEM_NUGGET
compare VAR_RESULT, FALSE
goto_if_eq ThreeIsland_DunsparceTunnel_EventScript_NoRoomForNugget
goto_if_eq VAR_RESULT, FALSE, ThreeIsland_DunsparceTunnel_EventScript_NoRoomForNugget
setflag FLAG_GOT_NUGGET_FROM_DUNSPARCE_TUNNEL
goto ThreeIsland_DunsparceTunnel_EventScript_ProspectorAlreadyGaveNugget
end