summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorentrpntr <entrpntr@gmail.com>2020-05-20 23:47:59 -0400
committerentrpntr <entrpntr@gmail.com>2020-05-21 10:59:38 -0400
commit96c806efc484c7a57476ac17515d62ac1d0515a8 (patch)
tree21bd541defee1a8ef4bb0331f93584d6e7fb3db6
parentaf844aa35c0731bbee14039a274aa151e75a35d9 (diff)
Disassemble remainder of bank $40.
-rw-r--r--constants/event_flags.asm48
-rw-r--r--data/text/std_text.asm422
-rw-r--r--engine/events/std_scripts.asm774
-rw-r--r--layout.link2
-rw-r--r--main.asm6
5 files changed, 1224 insertions, 28 deletions
diff --git a/constants/event_flags.asm b/constants/event_flags.asm
index 2aa6bf22..58127c6a 100644
--- a/constants/event_flags.asm
+++ b/constants/event_flags.asm
@@ -621,7 +621,7 @@
const EVENT_GAVE_KURT_PNK_APRICORN
; Phone events
const EVENT_JACK_ASKED_FOR_PHONE_NUMBER
- const EVENT_JACK_READY_FOR_REMATCH ; 0260
+ const EVENT_JACK_READY_FOR_REMATCH ; 260
const EVENT_BEVERLY_ASKED_FOR_PHONE_NUMBER
const EVENT_BEVERLY_READY_FOR_REMATCH
const EVENT_HUEY_ASKED_FOR_PHONE_NUMBER
@@ -637,7 +637,7 @@
const EVENT_BETH_ASKED_FOR_PHONE_NUMBER
const EVENT_BETH_READY_FOR_REMATCH
const EVENT_JOSE_ASKED_FOR_PHONE_NUMBER
- const EVENT_JOSE_READY_FOR_REMATCH ; 0270
+ const EVENT_JOSE_READY_FOR_REMATCH ; 270
const EVENT_REENA_ASKED_FOR_PHONE_NUMBER
const EVENT_REENA_READY_FOR_REMATCH
const EVENT_JOEY_ASKED_FOR_PHONE_NUMBER
@@ -1669,7 +1669,7 @@
; The map script command macros `disappear` and `appear` set/clear these flags and immediately apply the effect on visibility.
; The map script command macros `setevent` and `clearevent` set/clear these flags, and their effects will be seen when the map is reloaded.
; Johto itemballs
- const EVENT_CYNDAQUIL_POKEBALL_IN_ELMS_LAB
+ const EVENT_CYNDAQUIL_POKEBALL_IN_ELMS_LAB ; 640
const EVENT_TOTODILE_POKEBALL_IN_ELMS_LAB
const EVENT_CHIKORITA_POKEBALL_IN_ELMS_LAB
const EVENT_VIOLET_CITY_PP_UP
@@ -1685,7 +1685,7 @@
const EVENT_TIN_TOWER_4F_PP_UP
const EVENT_TIN_TOWER_4F_ESCAPE_ROPE
const EVENT_TIN_TOWER_5F_RARE_CANDY
- const EVENT_TIN_TOWER_7F_MAX_REVIVE
+ const EVENT_TIN_TOWER_7F_MAX_REVIVE ; 650
const EVENT_TIN_TOWER_8F_NUGGET
const EVENT_TIN_TOWER_8F_MAX_ELIXER
const EVENT_TIN_TOWER_8F_FULL_RESTORE
@@ -1701,7 +1701,7 @@
const EVENT_UNION_CAVE_1F_AWAKENING
const EVENT_UNION_CAVE_B1F_TM_SWIFT
const EVENT_UNION_CAVE_B1F_X_DEFEND
- const EVENT_UNION_CAVE_B2F_ELIXER
+ const EVENT_UNION_CAVE_B2F_ELIXER ; 660
const EVENT_UNION_CAVE_B2F_HYPER_POTION
const EVENT_SLOWPOKE_WELL_B1F_SUPER_POTION
const EVENT_SLOWPOKE_WELL_B2F_TM_RAIN_DANCE
@@ -1717,7 +1717,7 @@
const EVENT_TEAM_ROCKET_BASE_B3F_FULL_HEAL
const EVENT_TEAM_ROCKET_BASE_B3F_DIRE_HIT
const EVENT_TEAM_ROCKET_BASE_B3F_PROTEIN
- const EVENT_TEAM_ROCKET_BASE_B3F_ICE_HEAL
+ const EVENT_TEAM_ROCKET_BASE_B3F_ICE_HEAL ; 670
const EVENT_ILEX_FOREST_REVIVE
const EVENT_GOLDENROD_UNDERGROUND_COIN_CASE
const EVENT_GOLDENROD_UNDERGROUND_SWITCH_ROOM_ENTRANCES_SMOKE_BALL
@@ -1733,7 +1733,7 @@
const EVENT_MOUNT_MORTAR_1F_INSIDE_ESCAPE_ROPE
const EVENT_MOUNT_MORTAR_1F_INSIDE_MAX_REVIVE
const EVENT_MOUNT_MORTAR_1F_INSIDE_HYPER_POTION
- const EVENT_MOUNT_MORTAR_2F_INSIDE_MAX_POTION
+ const EVENT_MOUNT_MORTAR_2F_INSIDE_MAX_POTION ; 680
const EVENT_MOUNT_MORTAR_2F_INSIDE_RARE_CANDY
const EVENT_MOUNT_MORTAR_2F_INSIDE_TM_DEFENSE_CURL
const EVENT_MOUNT_MORTAR_2F_INSIDE_DRAGON_SCALE
@@ -1749,7 +1749,7 @@
const EVENT_ICE_PATH_B2F_BLACKTHORN_SIDE_TM_REST
const EVENT_ICE_PATH_B3F_NEVERMELTICE
const EVENT_WHIRL_ISLAND_NE_ULTRA_BALL
- const EVENT_WHIRL_ISLAND_SW_GUARD_SPEC
+ const EVENT_WHIRL_ISLAND_SW_GUARD_SPEC ; 690
const EVENT_WHIRL_ISLAND_B1F_FULL_RESTORE
const EVENT_WHIRL_ISLAND_B1F_CARBOS
const EVENT_WHIRL_ISLAND_B1F_CALCIUM
@@ -1765,7 +1765,7 @@
const EVENT_SILVER_CAVE_ITEM_ROOMS_FULL_RESTORE
const EVENT_DARK_CAVE_VIOLET_ENTRANCE_POTION
const EVENT_DARK_CAVE_VIOLET_ENTRANCE_FULL_HEAL
- const EVENT_DARK_CAVE_VIOLET_ENTRANCE_HYPER_POTION
+ const EVENT_DARK_CAVE_VIOLET_ENTRANCE_HYPER_POTION ; 6a0
const EVENT_DARK_CAVE_BLACKTHORN_ENTRANCE_REVIVE
const EVENT_DARK_CAVE_BLACKTHORN_ENTRANCE_TM_SNORE
const EVENT_VICTORY_ROAD_TM_EARTHQUAKE
@@ -1781,7 +1781,7 @@
const EVENT_ROUTE_29_POTION
const EVENT_ROUTE_31_ANTIDOTE
const EVENT_ROUTE_31_POKE_BALL
- const EVENT_ROUTE_32_GREAT_BALL
+ const EVENT_ROUTE_32_GREAT_BALL ; 6b0
const EVENT_ROUTE_32_POTION
const EVENT_ROUTE_35_TM_ROLLOUT
const EVENT_ROUTE_42_ULTRA_BALL
@@ -1798,7 +1798,7 @@
const EVENT_RIVAL_NEW_BARK_TOWN
const EVENT_RIVAL_CHERRYGROVE_CITY
const EVENT_RIVAL_AZALEA_TOWN
- const EVENT_RIVAL_TEAM_ROCKET_BASE
+ const EVENT_RIVAL_TEAM_ROCKET_BASE ; 6c0
const EVENT_RIVAL_GOLDENROD_UNDERGROUND
const EVENT_RIVAL_VICTORY_ROAD
const EVENT_RIVAL_OLIVINE_CITY
@@ -1814,7 +1814,7 @@
const EVENT_GOLDENROD_CITY_ROCKET_TAKEOVER
const EVENT_RADIO_TOWER_ROCKET_TAKEOVER
const EVENT_GOLDENROD_CITY_CIVILIANS
- const EVENT_RADIO_TOWER_CIVILIANS_AFTER
+ const EVENT_RADIO_TOWER_CIVILIANS_AFTER ; 6d0
const EVENT_RADIO_TOWER_BLACKBELT_BLOCKS_STAIRS
const EVENT_OLIVINE_LIGHTHOUSE_JASMINE
const EVENT_OLIVINE_GYM_JASMINE
@@ -1830,7 +1830,7 @@
const EVENT_TEAM_ROCKET_BASE_B2F_EXECUTIVE
const EVENT_TEAM_ROCKET_BASE_B2F_GRUNT_WITH_EXECUTIVE
const EVENT_TEAM_ROCKET_BASE_B2F_DRAGONITE
- const EVENT_TEAM_ROCKET_BASE_B2F_ELECTRODE_1
+ const EVENT_TEAM_ROCKET_BASE_B2F_ELECTRODE_1 ; 6e0
const EVENT_TEAM_ROCKET_BASE_B2F_ELECTRODE_2
const EVENT_TEAM_ROCKET_BASE_B2F_ELECTRODE_3
const EVENT_BLACKTHORN_CITY_SUPER_NERD_BLOCKS_GYM
@@ -1846,7 +1846,7 @@
const EVENT_ILEX_FOREST_FARFETCHD5
const EVENT_ILEX_FOREST_FARFETCHD6
const EVENT_ILEX_FOREST_FARFETCHD7
- const EVENT_ILEX_FOREST_FARFETCHD8
+ const EVENT_ILEX_FOREST_FARFETCHD8 ; 6f0
const EVENT_ILEX_FOREST_FARFETCHD9
const EVENT_ILEX_FOREST_FARFETCHD10
const EVENT_ILEX_FOREST_APPRENTICE
@@ -1862,7 +1862,7 @@
const EVENT_KURTS_HOUSE_SLOWPOKE
const EVENT_GUIDE_GENT_IN_HIS_HOUSE
const EVENT_GUIDE_GENT_VISIBLE_IN_CHERRYGROVE
- const EVENT_ELMS_AIDE_IN_VIOLET_POKEMON_CENTER
+ const EVENT_ELMS_AIDE_IN_VIOLET_POKEMON_CENTER ; 700
const EVENT_ELMS_AIDE_IN_LAB
const EVENT_COP_IN_ELMS_LAB
const EVENT_RUINS_OF_ALPH_OUTSIDE_SCIENTIST
@@ -1878,7 +1878,7 @@
const EVENT_BOULDER_IN_ICE_PATH_1A
const EVENT_BOULDER_IN_ICE_PATH_2A
const EVENT_BOULDER_IN_ICE_PATH_3A
- const EVENT_BOULDER_IN_ICE_PATH_4A
+ const EVENT_BOULDER_IN_ICE_PATH_4A ; 710
const EVENT_MYSTERY_GIFT_DELIVERY_GUY
const EVENT_MET_BILL
const EVENT_ECRUTEAK_POKE_CENTER_BILL
@@ -1894,7 +1894,7 @@
const EVENT_BUG_CATCHING_CONTESTANT_8A
const EVENT_BUG_CATCHING_CONTESTANT_9A
const EVENT_BUG_CATCHING_CONTESTANT_10A
- const EVENT_BUG_CATCHING_CONTESTANT_1B
+ const EVENT_BUG_CATCHING_CONTESTANT_1B ; 720
const EVENT_BUG_CATCHING_CONTESTANT_2B
const EVENT_BUG_CATCHING_CONTESTANT_3B
const EVENT_BUG_CATCHING_CONTESTANT_4B
@@ -1910,7 +1910,7 @@
const EVENT_FAST_SHIP_CABINS_NNW_NNE_NE_SAILOR
const EVENT_FAST_SHIP_B1F_SAILOR_LEFT
const EVENT_FAST_SHIP_B1F_SAILOR_RIGHT
- const EVENT_FAST_SHIP_CABINS_SE_SSE_GENTLEMAN
+ const EVENT_FAST_SHIP_CABINS_SE_SSE_GENTLEMAN ; 730
const EVENT_FAST_SHIP_CABINS_SE_SSE_CAPTAINS_CABIN_TWIN_1
const EVENT_FAST_SHIP_CABINS_SE_SSE_CAPTAINS_CABIN_TWIN_2
const EVENT_OLIVINE_PORT_PASSAGE_POKEFAN_M
@@ -1964,12 +1964,12 @@
const EVENT_GOLDENROD_DEPT_STORE_5F_HAPPINESS_EVENT_LADY
const EVENT_BURNED_TOWER_FIREBREATHER_DICK_NORMAL
const EVENT_BURNED_TOWER_FIREBREATHER_DICK_ASHES
- const EVENT_RANG_CLEAR_BELL_1
- const EVENT_RANG_CLEAR_BELL_2
- const EVENT_FLORIA_AT_FLOWER_SHOP
- const EVENT_FLORIA_AT_SUDOWOODO
- const EVENT_GOLDENROD_CITY_MOVE_TUTOR
- const EVENT_GOLDENROD_GAME_CORNER_MOVE_TUTOR
+ const EVENT_RANG_CLEAR_BELL_1 ; rename?
+ const EVENT_RANG_CLEAR_BELL_2 ; rename?
+ const EVENT_FLORIA_AT_FLOWER_SHOP ; rename?
+ const EVENT_FLORIA_AT_SUDOWOODO ; rename?
+ const EVENT_GOLDENROD_CITY_MOVE_TUTOR ; rename?
+ const EVENT_GOLDENROD_GAME_CORNER_MOVE_TUTOR ; rename?
; Kanto people
const EVENT_ROUTE_24_ROCKET
const EVENT_CERULEAN_GYM_ROCKET
diff --git a/data/text/std_text.asm b/data/text/std_text.asm
new file mode 100644
index 00000000..4c57e2e6
--- /dev/null
+++ b/data/text/std_text.asm
@@ -0,0 +1,422 @@
+NurseMornText:
+ text "Good morning!"
+ line "Welcome to our"
+ cont "#MON CENTER."
+ done
+
+NurseDayText:
+ text "Hello!"
+ line "Welcome to our"
+ cont "#MON CENTER."
+ done
+
+NurseNiteText:
+ text "Good evening!"
+ line "You're out late."
+
+ para "Welcome to our"
+ line "#MON CENTER."
+ done
+
+NurseAskHealText:
+ text "We can heal your"
+ line "#MON to perfect"
+ cont "health."
+
+ para "Shall we heal your"
+ line "#MON?"
+ done
+
+NurseTakePokemonText:
+ text "OK, may I see your"
+ line "#MON?"
+ done
+
+NurseReturnPokemonText:
+ text "Thank you for"
+ line "waiting."
+
+ para "Your #MON are"
+ line "fully healed."
+ done
+
+NurseGoodbyeText:
+ text "We hope to see you"
+ line "again."
+ done
+
+; not used
+ text "We hope to see you"
+ line "again."
+ done
+
+NursePokerusText:
+ text "Your #MON ap-"
+ line "pear to have tiny"
+
+ para "life forms stuck"
+ line "to them."
+
+ para "Your #MON are"
+ line "healthy and seem"
+ cont "to be fine."
+
+ para "But we can't tell"
+ line "you anything more"
+
+ para "at a #MON"
+ line "CENTER."
+ done
+
+DifficultBookshelfText:
+ text "It's full of"
+ line "difficult books."
+ done
+
+PictureBookshelfText:
+ text "A whole collection"
+ line "of #MON picture"
+ cont "books!"
+ done
+
+MagazineBookshelfText:
+ text "#MON magazines…"
+ line "#MON PAL,"
+
+ para "#MON HANDBOOK,"
+ line "#MON GRAPH…"
+ done
+
+TeamRocketOathText:
+ text "TEAM ROCKET OATH"
+
+ para "Steal #MON for"
+ line "profit!"
+
+ para "Exploit #MON"
+ line "for profit!"
+
+ para "All #MON exist"
+ line "for the glory of"
+ cont "TEAM ROCKET!"
+ done
+
+IncenseBurnerText:
+ text "What is this?"
+
+ para "Oh, it's an"
+ line "incense burner!"
+ done
+
+MerchandiseShelfText:
+ text "Lots of #MON"
+ line "merchandise!"
+ done
+
+LookTownMapText:
+ text "It's the TOWN MAP."
+ done
+
+WindowText:
+ text "My reflection!"
+ line "Lookin' good!"
+ done
+
+TVText:
+ text "It's a TV."
+ done
+
+HomepageText:
+ text "#MON JOURNAL"
+ line "HOME PAGE…"
+
+ para "It hasn't been"
+ line "updated…"
+ done
+
+; not used
+ text "#MON RADIO!"
+
+ para "Call in with your"
+ line "requests now!"
+ done
+
+TrashCanText:
+ text "There's nothing in"
+ line "here…"
+ done
+
+; not used
+ text "A #MON may be"
+ line "able to move this."
+ done
+
+; not used
+ text "Maybe a #MON"
+ line "can break this."
+ done
+
+PokecenterSignText:
+ text "Heal Your #MON!"
+ line "#MON CENTER"
+ done
+
+MartSignText:
+ text "For All Your"
+ line "#MON Needs"
+
+ para "#MON MART"
+ done
+
+ContestResults_ReadyToJudgeText:
+ text "We will now judge"
+ line "the #MON you've"
+ cont "caught."
+
+ para "<……>"
+ line "<……>"
+
+ para "We have chosen the"
+ line "winners!"
+
+ para "Are you ready for"
+ line "this?"
+ done
+
+AskNumber1MText:
+ text "Wow! You're pretty"
+ line "tough."
+
+ para "Could I get your"
+ line "phone number?"
+
+ para "I'll call you for"
+ line "a rematch."
+ done
+
+AskNumber2MText:
+ text "Register the phone"
+ line "number?"
+ done
+
+RegisteredNumberMText:
+ text "<PLAYER> registered"
+ line "@"
+ text_ram wStringBuffer3
+ text "'s number."
+ done
+
+NumberAcceptedMText:
+ text "I'll call you if"
+ line "anything comes up."
+ done
+
+NumberDeclinedMText:
+ text "Oh, OK…"
+ line "Just talk to me if"
+
+ para "you want to get my"
+ line "phone number."
+ done
+
+PhoneFullMText:
+ text "Your phone doesn't"
+ line "have enough memory"
+ cont "for more numbers."
+ done
+
+RematchMText:
+ text "I was waiting for"
+ line "you. Let's battle!"
+ done
+
+AskNumber1FText:
+ text "Wow, you're good"
+ line "at battling."
+
+ para "Want to give me"
+ line "your phone number?"
+
+ para "I'll phone you for"
+ line "another battle."
+ done
+
+AskNumber2FText:
+ text "Register the phone"
+ line "number?"
+ done
+
+RegisteredNumberFText:
+ text "<PLAYER> registered"
+ line "@"
+ text_ram wStringBuffer3
+ text "'s number."
+ done
+
+NumberAcceptedFText:
+ text "I'll call you if"
+ line "something's up."
+ done
+
+NumberDeclinedFText:
+ text "Oh, fine then…"
+ line "If you want to get"
+
+ para "my phone number,"
+ line "just tell me."
+ done
+
+PhoneFullFText:
+ text "Your phone doesn't"
+ line "have enough memory"
+ cont "for more numbers."
+ done
+
+RematchFText:
+ text "I waited for you."
+ line "Let's battle!"
+ done
+
+ContestResults_PlayerWonAPrizeText:
+ text "<PLAYER> wins the"
+ line "No. @"
+ text_ram wStringBuffer3
+ text " prize,"
+ cont "a @"
+ text_ram wStringBuffer4
+ text "!"
+ done
+
+ReceivedItemText:
+ text "<PLAYER> received"
+ line "@"
+ text_ram wStringBuffer4
+ text "."
+ done
+
+ContestResults_JoinUsNextTimeText:
+ text "Please join us for"
+ line "the next Contest!"
+ done
+
+ContestResults_ConsolationPrizeText:
+ text "Everyone else gets"
+ line "a BERRY as a con-"
+ cont "solation prize!"
+ done
+
+ContestResults_DidNotWinText:
+ text "We hope you do"
+ line "better next time."
+ done
+
+ContestResults_ReturnPartyText:
+ text "We'll return the"
+ line "#MON we kept"
+
+ para "for you."
+ line "Here you go!"
+ done
+
+ContestResults_PartyFullText:
+ text "Your party's full,"
+ line "so the #MON was"
+
+ para "sent to your BOX"
+ line "in BILL's PC."
+ done
+
+GymStatue_CityGymText:
+ text_ram wStringBuffer3
+ text_start
+ line "#MON GYM"
+ done
+
+GymStatue_WinningTrainersText:
+ text "LEADER: @"
+ text_ram wStringBuffer4
+ text_start
+ para "WINNING TRAINERS:"
+ line "<PLAYER>"
+ done
+
+CoinVendor_WelcomeText:
+ text "Welcome to the"
+ line "GAME CORNER."
+ done
+
+CoinVendor_NoCoinCaseText:
+ text "Do you need game"
+ line "coins?"
+
+ para "Oh, you don't have"
+ line "a COIN CASE for"
+ cont "your coins."
+ done
+
+CoinVendor_IntroText:
+ text "Do you need some"
+ line "game coins?"
+
+ para "It costs ¥1000 for"
+ line "50 coins. Do you"
+ cont "want some?"
+ done
+
+CoinVendor_Buy50CoinsText:
+ text "Thank you!"
+ line "Here are 50 coins."
+ done
+
+CoinVendor_Buy500CoinsText:
+ text "Thank you! Here"
+ line "are 500 coins."
+ done
+
+CoinVendor_NotEnoughMoneyText:
+ text "You don't have"
+ line "enough money."
+ done
+
+CoinVendor_CoinCaseFullText:
+ text "Whoops! Your COIN"
+ line "CASE is full."
+ done
+
+CoinVendor_CancelText:
+ text "No coins for you?"
+ line "Come again!"
+ done
+
+BugContestPrizeNoRoomText:
+ text "Oh? Your PACK is"
+ line "full."
+
+ para "We'll keep this"
+ line "for you today, so"
+
+ para "come back when you"
+ line "make room for it."
+ done
+
+HappinessText3:
+ text "Wow! You and your"
+ line "#MON are really"
+ cont "close!"
+ done
+
+HappinessText2:
+ text "#MON get more"
+ line "friendly if you"
+
+ para "spend time with"
+ line "them."
+ done
+
+HappinessText1:
+ text "You haven't tamed"
+ line "your #MON."
+
+ para "If you aren't"
+ line "nice, it'll pout."
+ done
diff --git a/engine/events/std_scripts.asm b/engine/events/std_scripts.asm
new file mode 100644
index 00000000..bdc90c55
--- /dev/null
+++ b/engine/events/std_scripts.asm
@@ -0,0 +1,774 @@
+StdScripts::
+; entries correspond to constants/std_constants.asm
+ dba PokecenterNurseScript
+ dba DifficultBookshelfScript
+ dba PictureBookshelfScript
+ dba MagazineBookshelfScript
+ dba TeamRocketOathScript
+ dba IncenseBurnerScript
+ dba MerchandiseShelfScript
+ dba TownMapScript
+ dba WindowScript
+ dba TVScript
+ dba HomepageScript
+ dba Radio1Script
+ dba Radio2Script
+ dba TrashCanScript
+ dba StrengthBoulderScript
+ dba SmashRockScript
+ dba PokecenterSignScript
+ dba MartSignScript
+ dba GoldenrodRocketsScript
+ dba RadioTowerRocketsScript
+ dba ElevatorButtonScript
+ dba DayToTextScript
+ dba BugContestResultsWarpScript
+ dba BugContestResultsScript
+ dba InitializeEventsScript
+ dba AskNumber1MScript
+ dba AskNumber2MScript
+ dba RegisteredNumberMScript
+ dba NumberAcceptedMScript
+ dba NumberDeclinedMScript
+ dba PhoneFullMScript
+ dba RematchMScript
+ dba AskNumber1FScript
+ dba AskNumber2FScript
+ dba RegisteredNumberFScript
+ dba NumberAcceptedFScript
+ dba NumberDeclinedFScript
+ dba PhoneFullFScript
+ dba RematchFScript
+ dba GymStatue1Script
+ dba GymStatue2Script
+ dba ReceiveItemScript
+ dba ReceiveTogepiEggScript
+ dba PCScript
+ dba GameCornerCoinVendorScript
+ dba HappinessCheckScript
+
+PokecenterNurseScript:
+ opentext
+ checktime MORN
+ iftrue .morn
+ checktime DAY
+ iftrue .day
+ checktime NITE
+ iftrue .nite
+ sjump .ok
+
+.morn
+ writetext NurseMornText
+ promptbutton
+ sjump .ok
+
+.day
+ writetext NurseDayText
+ promptbutton
+ sjump .ok
+
+.nite
+ writetext NurseNiteText
+ promptbutton
+ sjump .ok
+
+.ok
+ writetext NurseAskHealText
+ yesorno
+ iffalse .done
+
+ writetext NurseTakePokemonText
+ pause 20
+ turnobject LAST_TALKED, LEFT
+ pause 10
+ special HealParty
+ playmusic MUSIC_NONE
+ setval HEALMACHINE_POKECENTER
+ special HealMachineAnim
+ pause 30
+ special RestartMapMusic
+ turnobject LAST_TALKED, DOWN
+ pause 10
+
+ checkphonecall ; elm already called about pokerus
+ iftrue .no
+ checkflag ENGINE_CAUGHT_POKERUS
+ iftrue .no
+ special CheckPokerus
+ iftrue .pokerus
+.no
+ writetext NurseReturnPokemonText
+ pause 20
+
+.done
+ writetext NurseGoodbyeText
+
+ turnobject LAST_TALKED, UP
+ pause 10
+ turnobject LAST_TALKED, DOWN
+ pause 10
+
+ waitbutton
+ closetext
+ end
+
+.pokerus
+ writetext NursePokerusText
+ waitbutton
+ closetext
+ setflag ENGINE_CAUGHT_POKERUS
+ specialphonecall SPECIALCALL_POKERUS
+ end
+
+DifficultBookshelfScript:
+ jumptext DifficultBookshelfText
+
+PictureBookshelfScript:
+ jumptext PictureBookshelfText
+
+MagazineBookshelfScript:
+ jumptext MagazineBookshelfText
+
+TeamRocketOathScript:
+ jumptext TeamRocketOathText
+
+IncenseBurnerScript:
+ jumptext IncenseBurnerText
+
+MerchandiseShelfScript:
+ jumptext MerchandiseShelfText
+
+TownMapScript:
+ opentext
+ writetext LookTownMapText
+ waitbutton
+ special OverworldTownMap
+ closetext
+ end
+
+WindowScript:
+ jumptext WindowText
+
+TVScript:
+ opentext
+ writetext TVText
+ waitbutton
+ closetext
+ end
+
+HomepageScript:
+ jumptext HomepageText
+
+Radio1Script:
+ opentext
+ setval MAPRADIO_POKEMON_CHANNEL
+ special MapRadio
+ closetext
+ end
+
+Radio2Script:
+; Lucky Channel
+ opentext
+ setval MAPRADIO_LUCKY_CHANNEL
+ special MapRadio
+ closetext
+ end
+
+TrashCanScript:
+ jumptext TrashCanText
+
+PCScript:
+ opentext
+ special PokemonCenterPC
+ closetext
+ end
+
+ElevatorButtonScript:
+ playsound SFX_READ_TEXT_2
+ pause 15
+ playsound SFX_ELEVATOR_END
+ end
+
+StrengthBoulderScript:
+ farsjump AskStrengthScript
+
+SmashRockScript:
+ farsjump AskRockSmashScript
+
+PokecenterSignScript:
+ jumptext PokecenterSignText
+
+MartSignScript:
+ jumptext MartSignText
+
+DayToTextScript:
+ readvar VAR_WEEKDAY
+ ifequal MONDAY, .Monday
+ ifequal TUESDAY, .Tuesday
+ ifequal WEDNESDAY, .Wednesday
+ ifequal THURSDAY, .Thursday
+ ifequal FRIDAY, .Friday
+ ifequal SATURDAY, .Saturday
+ getstring STRING_BUFFER_3, .SundayText
+ end
+.Monday:
+ getstring STRING_BUFFER_3, .MondayText
+ end
+.Tuesday:
+ getstring STRING_BUFFER_3, .TuesdayText
+ end
+.Wednesday:
+ getstring STRING_BUFFER_3, .WednesdayText
+ end
+.Thursday:
+ getstring STRING_BUFFER_3, .ThursdayText
+ end
+.Friday:
+ getstring STRING_BUFFER_3, .FridayText
+ end
+.Saturday:
+ getstring STRING_BUFFER_3, .SaturdayText
+ end
+.SundayText:
+ db "SUNDAY@"
+.MondayText:
+ db "MONDAY@"
+.TuesdayText:
+ db "TUESDAY@"
+.WednesdayText:
+ db "WEDNESDAY@"
+.ThursdayText:
+ db "THURSDAY@"
+.FridayText:
+ db "FRIDAY@"
+.SaturdayText:
+ db "SATURDAY@"
+
+GoldenrodRocketsScript:
+ clearevent EVENT_GOLDENROD_CITY_ROCKET_TAKEOVER
+ end
+
+RadioTowerRocketsScript:
+ setflag ENGINE_ROCKETS_IN_RADIO_TOWER
+ setevent EVENT_GOLDENROD_CITY_CIVILIANS
+ setevent EVENT_RADIO_TOWER_BLACKBELT_BLOCKS_STAIRS
+ clearevent EVENT_RADIO_TOWER_ROCKET_TAKEOVER
+ clearevent EVENT_USED_THE_CARD_KEY_IN_THE_RADIO_TOWER
+ setevent EVENT_MAHOGANY_TOWN_POKEFAN_M_BLOCKS_EAST
+ specialphonecall SPECIALCALL_WEIRDBROADCAST
+ setmapscene MAHOGANY_TOWN, SCENE_FINISHED
+ end
+
+BugContestResultsWarpScript:
+ special ClearBGPalettes
+ scall BugContestResults_CopyContestantsToResults
+ setevent EVENT_ROUTE_36_NATIONAL_PARK_GATE_OFFICER_CONTEST_DAY
+ clearevent EVENT_ROUTE_36_NATIONAL_PARK_GATE_OFFICER_NOT_CONTEST_DAY
+ setevent EVENT_WARPED_FROM_ROUTE_35_NATIONAL_PARK_GATE
+ warp ROUTE_36_NATIONAL_PARK_GATE, 0, 4
+ applymovement PLAYER, Movement_ContestResults_WalkAfterWarp
+
+BugContestResultsScript:
+ clearflag ENGINE_BUG_CONTEST_TIMER
+ clearevent EVENT_WARPED_FROM_ROUTE_35_NATIONAL_PARK_GATE
+ clearevent EVENT_CONTEST_OFFICER_HAS_SUN_STONE
+ clearevent EVENT_CONTEST_OFFICER_HAS_EVERSTONE
+ clearevent EVENT_CONTEST_OFFICER_HAS_GOLD_BERRY
+ clearevent EVENT_CONTEST_OFFICER_HAS_BERRY
+ opentext
+ writetext ContestResults_ReadyToJudgeText
+ waitbutton
+ special BugContestJudging
+ getnum STRING_BUFFER_3
+ ifequal 1, BugContestResults_FirstPlace
+ ifequal 2, BugContestResults_SecondPlace
+ ifequal 3, BugContestResults_ThirdPlace
+ writetext ContestResults_ConsolationPrizeText
+ promptbutton
+ waitsfx
+ verbosegiveitem BERRY
+ iffalse BugContestResults_NoRoomForBerry
+
+BugContestResults_DidNotWin:
+ writetext ContestResults_DidNotWinText
+ promptbutton
+ sjump BugContestResults_FinishUp
+
+BugContestResults_ReturnAfterWinnersPrize:
+ writetext ContestResults_JoinUsNextTimeText
+ promptbutton
+
+BugContestResults_FinishUp:
+ checkevent EVENT_LEFT_MONS_WITH_CONTEST_OFFICER
+ iffalse BugContestResults_DidNotLeaveMons
+ writetext ContestResults_ReturnPartyText
+ waitbutton
+ special ContestReturnMons
+BugContestResults_DidNotLeaveMons:
+ special CheckPartyFullAfterContest
+ ifequal BUGCONTEST_CAUGHT_MON, BugContestResults_CleanUp
+ ifequal BUGCONTEST_NO_CATCH, BugContestResults_CleanUp
+ ; BUGCONTEST_BOXED_MON
+ writetext ContestResults_PartyFullText
+ waitbutton
+BugContestResults_CleanUp:
+ closetext
+ setscene SCENE_ROUTE36NATIONALPARKGATE_NOTHING
+ setmapscene ROUTE_35_NATIONAL_PARK_GATE, SCENE_ROUTE35NATIONALPARKGATE_NOTHING
+ setevent EVENT_BUG_CATCHING_CONTESTANT_1A
+ setevent EVENT_BUG_CATCHING_CONTESTANT_2A
+ setevent EVENT_BUG_CATCHING_CONTESTANT_3A
+ setevent EVENT_BUG_CATCHING_CONTESTANT_4A
+ setevent EVENT_BUG_CATCHING_CONTESTANT_5A
+ setevent EVENT_BUG_CATCHING_CONTESTANT_6A
+ setevent EVENT_BUG_CATCHING_CONTESTANT_7A
+ setevent EVENT_BUG_CATCHING_CONTESTANT_8A
+ setevent EVENT_BUG_CATCHING_CONTESTANT_9A
+ setevent EVENT_BUG_CATCHING_CONTESTANT_10A
+ setevent EVENT_BUG_CATCHING_CONTESTANT_1B
+ setevent EVENT_BUG_CATCHING_CONTESTANT_2B
+ setevent EVENT_BUG_CATCHING_CONTESTANT_3B
+ setevent EVENT_BUG_CATCHING_CONTESTANT_4B
+ setevent EVENT_BUG_CATCHING_CONTESTANT_5B
+ setevent EVENT_BUG_CATCHING_CONTESTANT_6B
+ setevent EVENT_BUG_CATCHING_CONTESTANT_7B
+ setevent EVENT_BUG_CATCHING_CONTESTANT_8B
+ setevent EVENT_BUG_CATCHING_CONTESTANT_9B
+ setevent EVENT_BUG_CATCHING_CONTESTANT_10B
+ setflag ENGINE_DAILY_BUG_CONTEST
+ special PlayMapMusic
+ end
+
+BugContestResults_FirstPlace:
+ setevent EVENT_TEMPORARY_UNTIL_MAP_RELOAD_1
+ getitemname STRING_BUFFER_4, SUN_STONE
+ writetext ContestResults_PlayerWonAPrizeText
+ waitbutton
+ verbosegiveitem SUN_STONE
+ iffalse BugContestResults_NoRoomForSunStone
+ sjump BugContestResults_ReturnAfterWinnersPrize
+
+BugContestResults_SecondPlace:
+ getitemname STRING_BUFFER_4, EVERSTONE
+ writetext ContestResults_PlayerWonAPrizeText
+ waitbutton
+ verbosegiveitem EVERSTONE
+ iffalse BugContestResults_NoRoomForEverstone
+ sjump BugContestResults_ReturnAfterWinnersPrize
+
+BugContestResults_ThirdPlace:
+ getitemname STRING_BUFFER_4, GOLD_BERRY
+ writetext ContestResults_PlayerWonAPrizeText
+ waitbutton
+ verbosegiveitem GOLD_BERRY
+ iffalse BugContestResults_NoRoomForGoldBerry
+ sjump BugContestResults_ReturnAfterWinnersPrize
+
+BugContestResults_NoRoomForSunStone:
+ writetext BugContestPrizeNoRoomText
+ promptbutton
+ setevent EVENT_CONTEST_OFFICER_HAS_SUN_STONE
+ sjump BugContestResults_ReturnAfterWinnersPrize
+
+BugContestResults_NoRoomForEverstone:
+ writetext BugContestPrizeNoRoomText
+ promptbutton
+ setevent EVENT_CONTEST_OFFICER_HAS_EVERSTONE
+ sjump BugContestResults_ReturnAfterWinnersPrize
+
+BugContestResults_NoRoomForGoldBerry:
+ writetext BugContestPrizeNoRoomText
+ promptbutton
+ setevent EVENT_CONTEST_OFFICER_HAS_GOLD_BERRY
+ sjump BugContestResults_ReturnAfterWinnersPrize
+
+BugContestResults_NoRoomForBerry:
+ writetext BugContestPrizeNoRoomText
+ promptbutton
+ setevent EVENT_CONTEST_OFFICER_HAS_BERRY
+ sjump BugContestResults_DidNotWin
+
+BugContestResults_CopyContestantsToResults:
+ checkevent EVENT_BUG_CATCHING_CONTESTANT_1A
+ iftrue .skip1
+ clearevent EVENT_BUG_CATCHING_CONTESTANT_1B
+.skip1
+ checkevent EVENT_BUG_CATCHING_CONTESTANT_2A
+ iftrue .skip2
+ clearevent EVENT_BUG_CATCHING_CONTESTANT_2B
+.skip2
+ checkevent EVENT_BUG_CATCHING_CONTESTANT_3A
+ iftrue .skip3
+ clearevent EVENT_BUG_CATCHING_CONTESTANT_3B
+.skip3
+ checkevent EVENT_BUG_CATCHING_CONTESTANT_4A
+ iftrue .skip4
+ clearevent EVENT_BUG_CATCHING_CONTESTANT_4B
+.skip4
+ checkevent EVENT_BUG_CATCHING_CONTESTANT_5A
+ iftrue .skip5
+ clearevent EVENT_BUG_CATCHING_CONTESTANT_5B
+.skip5
+ checkevent EVENT_BUG_CATCHING_CONTESTANT_6A
+ iftrue .skip6
+ clearevent EVENT_BUG_CATCHING_CONTESTANT_6B
+.skip6
+ checkevent EVENT_BUG_CATCHING_CONTESTANT_7A
+ iftrue .skip7
+ clearevent EVENT_BUG_CATCHING_CONTESTANT_7B
+.skip7
+ checkevent EVENT_BUG_CATCHING_CONTESTANT_8A
+ iftrue .skip8
+ clearevent EVENT_BUG_CATCHING_CONTESTANT_8B
+.skip8
+ checkevent EVENT_BUG_CATCHING_CONTESTANT_9A
+ iftrue .skip9
+ clearevent EVENT_BUG_CATCHING_CONTESTANT_9B
+.skip9
+ checkevent EVENT_BUG_CATCHING_CONTESTANT_10A
+ iftrue .skip10
+ clearevent EVENT_BUG_CATCHING_CONTESTANT_10B
+.skip10
+ end
+
+InitializeEventsScript:
+ setevent EVENT_EARLS_ACADEMY_EARL
+ setevent EVENT_RADIO_TOWER_ROCKET_TAKEOVER
+ setevent EVENT_GOLDENROD_CITY_ROCKET_TAKEOVER
+ setevent EVENT_RADIO_TOWER_CIVILIANS_AFTER
+ setevent EVENT_ILEX_FOREST_APPRENTICE
+ setevent EVENT_ILEX_FOREST_FARFETCHD1
+ setevent EVENT_ILEX_FOREST_FARFETCHD2
+ setevent EVENT_ILEX_FOREST_FARFETCHD3
+ setevent EVENT_ILEX_FOREST_FARFETCHD4
+ setevent EVENT_ILEX_FOREST_FARFETCHD5
+ setevent EVENT_ILEX_FOREST_FARFETCHD6
+ setevent EVENT_ILEX_FOREST_FARFETCHD7
+ setevent EVENT_ILEX_FOREST_FARFETCHD8
+ setevent EVENT_ILEX_FOREST_FARFETCHD9
+ setevent EVENT_ILEX_FOREST_FARFETCHD10
+ setevent EVENT_ILEX_FOREST_CHARCOAL_MASTER
+ setevent EVENT_MAHOGANY_MART_LANCE_AND_DRAGONITE
+ setevent EVENT_TEAM_ROCKET_BASE_B2F_GRUNT_WITH_EXECUTIVE
+ setevent EVENT_TEAM_ROCKET_BASE_B2F_EXECUTIVE
+ setevent EVENT_TEAM_ROCKET_BASE_B2F_DRAGONITE
+ setevent EVENT_RIVAL_TEAM_ROCKET_BASE
+ setevent EVENT_BLACKTHORN_CITY_SUPER_NERD_DOES_NOT_BLOCK_GYM
+ setevent EVENT_USED_THE_CARD_KEY_IN_THE_RADIO_TOWER
+ setevent EVENT_RIVAL_CHERRYGROVE_CITY
+ setevent EVENT_RIVAL_AZALEA_TOWN
+ setevent EVENT_RIVAL_GOLDENROD_UNDERGROUND
+ setevent EVENT_AZALEA_TOWN_SLOWPOKES
+ setevent EVENT_KURTS_HOUSE_SLOWPOKE
+ setevent EVENT_GUIDE_GENT_VISIBLE_IN_CHERRYGROVE
+ setevent EVENT_ELMS_AIDE_IN_VIOLET_POKEMON_CENTER
+ setevent EVENT_COP_IN_ELMS_LAB
+ setevent EVENT_RUINS_OF_ALPH_OUTSIDE_SCIENTIST
+ setevent EVENT_RUINS_OF_ALPH_RESEARCH_CENTER_SCIENTIST
+ setevent EVENT_BOULDER_IN_ICE_PATH_1A
+ setevent EVENT_BOULDER_IN_ICE_PATH_2A
+ setevent EVENT_BOULDER_IN_ICE_PATH_3A
+ setevent EVENT_BOULDER_IN_ICE_PATH_4A
+ setevent EVENT_ROUTE_30_YOUNGSTER_JOEY
+ setevent EVENT_BUG_CATCHING_CONTESTANT_1A
+ setevent EVENT_BUG_CATCHING_CONTESTANT_2A
+ setevent EVENT_BUG_CATCHING_CONTESTANT_3A
+ setevent EVENT_BUG_CATCHING_CONTESTANT_4A
+ setevent EVENT_BUG_CATCHING_CONTESTANT_5A
+ setevent EVENT_BUG_CATCHING_CONTESTANT_6A
+ setevent EVENT_BUG_CATCHING_CONTESTANT_7A
+ setevent EVENT_BUG_CATCHING_CONTESTANT_8A
+ setevent EVENT_BUG_CATCHING_CONTESTANT_9A
+ setevent EVENT_BUG_CATCHING_CONTESTANT_10A
+ setevent EVENT_BUG_CATCHING_CONTESTANT_1B
+ setevent EVENT_BUG_CATCHING_CONTESTANT_2B
+ setevent EVENT_BUG_CATCHING_CONTESTANT_3B
+ setevent EVENT_BUG_CATCHING_CONTESTANT_4B
+ setevent EVENT_BUG_CATCHING_CONTESTANT_5B
+ setevent EVENT_BUG_CATCHING_CONTESTANT_6B
+ setevent EVENT_BUG_CATCHING_CONTESTANT_7B
+ setevent EVENT_BUG_CATCHING_CONTESTANT_8B
+ setevent EVENT_BUG_CATCHING_CONTESTANT_9B
+ setevent EVENT_BUG_CATCHING_CONTESTANT_10B
+ setevent EVENT_FAST_SHIP_1F_GENTLEMAN
+ setevent EVENT_FAST_SHIP_B1F_SAILOR_RIGHT
+ setevent EVENT_FAST_SHIP_CABINS_NNW_NNE_NE_SAILOR
+ setevent EVENT_LAKE_OF_RAGE_CIVILIANS
+ setevent EVENT_MAHOGANY_MART_OWNERS
+ setevent EVENT_TIN_TOWER_ROOF_HO_OH
+ setevent EVENT_WHIRL_ISLAND_LUGIA_CHAMBER_LUGIA
+ setevent EVENT_PLAYERS_HOUSE_2F_CONSOLE
+ setevent EVENT_PLAYERS_HOUSE_2F_DOLL_1
+ setevent EVENT_PLAYERS_HOUSE_2F_DOLL_2
+ setevent EVENT_PLAYERS_HOUSE_2F_BIG_DOLL
+ setevent EVENT_DECO_BED_1
+ setevent EVENT_DECO_POSTER_1
+ setevent EVENT_GOLDENROD_TRAIN_STATION_GENTLEMAN
+ setevent EVENT_OLIVINE_GYM_JASMINE
+ setevent EVENT_BLACKTHORN_CITY_GRAMPS_NOT_BLOCKING_DRAGONS_DEN
+ setevent EVENT_MET_BILL
+ setevent EVENT_ECRUTEAK_POKE_CENTER_BILL
+ setevent EVENT_MYSTERY_GIFT_DELIVERY_GUY
+ setevent EVENT_LAKE_OF_RAGE_LANCE
+ setevent EVENT_GOLDENROD_DEPT_STORE_B1F_LAYOUT_1
+ setevent EVENT_GOLDENROD_UNDERGROUND_WAREHOUSE_BLOCKED_OFF
+ setevent EVENT_DRAGONS_DEN_CLAIR
+ setevent EVENT_RIVAL_OLIVINE_CITY
+ setevent EVENT_RIVAL_VICTORY_ROAD
+ setevent EVENT_RIVAL_DRAGONS_DEN
+ setevent EVENT_LANCES_ROOM_OAK_AND_MARY
+ setevent EVENT_FAST_SHIP_CABINS_SE_SSE_CAPTAINS_CABIN_TWIN_1
+ setevent EVENT_BURNED_TOWER_B1F_BEASTS_1
+ setevent EVENT_RED_IN_MT_SILVER
+ setevent EVENT_OLIVINE_PORT_SPRITES_AFTER_HALL_OF_FAME
+ setevent EVENT_FAST_SHIP_PASSENGERS_EASTBOUND
+ setevent EVENT_FAST_SHIP_PASSENGERS_WESTBOUND
+ setevent EVENT_OLIVINE_PORT_PASSAGE_POKEFAN_M
+ setevent EVENT_KURTS_HOUSE_KURT_2
+ setevent EVENT_BURNED_TOWER_FIREBREATHER_DICK_ASHES
+ setevent EVENT_RANG_CLEAR_BELL_1 ; ?
+ setevent EVENT_PLAYERS_HOUSE_MOM_2
+ setflag ENGINE_ROCKET_SIGNAL_ON_CH20
+ setflag ENGINE_ROCKETS_IN_MAHOGANY
+ variablesprite SPRITE_WEIRD_TREE, SPRITE_SUDOWOODO
+ variablesprite SPRITE_OLIVINE_RIVAL, SPRITE_SILVER
+ variablesprite SPRITE_AZALEA_ROCKET, SPRITE_ROCKET
+ variablesprite SPRITE_FUCHSIA_GYM_1, SPRITE_JANINE
+ variablesprite SPRITE_FUCHSIA_GYM_2, SPRITE_JANINE
+ variablesprite SPRITE_FUCHSIA_GYM_3, SPRITE_JANINE
+ variablesprite SPRITE_FUCHSIA_GYM_4, SPRITE_JANINE
+ variablesprite SPRITE_COPYCAT, SPRITE_LASS
+ variablesprite SPRITE_JANINE_IMPERSONATOR, SPRITE_LASS
+ setevent EVENT_FOUND_MACHINE_PART_IN_CERULEAN_GYM
+ setevent EVENT_CERULEAN_GYM_ROCKET
+ setevent EVENT_ROUTE_24_ROCKET
+ setevent EVENT_ROUTE_25_MISTY_BOYFRIEND
+ setevent EVENT_TRAINERS_IN_CERULEAN_GYM
+ setevent EVENT_COPYCATS_HOUSE_2F_DOLL
+ setevent EVENT_VIRIDIAN_GYM_BLUE
+ setevent EVENT_SEAFOAM_GYM_GYM_GUY
+ setevent EVENT_MT_MOON_SQUARE_CLEFAIRY
+ setevent EVENT_SAFFRON_TRAIN_STATION_POPULATION
+ setevent EVENT_INDIGO_PLATEAU_POKECENTER_RIVAL
+ setevent EVENT_INITIALIZED_EVENTS
+ return
+
+AskNumber1MScript:
+ writetext AskNumber1MText
+ end
+
+AskNumber2MScript:
+ writetext AskNumber2MText
+ end
+
+RegisteredNumberMScript:
+ writetext RegisteredNumberMText
+ playsound SFX_REGISTER_PHONE_NUMBER
+ waitsfx
+ promptbutton
+ end
+
+NumberAcceptedMScript:
+ writetext NumberAcceptedMText
+ waitbutton
+ closetext
+ end
+
+NumberDeclinedMScript:
+ writetext NumberDeclinedMText
+ waitbutton
+ closetext
+ end
+
+PhoneFullMScript:
+ writetext PhoneFullMText
+ waitbutton
+ closetext
+ end
+
+RematchMScript:
+ writetext RematchMText
+ waitbutton
+ closetext
+ end
+
+AskNumber1FScript:
+ writetext AskNumber1FText
+ end
+
+AskNumber2FScript:
+ writetext AskNumber2FText
+ end
+
+RegisteredNumberFScript:
+ writetext RegisteredNumberFText
+ playsound SFX_REGISTER_PHONE_NUMBER
+ waitsfx
+ promptbutton
+ end
+
+NumberAcceptedFScript:
+ writetext NumberAcceptedFText
+ waitbutton
+ closetext
+ end
+
+NumberDeclinedFScript:
+ writetext NumberDeclinedFText
+ waitbutton
+ closetext
+ end
+
+PhoneFullFScript:
+ writetext PhoneFullFText
+ waitbutton
+ closetext
+ end
+
+RematchFScript:
+ writetext RematchFText
+ waitbutton
+ closetext
+ end
+
+GymStatue1Script:
+ getcurlandmarkname STRING_BUFFER_3
+ opentext
+ writetext GymStatue_CityGymText
+ waitbutton
+ closetext
+ end
+
+GymStatue2Script:
+ getcurlandmarkname STRING_BUFFER_3
+ opentext
+ writetext GymStatue_CityGymText
+ promptbutton
+ writetext GymStatue_WinningTrainersText
+ waitbutton
+ closetext
+ end
+
+ReceiveItemScript:
+ waitsfx
+ writetext ReceivedItemText
+ playsound SFX_ITEM
+ waitsfx
+ end
+
+ReceiveTogepiEggScript:
+ waitsfx
+ writetext ReceivedItemText
+ playsound SFX_GET_EGG
+ waitsfx
+ end
+
+GameCornerCoinVendorScript:
+ faceplayer
+ opentext
+ writetext CoinVendor_WelcomeText
+ promptbutton
+ checkitem COIN_CASE
+ iftrue CoinVendor_IntroScript
+ writetext CoinVendor_NoCoinCaseText
+ waitbutton
+ closetext
+ end
+
+CoinVendor_IntroScript:
+ writetext CoinVendor_IntroText
+
+.loop
+ special DisplayMoneyAndCoinBalance
+ loadmenu .MenuHeader
+ verticalmenu
+ closewindow
+ ifequal 1, .Buy50
+ ifequal 2, .Buy500
+ sjump .Cancel
+
+.Buy50:
+ checkcoins MAX_COINS - 50
+ ifequal HAVE_MORE, .CoinCaseFull
+ checkmoney YOUR_MONEY, 1000
+ ifequal HAVE_LESS, .NotEnoughMoney
+ givecoins 50
+ takemoney YOUR_MONEY, 1000
+ waitsfx
+ playsound SFX_TRANSACTION
+ writetext CoinVendor_Buy50CoinsText
+ waitbutton
+ sjump .loop
+
+.Buy500:
+ checkcoins MAX_COINS - 500
+ ifequal HAVE_MORE, .CoinCaseFull
+ checkmoney YOUR_MONEY, 10000
+ ifequal HAVE_LESS, .NotEnoughMoney
+ givecoins 500
+ takemoney YOUR_MONEY, 10000
+ waitsfx
+ playsound SFX_TRANSACTION
+ writetext CoinVendor_Buy500CoinsText
+ waitbutton
+ sjump .loop
+
+.NotEnoughMoney:
+ writetext CoinVendor_NotEnoughMoneyText
+ waitbutton
+ closetext
+ end
+
+.CoinCaseFull:
+ writetext CoinVendor_CoinCaseFullText
+ waitbutton
+ closetext
+ end
+
+.Cancel:
+ writetext CoinVendor_CancelText
+ waitbutton
+ closetext
+ end
+
+.MenuHeader:
+ db MENU_BACKUP_TILES ; flags
+ menu_coords 0, 4, 15, TEXTBOX_Y - 1
+ dw .MenuData
+ db 1 ; default option
+
+.MenuData:
+ db STATICMENU_CURSOR ; flags
+ db 3 ; items
+ db " 50 : ¥1000@"
+ db "500 : ¥10000@"
+ db "CANCEL@"
+
+HappinessCheckScript:
+ faceplayer
+ opentext
+ special GetFirstPokemonHappiness
+ ifless 50, .Unhappy
+ ifless 150, .KindaHappy
+ writetext HappinessText3
+ waitbutton
+ closetext
+ end
+
+.KindaHappy:
+ writetext HappinessText2
+ waitbutton
+ closetext
+ end
+
+.Unhappy:
+ writetext HappinessText1
+ waitbutton
+ closetext
+ end
+
+Movement_ContestResults_WalkAfterWarp:
+ step RIGHT
+ step DOWN
+ turn_head UP
+ step_end
diff --git a/layout.link b/layout.link
index 984869b6..1512a858 100644
--- a/layout.link
+++ b/layout.link
@@ -154,7 +154,7 @@ ROMX $3e
ROMX $3f
"bank3f"
ROMX $40
- "bank40"
+ "Standard Scripts"
ROMX $41
"bank41"
ROMX $42
diff --git a/main.asm b/main.asm
index 31eb277f..9a8b6b98 100644
--- a/main.asm
+++ b/main.asm
@@ -876,10 +876,10 @@ InitMysteryGiftLayout::
dr $fcfb2, $fde20
-SECTION "bank40", ROMX
+SECTION "Standard Scripts", ROMX
-StdScripts::
- dr $100000, $10110c
+INCLUDE "engine/events/std_scripts.asm"
+INCLUDE "data/text/std_text.asm"
INCLUDE "data/text/battle.asm"