Files
pokeemerald/data/maps/BattleFrontier_OutsideEast/scripts.inc
2025-06-11 09:45:39 -04:00

247 lines
7.1 KiB
PHP

BattleFrontier_OutsideEast_MapScripts::
map_script MAP_SCRIPT_ON_RESUME, BattleFrontier_OutsideEast_OnResume
map_script MAP_SCRIPT_ON_TRANSITION, BattleFrontier_OutsideEast_OnTransition
.byte 0
BattleFrontier_OutsideEast_OnResume:
call_if_set FLAG_SYS_CTRL_OBJ_DELETE, BattleFrontier_OutsideEast_EventScript_TryRemoveSudowoodo
end
BattleFrontier_OutsideEast_EventScript_TryRemoveSudowoodo::
specialvar VAR_RESULT, GetBattleOutcome
goto_if_ne VAR_RESULT, B_OUTCOME_CAUGHT, Common_EventScript_NopReturn
removeobject VAR_LAST_TALKED
return
BattleFrontier_OutsideEast_OnTransition:
setvar VAR_BRAVO_TRAINER_BATTLE_TOWER_ON, 0
setflag FLAG_HIDE_BATTLE_TOWER_REPORTER
call_if_unset FLAG_DEFEATED_SUDOWOODO, BattleFrontier_OutsideEast_EventScript_ShowSudowoodo
end
BattleFrontier_OutsideEast_EventScript_ShowSudowoodo::
clearflag FLAG_HIDE_BATTLE_FRONTIER_SUDOWOODO
return
BattleFrontier_OutsideEast_EventScript_BattleTowerSign::
msgbox BattleFrontier_OutsideEast_Text_BattleTowerSign, MSGBOX_SIGN
end
BattleFrontier_OutsideEast_EventScript_BattlePalaceSign::
msgbox BattleFrontier_OutsideEast_Text_BattlePalaceSign, MSGBOX_SIGN
end
BattleFrontier_OutsideEast_EventScript_BattleArenaSign::
msgbox BattleFrontier_OutsideEast_Text_BattleArenaSign, MSGBOX_SIGN
end
BattleFrontier_OutsideEast_EventScript_BattlePyramidSign::
msgbox BattleFrontier_OutsideEast_Text_BattlePyramidSign, MSGBOX_SIGN
end
BattleFrontier_OutsideEast_EventScript_NinjaBoy::
msgbox BattleFrontier_OutsideEast_Text_BattleTowerFeelsSpecial, MSGBOX_NPC
end
BattleFrontier_OutsideEast_EventScript_Man1::
msgbox BattleFrontier_OutsideEast_Text_ConquerLeagueAndFrontier, MSGBOX_NPC
end
BattleFrontier_OutsideEast_EventScript_Hiker::
msgbox BattleFrontier_OutsideEast_Text_PyramidTooHarsh, MSGBOX_NPC
end
BattleFrontier_OutsideEast_EventScript_HexManiac::
msgbox BattleFrontier_OutsideEast_Text_ThriveInDarkness, MSGBOX_NPC
end
BattleFrontier_OutsideEast_EventScript_BlackBelt1::
msgbox BattleFrontier_OutsideEast_Text_PutTogetherUltimateTeam, MSGBOX_NPC
end
BattleFrontier_OutsideEast_EventScript_Cook::
lock
msgbox BattleFrontier_OutsideEast_Text_BelieveInYouBuddy, MSGBOX_DEFAULT
release
end
BattleFrontier_OutsideEast_EventScript_Zigzagoon::
lock
faceplayer
waitse
playmoncry SPECIES_ZIGZAGOON, CRY_MODE_NORMAL
msgbox BattleFrontier_OutsideEast_Text_ZigzagoonLooksVacant, MSGBOX_DEFAULT
waitmoncry
release
end
BattleFrontier_OutsideEast_EventScript_RichBoy::
msgbox BattleFrontier_OutsideEast_Text_PeopleCallMeBusybody, MSGBOX_NPC
end
BattleFrontier_OutsideEast_EventScript_ExpertF::
msgbox BattleFrontier_OutsideEast_Text_OnceBeatGymLeader, MSGBOX_NPC
end
BattleFrontier_OutsideEast_EventScript_TriathleteF::
msgbox BattleFrontier_OutsideEast_Text_FastOnBikeAndBattles, MSGBOX_NPC
end
BattleFrontier_OutsideEast_EventScript_Twin::
msgbox BattleFrontier_OutsideEast_Text_BetterThanDaddyAtPokemon, MSGBOX_NPC
end
BattleFrontier_OutsideEast_EventScript_Man2::
lock
msgbox BattleFrontier_OutsideEast_Text_GoRackUpSomeWinsForDaddy, MSGBOX_DEFAULT
release
end
BattleFrontier_OutsideEast_EventScript_TriathleteM::
msgbox BattleFrontier_OutsideEast_Text_DidScottBringYouHere, MSGBOX_NPC
end
BattleFrontier_OutsideEast_EventScript_Sudowoodo::
lock
faceplayer
waitse
playse SE_SUDOWOODO_SHAKE
applymovement LOCALID_FRONTIER_SUDOWOODO, BattleFrontier_OutsideEast_Movement_SudowoodoShake
waitmovement 0
release
end
BattleFrontier_OutsideEast_EventScript_WaterSudowoodo::
lock
faceplayer
special DoWateringBerryTreeAnim
waitstate
waitse
playse SE_SUDOWOODO_SHAKE
applymovement LOCALID_FRONTIER_SUDOWOODO, BattleFrontier_OutsideEast_Movement_SudowoodoShake
waitmovement 0
msgbox gText_Sudowoodo_Attacked, MSGBOX_DEFAULT
closemessage
waitse
playmoncry SPECIES_SUDOWOODO, CRY_MODE_ENCOUNTER
delay 40
waitmoncry
setvar VAR_LAST_TALKED, LOCALID_FRONTIER_SUDOWOODO
setwildbattle SPECIES_SUDOWOODO, 40
setflag FLAG_SYS_CTRL_OBJ_DELETE
dowildbattle
clearflag FLAG_SYS_CTRL_OBJ_DELETE
specialvar VAR_RESULT, GetBattleOutcome
goto_if_eq VAR_RESULT, B_OUTCOME_WON, BattleFrontier_OutsideEast_EventScript_DefeatedSudowoodo
goto_if_eq VAR_RESULT, B_OUTCOME_RAN, BattleFrontier_OutsideEast_EventScript_DefeatedSudowoodo
goto_if_eq VAR_RESULT, B_OUTCOME_PLAYER_TELEPORTED, BattleFrontier_OutsideEast_EventScript_DefeatedSudowoodo
setflag FLAG_DEFEATED_SUDOWOODO
release
end
BattleFrontier_OutsideEast_EventScript_DefeatedSudowoodo::
setflag FLAG_DEFEATED_SUDOWOODO
goto Common_EventScript_RemoveStaticPokemon
end
BattleFrontier_OutsideEast_Movement_SudowoodoShake:
face_right
delay_8
face_down
delay_8
face_left
delay_8
face_down
delay_8
face_right
delay_8
face_down
delay_8
face_left
delay_8
face_down
step_end
BattleFrontier_OutsideEast_EventScript_Maniac1::
msgbox BattleFrontier_OutsideEast_Text_HeardPrettyGirlAtBattleArena, MSGBOX_NPC
end
BattleFrontier_OutsideEast_EventScript_Girl::
msgbox BattleFrontier_OutsideEast_Text_SometimesImportantOldManInThere, MSGBOX_NPC
end
BattleFrontier_OutsideEast_EventScript_PsychicM::
msgbox BattleFrontier_OutsideEast_Text_LegendOfBattlePyramid, MSGBOX_NPC
end
BattleFrontier_OutsideEast_EventScript_Man3::
msgbox BattleFrontier_OutsideEast_Text_GotWipedOut, MSGBOX_NPC
end
BattleFrontier_OutsideEast_EventScript_Woman1::
msgbox BattleFrontier_OutsideEast_Text_ToughTrainerInBattleTower, MSGBOX_NPC
end
BattleFrontier_OutsideEast_EventScript_Woman2::
msgbox BattleFrontier_OutsideEast_Text_EnoughBattlePointsForDoll, MSGBOX_NPC
end
BattleFrontier_OutsideEast_EventScript_BlackBelt2::
msgbox BattleFrontier_OutsideEast_Text_LikeToHaveNameRecordedHere, MSGBOX_NPC
end
BattleFrontier_OutsideEast_EventScript_Maniac2::
lock
msgbox BattleFrontier_OutsideEast_Text_CanDoAnythingWithYou, MSGBOX_DEFAULT
release
end
BattleFrontier_OutsideEast_EventScript_Woman3::
lock
msgbox BattleFrontier_OutsideEast_Text_PowerOfOurLoveWillOvercome, MSGBOX_DEFAULT
release
end
BattleFrontier_OutsideEast_EventScript_RankingHallSign::
msgbox BattleFrontier_OutsideEast_Text_RankingHallSign, MSGBOX_SIGN
end
BattleFrontier_OutsideEast_EventScript_ExchangeCornerSign::
msgbox BattleFrontier_OutsideEast_Text_ExchangeCornerSign, MSGBOX_SIGN
end
BattleFrontier_OutsideEast_EventScript_Gentleman::
msgbox BattleFrontier_OutsideEast_Text_FrontierNotExclusivelyForToughTrainers, MSGBOX_NPC
end
BattleFrontier_OutsideEast_EventScript_OldWoman::
lock
faceplayer
goto_if_set FLAG_DEFEATED_SUDOWOODO, BattleFrontier_OutsideEast_EventScript_OldWomanSudowoodoGone
msgbox BattleFrontier_OutsideEast_Text_OddTreeHereSeemsToWiggle, MSGBOX_DEFAULT
release
end
BattleFrontier_OutsideEast_EventScript_OldWomanSudowoodoGone::
msgbox BattleFrontier_OutsideEast_Text_OnceAnOddTreePastHere, MSGBOX_DEFAULT
release
end
BattleFrontier_OutsideEast_EventScript_Camper::
msgbox BattleFrontier_OutsideEast_Text_StickyMonWithLongTail, MSGBOX_NPC
end
.ifdef FRENCH
.include "data/maps/BattleFrontier_OutsideEast/text_fr.inc"
.else
.ifdef ITALIAN
.include "data/maps/BattleFrontier_OutsideEast/text_it.inc"
.else
.ifdef SPANISH
.include "data/maps/BattleFrontier_OutsideEast/text_es.inc"
.else
.include "data/maps/BattleFrontier_OutsideEast/text.inc"
.endif
.endif
.endif