pokeemerald/data/maps/EverGrandeCity_PokemonLeague_1F/scripts.inc

144 lines
4.4 KiB
PHP
Raw Normal View History

.set LOCALID_NURSE, 1
.set LOCALID_GUARD_1, 3
.set LOCALID_GUARD_2, 4
2021-07-20 21:18:31 +02:00
EverGrandeCity_PokemonLeague_1F_MapScripts::
2019-04-05 01:28:37 +02:00
map_script MAP_SCRIPT_ON_TRANSITION, EverGrandeCity_PokemonLeague_1F_OnTransition
2019-10-12 04:23:05 +02:00
map_script MAP_SCRIPT_ON_RESUME, CableClub_OnResume
2017-11-10 02:21:31 +01:00
.byte 0
2021-07-20 21:18:31 +02:00
EverGrandeCity_PokemonLeague_1F_OnTransition:
setrespawn HEAL_LOCATION_EVER_GRANDE_CITY_POKEMON_LEAGUE
2017-12-27 04:20:29 +01:00
setflag FLAG_LANDMARK_POKEMON_LEAGUE
2019-11-03 18:29:41 +01:00
call_if_unset FLAG_ENTERED_ELITE_FOUR, EverGrandeCity_PokemonLeague_1F_EventScript_GuardsBlockDoor
2017-11-10 02:21:31 +01:00
end
2021-07-20 21:18:31 +02:00
EverGrandeCity_PokemonLeague_1F_EventScript_GuardsBlockDoor::
setobjectxyperm LOCALID_GUARD_1, 9, 2
setobjectxyperm LOCALID_GUARD_2, 10, 2
2017-11-10 02:21:31 +01:00
return
2021-07-20 21:18:31 +02:00
EverGrandeCity_PokemonLeague_1F_EventScript_Nurse::
setvar VAR_0x800B, LOCALID_NURSE
2019-08-15 05:38:42 +02:00
call Common_EventScript_PkmnCenterNurse
2017-11-10 02:21:31 +01:00
waitmessage
waitbuttonpress
release
end
2021-07-20 21:18:31 +02:00
EverGrandeCity_PokemonLeague_1F_EventScript_Clerk::
2017-11-10 02:21:31 +01:00
lock
faceplayer
2019-08-15 05:38:42 +02:00
message gText_HowMayIServeYou
2017-11-10 02:21:31 +01:00
waitmessage
2019-11-03 18:29:41 +01:00
pokemart EverGrandeCity_PokemonLeague_1F_Pokemart
2019-08-15 05:38:42 +02:00
msgbox gText_PleaseComeAgain, MSGBOX_DEFAULT
2017-11-10 02:21:31 +01:00
release
end
.align 2
2021-07-20 21:18:31 +02:00
EverGrandeCity_PokemonLeague_1F_Pokemart:
2017-11-10 02:21:31 +01:00
.2byte ITEM_ULTRA_BALL
.2byte ITEM_HYPER_POTION
.2byte ITEM_MAX_POTION
.2byte ITEM_FULL_RESTORE
.2byte ITEM_FULL_HEAL
.2byte ITEM_REVIVE
.2byte ITEM_MAX_REPEL
.2byte ITEM_NONE
release
end
2019-11-03 18:29:41 +01:00
@ The door guards only check for FLAG_BADGE06_GET because Winonas badge is the only one that can be skipped
@ Its assumed the player has the remaining badges
2021-07-20 21:18:31 +02:00
EverGrandeCity_PokemonLeague_1F_EventScript_DoorGuard::
2017-11-10 02:21:31 +01:00
lockall
2019-11-03 18:29:41 +01:00
goto_if_set FLAG_ENTERED_ELITE_FOUR, EverGrandeCity_PokemonLeague_1F_EventScript_GoForth
2018-05-19 18:02:43 +02:00
getplayerxy VAR_TEMP_0, VAR_TEMP_1
call_if_ge VAR_TEMP_0, 11, EverGrandeCity_PokemonLeague_1F_EventScript_PlayerMoveToFrontFromRight
call_if_le VAR_TEMP_0, 8, EverGrandeCity_PokemonLeague_1F_EventScript_PlayerMoveToFrontFromLeft
2019-11-03 18:29:41 +01:00
message EverGrandeCity_PokemonLeague_1F_Text_MustHaveAllGymBadges
2017-11-10 02:21:31 +01:00
waitmessage
delay 120
2019-11-03 18:29:41 +01:00
goto_if_unset FLAG_BADGE06_GET, EverGrandeCity_PokemonLeague_1F_EventScript_NotAllBadges
2017-11-10 02:21:31 +01:00
closemessage
applymovement LOCALID_GUARD_1, EverGrandeCity_PokemonLeague_1F_Movement_LeftGuardOutOfWay
applymovement LOCALID_GUARD_2, EverGrandeCity_PokemonLeague_1F_Movement_RightGuardOutOfWay
2017-11-10 02:21:31 +01:00
waitmovement 0
delay 10
2020-08-21 00:02:00 +02:00
playfanfare MUS_OBTAIN_BADGE
2019-11-03 18:29:41 +01:00
message EverGrandeCity_PokemonLeague_1F_Text_GoForth
2017-11-10 02:21:31 +01:00
waitmessage
waitfanfare
closemessage
copyobjectxytoperm LOCALID_GUARD_1
copyobjectxytoperm LOCALID_GUARD_2
2019-01-02 22:12:43 +01:00
setflag FLAG_ENTERED_ELITE_FOUR
2017-11-10 02:21:31 +01:00
releaseall
end
2021-07-20 21:18:31 +02:00
EverGrandeCity_PokemonLeague_1F_EventScript_PlayerMoveToFrontFromRight::
applymovement OBJ_EVENT_ID_PLAYER, EverGrandeCity_PokemonLeague_1F_Movement_MoveToFrontFromRight
2017-11-10 02:21:31 +01:00
waitmovement 0
return
2021-07-20 21:18:31 +02:00
EverGrandeCity_PokemonLeague_1F_EventScript_PlayerMoveToFrontFromLeft::
applymovement OBJ_EVENT_ID_PLAYER, EverGrandeCity_PokemonLeague_1F_Movement_MoveToFrontFromLeft
2017-11-10 02:21:31 +01:00
waitmovement 0
return
2021-07-20 21:18:31 +02:00
EverGrandeCity_PokemonLeague_1F_EventScript_NotAllBadges::
2020-08-21 00:02:00 +02:00
playse SE_FAILURE
2019-11-03 18:29:41 +01:00
msgbox EverGrandeCity_PokemonLeague_1F_Text_HaventObtainedAllBadges, MSGBOX_DEFAULT
2017-11-10 02:21:31 +01:00
releaseall
end
2021-07-20 21:18:31 +02:00
EverGrandeCity_PokemonLeague_1F_EventScript_GoForth::
applymovement VAR_LAST_TALKED, Common_Movement_FacePlayer
2017-11-10 02:21:31 +01:00
waitmovement 0
2019-11-03 18:29:41 +01:00
msgbox EverGrandeCity_PokemonLeague_1F_Text_GoForth, MSGBOX_DEFAULT
2017-11-10 02:21:31 +01:00
closemessage
applymovement VAR_LAST_TALKED, Common_Movement_FaceOriginalDirection
2017-11-10 02:21:31 +01:00
waitmovement 0
releaseall
end
2021-07-20 21:18:31 +02:00
EverGrandeCity_PokemonLeague_1F_Movement_MoveToFrontFromRight:
walk_down
walk_left
walk_in_place_faster_up
2017-11-10 02:21:31 +01:00
step_end
2021-07-20 21:18:31 +02:00
EverGrandeCity_PokemonLeague_1F_Movement_MoveToFrontFromLeft:
walk_down
walk_right
walk_in_place_faster_up
2017-11-10 02:21:31 +01:00
step_end
2021-07-20 21:18:31 +02:00
EverGrandeCity_PokemonLeague_1F_Movement_LeftGuardOutOfWay:
walk_left
walk_in_place_faster_down
2017-11-10 02:21:31 +01:00
step_end
2021-07-20 21:18:31 +02:00
EverGrandeCity_PokemonLeague_1F_Movement_RightGuardOutOfWay:
walk_right
walk_in_place_faster_down
2017-11-10 02:21:31 +01:00
step_end
2021-07-20 21:18:31 +02:00
EverGrandeCity_PokemonLeague_1F_Text_MustHaveAllGymBadges:
2017-11-10 02:21:31 +01:00
.string "Beyond this point, only those TRAINERS\n"
.string "who have collected all the GYM BADGES\l"
.string "are permitted to enter.\p"
.string "TRAINER, let us confirm that you have\n"
.string "all the GYM BADGES.$"
2021-07-20 21:18:31 +02:00
EverGrandeCity_PokemonLeague_1F_Text_HaventObtainedAllBadges:
2018-12-07 16:41:08 +01:00
.string "You haven't obtained all the BADGES.\p"
.string "If you're bound for the POKéMON\n"
2017-11-10 02:21:31 +01:00
.string "LEAGUE, you must return with them.$"
2021-07-20 21:18:31 +02:00
EverGrandeCity_PokemonLeague_1F_Text_GoForth:
2017-11-10 02:21:31 +01:00
.string "TRAINER! Believe in yourself and your\n"
.string "POKéMON, and go forth!$"