summaryrefslogtreecommitdiff
path: root/data/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'data/scripts')
-rw-r--r--data/scripts/berry_tree.inc4
-rw-r--r--data/scripts/cable_club.inc76
-rw-r--r--data/scripts/cave_hole.inc33
-rw-r--r--data/scripts/cave_of_origin.inc43
-rw-r--r--data/scripts/check_furniture.inc27
-rw-r--r--data/scripts/contest_hall.inc138
-rw-r--r--data/scripts/day_care.inc54
-rw-r--r--data/scripts/debug.inc826
-rw-r--r--data/scripts/dynamic_npc_graphics.inc59
-rw-r--r--data/scripts/elite_four.inc62
-rw-r--r--data/scripts/gabby_and_ty.inc70
-rw-r--r--data/scripts/hall_of_fame.inc34
-rw-r--r--data/scripts/magma_chimney.inc42
-rw-r--r--data/scripts/magma_summit.inc24
-rw-r--r--data/scripts/mauville_man.inc56
-rw-r--r--data/scripts/movement.inc71
-rw-r--r--data/scripts/mystery_event_club.inc30
-rw-r--r--data/scripts/new_game.inc218
-rw-r--r--data/scripts/obtain_item.inc161
-rw-r--r--data/scripts/pc.inc66
-rw-r--r--data/scripts/pkmn_center_nurse.inc57
-rw-r--r--data/scripts/players_house.inc166
-rw-r--r--data/scripts/pokeblocks.inc74
-rw-r--r--data/scripts/prof_birch.inc84
-rw-r--r--data/scripts/record_mix.inc22
-rw-r--r--data/scripts/safari_zone.inc2
-rw-r--r--data/scripts/secret_base.inc683
-rw-r--r--data/scripts/secret_power_tm.inc12
-rw-r--r--data/scripts/set_gym_trainers.inc74
-rw-r--r--data/scripts/shared_secret_base.inc190
-rw-r--r--data/scripts/static_pokemon.inc177
-rw-r--r--data/scripts/std_msgbox.inc36
-rw-r--r--data/scripts/surf.inc16
-rw-r--r--data/scripts/trainer_battle.inc136
-rw-r--r--data/scripts/tv.inc10
35 files changed, 3041 insertions, 792 deletions
diff --git a/data/scripts/berry_tree.inc b/data/scripts/berry_tree.inc
index 1a72316bc..f7952540c 100644
--- a/data/scripts/berry_tree.inc
+++ b/data/scripts/berry_tree.inc
@@ -39,13 +39,13 @@ BerryTree_EventScript_1A1558:: @ 81A1558
end
BerryTree_EventScript_1A1577:: @ 81A1577
- fadescreen 1
+ fadescreen FADE_TO_BLACK
closemessage
special Berry_FadeAndGoToBerryBagMenu
waitstate
compare VAR_ITEM_ID, 0
goto_if_eq BerryTree_EventScript_1A1593
- takeitem VAR_ITEM_ID, 1
+ removeitem VAR_ITEM_ID, 1
call S_PlantBerryTree
BerryTree_EventScript_1A1593:: @ 81A1593
release
diff --git a/data/scripts/cable_club.inc b/data/scripts/cable_club.inc
index 56a03f346..0d84f3972 100644
--- a/data/scripts/cable_club.inc
+++ b/data/scripts/cable_club.inc
@@ -88,7 +88,7 @@ VerdanturfTown_PokemonCenter_2F_MapScript2_1A3D88:: @ 81A3D88
OldaleTown_PokemonCenter_2F_EventScript_1A3DB2:: @ 81A3DB2
special CloseLink
setvar VAR_CABLE_CLUB_STATE, 0
- applymovement 255, OldaleTown_PokemonCenter_2F_Movement_1A4358
+ applymovement OBJ_EVENT_ID_PLAYER, OldaleTown_PokemonCenter_2F_Movement_1A4358
waitmovement 0
compare VAR_0x8007, 0
goto_if_eq OldaleTown_PokemonCenter_2F_EventScript_1A3DD9
@@ -105,14 +105,14 @@ OldaleTown_PokemonCenter_2F_EventScript_1A3DDA:: @ 81A3DDA
goto_if_eq OldaleTown_PokemonCenter_2F_EventScript_1A3E0C
applymovement VAR_0x8007, OldaleTown_PokemonCenter_2F_Movement_1A4356
waitmovement 0
- applymovement 255, OldaleTown_PokemonCenter_2F_Movement_1A4358
+ applymovement OBJ_EVENT_ID_PLAYER, OldaleTown_PokemonCenter_2F_Movement_1A4358
waitmovement 0
applymovement VAR_0x8007, OldaleTown_PokemonCenter_2F_Movement_1A4354
waitmovement 0
return
OldaleTown_PokemonCenter_2F_EventScript_1A3E0C:: @ 81A3E0C
- applymovement 255, OldaleTown_PokemonCenter_2F_Movement_1A4358
+ applymovement OBJ_EVENT_ID_PLAYER, OldaleTown_PokemonCenter_2F_Movement_1A4358
waitmovement 0
return
@@ -130,7 +130,7 @@ OldaleTown_PokemonCenter_2F_EventScript_1A3E30:: @ 81A3E30
setvar VAR_CABLE_CLUB_STATE, 0
compare VAR_0x8007, 0
goto_if_eq OldaleTown_PokemonCenter_2F_EventScript_1A3E0C
- applymovement 255, OldaleTown_PokemonCenter_2F_Movement_1A4361
+ applymovement OBJ_EVENT_ID_PLAYER, OldaleTown_PokemonCenter_2F_Movement_1A4361
waitmovement 0
applymovement VAR_0x8007, OldaleTown_PokemonCenter_2F_Movement_1A4356
waitmovement 0
@@ -139,7 +139,7 @@ OldaleTown_PokemonCenter_2F_EventScript_1A3E30:: @ 81A3E30
playse SE_PIN
message OldaleTown_PokemonCenter_2F_Text_1A4E79
waitmessage
- applymovement 255, OldaleTown_PokemonCenter_2F_Movement_1A4358
+ applymovement OBJ_EVENT_ID_PLAYER, OldaleTown_PokemonCenter_2F_Movement_1A4358
waitmovement 0
applymovement VAR_0x8007, OldaleTown_PokemonCenter_2F_Movement_1A4354
waitmovement 0
@@ -190,7 +190,7 @@ OldaleTown_PokemonCenter_2F_EventScript_1A3EBC:: @ 81A3EBC
case 127, OldaleTown_PokemonCenter_2F_EventScript_1A4319
OldaleTown_PokemonCenter_2F_EventScript_1A3EF2:: @ 81A3EF2
- call S_DoSaveDialog
+ call Common_EventScript_SaveGame
compare VAR_RESULT, 0
goto_if_eq OldaleTown_PokemonCenter_2F_EventScript_1A4319
call OldaleTown_PokemonCenter_2F_EventScript_1A3FEF
@@ -226,13 +226,13 @@ OldaleTown_PokemonCenter_2F_EventScript_1A3F5E:: @ 81A3F5E
applymovement VAR_LAST_TALKED, OldaleTown_PokemonCenter_2F_Movement_1A4356
waitmovement 0
closemessage
- applymovement 255, OldaleTown_PokemonCenter_2F_Movement_1A435B
+ applymovement OBJ_EVENT_ID_PLAYER, OldaleTown_PokemonCenter_2F_Movement_1A435B
waitmovement 0
opendoor 5, 1
waitdooranim
- applymovement 255, OldaleTown_PokemonCenter_2F_Movement_1A435F
+ applymovement OBJ_EVENT_ID_PLAYER, OldaleTown_PokemonCenter_2F_Movement_1A435F
waitmovement 0
- hideobjectat 255, MAP_PETALBURG_CITY
+ hideobjectat OBJ_EVENT_ID_PLAYER, MAP_PETALBURG_CITY
closedoor 5, 1
waitdooranim
release
@@ -279,8 +279,8 @@ OldaleTown_PokemonCenter_2F_EventScript_1A403C:: @ 81A403C
return
OldaleTown_PokemonCenter_2F_EventScript_1A4042:: @ 81A4042
- special CheckForAlivePartyMons
- compare VAR_RESULT, 0
+ special HasEnoughMonsForDoubleBattle
+ compare VAR_RESULT, PLAYER_HAS_TWO_USABLE_MONS
goto_if_ne OldaleTown_PokemonCenter_2F_EventScript_1A4056
setvar VAR_0x8004, 2
return
@@ -359,7 +359,7 @@ OldaleTown_PokemonCenter_2F_EventScript_1A40FA:: @ 81A40FA
call OldaleTown_PokemonCenter_2F_EventScript_1A41BB
compare VAR_RESULT, 0
goto_if_eq OldaleTown_PokemonCenter_2F_EventScript_1A4319
- call S_DoSaveDialog
+ call Common_EventScript_SaveGame
compare VAR_RESULT, 0
goto_if_eq OldaleTown_PokemonCenter_2F_EventScript_1A4319
message OldaleTown_PokemonCenter_2F_Text_1A490C
@@ -390,13 +390,13 @@ OldaleTown_PokemonCenter_2F_EventScript_1A4166:: @ 81A4166
applymovement VAR_LAST_TALKED, OldaleTown_PokemonCenter_2F_Movement_1A4356
waitmovement 0
closemessage
- applymovement 255, OldaleTown_PokemonCenter_2F_Movement_1A435B
+ applymovement OBJ_EVENT_ID_PLAYER, OldaleTown_PokemonCenter_2F_Movement_1A435B
waitmovement 0
opendoor 8, 1
waitdooranim
- applymovement 255, OldaleTown_PokemonCenter_2F_Movement_1A435F
+ applymovement OBJ_EVENT_ID_PLAYER, OldaleTown_PokemonCenter_2F_Movement_1A435F
waitmovement 0
- hideobjectat 255, MAP_PETALBURG_CITY
+ hideobjectat OBJ_EVENT_ID_PLAYER, MAP_PETALBURG_CITY
closedoor 8, 1
waitdooranim
release
@@ -452,7 +452,7 @@ VerdanturfTown_PokemonCenter_2F_EventScript_1A41FB:: @ 81A41FB
goto_if_eq OldaleTown_PokemonCenter_2F_EventScript_1A4229
OldaleTown_PokemonCenter_2F_EventScript_1A4229:: @ 81A4229
- call S_DoSaveDialog
+ call Common_EventScript_SaveGame
compare VAR_RESULT, 0
goto_if_eq OldaleTown_PokemonCenter_2F_EventScript_1A4319
message OldaleTown_PokemonCenter_2F_Text_1A490C
@@ -487,13 +487,13 @@ OldaleTown_PokemonCenter_2F_EventScript_1A4294:: @ 81A4294
applymovement VAR_LAST_TALKED, OldaleTown_PokemonCenter_2F_Movement_1A4356
waitmovement 0
closemessage
- applymovement 255, OldaleTown_PokemonCenter_2F_Movement_1A435B
+ applymovement OBJ_EVENT_ID_PLAYER, OldaleTown_PokemonCenter_2F_Movement_1A435B
waitmovement 0
opendoor 11, 1
waitdooranim
- applymovement 255, OldaleTown_PokemonCenter_2F_Movement_1A435F
+ applymovement OBJ_EVENT_ID_PLAYER, OldaleTown_PokemonCenter_2F_Movement_1A435F
waitmovement 0
- hideobjectat 255, MAP_PETALBURG_CITY
+ hideobjectat OBJ_EVENT_ID_PLAYER, MAP_PETALBURG_CITY
closedoor 11, 1
waitdooranim
release
@@ -554,43 +554,43 @@ OldaleTown_PokemonCenter_2F_EventScript_1A432D:: @ 81A432D
end
OldaleTown_PokemonCenter_2F_EventScript_1A4339:: @ 81A4339
- msgbox OldaleTown_PokemonCenter_2F_Text_1A141C, 2
+ msgbox OldaleTown_PokemonCenter_2F_Text_1A141C, MSGBOX_NPC
end
OldaleTown_PokemonCenter_2F_EventScript_1A4342:: @ 81A4342
- msgbox OldaleTown_PokemonCenter_2F_Text_1A13DF, 2
+ msgbox OldaleTown_PokemonCenter_2F_Text_1A13DF, MSGBOX_NPC
end
OldaleTown_PokemonCenter_2F_EventScript_1A434B:: @ 81A434B
- msgbox OldaleTown_PokemonCenter_2F_Text_1A145C, 2
+ msgbox OldaleTown_PokemonCenter_2F_Text_1A145C, MSGBOX_NPC
end
OldaleTown_PokemonCenter_2F_Movement_1A4354:: @ 81A4354
face_down
- end_movement
+ step_end
OldaleTown_PokemonCenter_2F_Movement_1A4356:: @ 81A4356
face_right
- end_movement
+ step_end
OldaleTown_PokemonCenter_2F_Movement_1A4358:: @ 81A4358
walk_down
walk_down
- end_movement
+ step_end
OldaleTown_PokemonCenter_2F_Movement_1A435B:: @ 81A435B
walk_right
walk_up
walk_up
- end_movement
+ step_end
OldaleTown_PokemonCenter_2F_Movement_1A435F:: @ 81A435F
walk_up
- end_movement
+ step_end
OldaleTown_PokemonCenter_2F_Movement_1A4361:: @ 81A4361
face_left
- end_movement
+ step_end
gUnknown_081A4363:: @ 81A4363
lockall
@@ -613,7 +613,7 @@ SingleBattleColosseum_EventScript_1A4379:: @ 81A4379
end
DoubleBattleColosseum_EventScript_1A4383:: @ 81A4383
- fadescreen 1
+ fadescreen FADE_TO_BLACK
special sub_80C5568
waitstate
compare VAR_RESULT, 0
@@ -624,7 +624,7 @@ DoubleBattleColosseum_EventScript_1A4383:: @ 81A4383
end
DoubleBattleColosseum_EventScript_1A439E:: @ 81A439E
- fadescreen 1
+ fadescreen FADE_TO_BLACK
special sub_80C5568
waitstate
compare VAR_RESULT, 0
@@ -635,7 +635,7 @@ DoubleBattleColosseum_EventScript_1A439E:: @ 81A439E
end
DoubleBattleColosseum_EventScript_1A43B9:: @ 81A43B9
- fadescreen 1
+ fadescreen FADE_TO_BLACK
special sub_80C5568
waitstate
compare VAR_RESULT, 0
@@ -646,7 +646,7 @@ DoubleBattleColosseum_EventScript_1A43B9:: @ 81A43B9
end
DoubleBattleColosseum_EventScript_1A43D4:: @ 81A43D4
- fadescreen 1
+ fadescreen FADE_TO_BLACK
special sub_80C5568
waitstate
compare VAR_RESULT, 0
@@ -685,7 +685,7 @@ TradeCenter_EventScript_1A43FA:: @ 81A43FA
RecordCorner_EventScript_1A4418:: @ 81A4418
setvar VAR_0x8005, 0
- special sub_80B929C
+ special RecordMixingPlayerSpotTriggered
waitstate
compare VAR_TEMP_1, 0
goto_if_ne RecordCorner_EventScript_1A446C
@@ -693,7 +693,7 @@ RecordCorner_EventScript_1A4418:: @ 81A4418
RecordCorner_EventScript_1A442D:: @ 81A442D
setvar VAR_0x8005, 1
- special sub_80B929C
+ special RecordMixingPlayerSpotTriggered
waitstate
compare VAR_TEMP_1, 0
goto_if_ne RecordCorner_EventScript_1A446C
@@ -701,7 +701,7 @@ RecordCorner_EventScript_1A442D:: @ 81A442D
RecordCorner_EventScript_1A4442:: @ 81A4442
setvar VAR_0x8005, 2
- special sub_80B929C
+ special RecordMixingPlayerSpotTriggered
waitstate
compare VAR_TEMP_1, 0
goto_if_ne RecordCorner_EventScript_1A446C
@@ -709,7 +709,7 @@ RecordCorner_EventScript_1A4442:: @ 81A4442
RecordCorner_EventScript_1A4457:: @ 81A4457
setvar VAR_0x8005, 3
- special sub_80B929C
+ special RecordMixingPlayerSpotTriggered
waitstate
compare VAR_TEMP_1, 0
goto_if_ne RecordCorner_EventScript_1A446C
@@ -727,7 +727,7 @@ TradeRoom_ReadTrainerCard1:: @ 81A4479
message CableClub_LookAtTrainerCard1
waitmessage
waitbuttonpress
- fadescreen 1
+ fadescreen FADE_TO_BLACK
special sub_8083BDC
waitstate
end
@@ -736,7 +736,7 @@ TradeRoom_ReadTrainerCard2:: @ 81A4487
message CableClub_LookAtTrainerCard2
waitmessage
waitbuttonpress
- fadescreen 1
+ fadescreen FADE_TO_BLACK
special sub_8083BDC
waitstate
end
diff --git a/data/scripts/cave_hole.inc b/data/scripts/cave_hole.inc
new file mode 100644
index 000000000..0bc876575
--- /dev/null
+++ b/data/scripts/cave_hole.inc
@@ -0,0 +1,33 @@
+CaveHole_CheckFallDownHole:: @ 81C6BB5
+ map_script_2 VAR_ICE_STEP_COUNT, 0, EventScript_FallDownHole
+ .2byte 0
+
+CaveHole_FixCrackedGround:: @ 81C6BBF
+ copyvar VAR_ICE_STEP_COUNT, 1
+ end
+
+EventScript_FallDownHole:: @ 81C6BC5
+ lockall
+ delay 20
+ applymovement OBJ_EVENT_ID_PLAYER, Movement_SetInvisible
+ waitmovement 0
+ playse SE_RU_HYUU
+ delay 60
+ warphole MAP_UNDEFINED
+ waitstate
+ end
+
+EventScript_FallDownHoleMtPyre:: @ 81C6BDE
+ lockall
+ delay 20
+ applymovement OBJ_EVENT_ID_PLAYER, Movement_SetInvisible
+ waitmovement 0
+ playse SE_RU_HYUU
+ delay 60
+ special DoFallWarp
+ waitstate
+ end
+
+Movement_SetInvisible:: @ 81C6BF7
+ set_invisible
+ step_end
diff --git a/data/scripts/cave_of_origin.inc b/data/scripts/cave_of_origin.inc
new file mode 100644
index 000000000..0ec097533
--- /dev/null
+++ b/data/scripts/cave_of_origin.inc
@@ -0,0 +1,43 @@
+CaveOfOrigin_EventScript_LegendaryCry:: @ 81A04A0
+ lockall
+ waitse
+ playmoncry SPECIES_GROUDON_OR_KYOGRE, 2
+ waitmoncry
+ setvar VAR_TEMP_5, 1
+ releaseall
+ end
+
+CaveOfOrigin_EventScript_Shake1:: @ 81A04AF
+ lockall
+ setvar VAR_TEMP_1, 1
+ goto CaveOfOrigin_EventScript_Shake
+ end
+
+CaveOfOrigin_EventScript_Shake2:: @ 81A04BB
+ lockall
+ setvar VAR_TEMP_2, 1
+ goto CaveOfOrigin_EventScript_Shake
+ end
+
+@ Unused
+CaveOfOrigin_EventScript_Shake3:: @ 81A04C7
+ lockall
+ setvar VAR_TEMP_3, 1
+ goto CaveOfOrigin_EventScript_Shake
+ end
+
+CaveOfOrigin_EventScript_Shake:: @ 81A04D3
+ setvar VAR_0x8004, 1
+ setvar VAR_0x8005, 1
+ special ShakeCamera
+ waitstate
+ releaseall
+ end
+
+CaveOfOrigin_EventScript_DisableTriggers:: @ 81A04E3
+ setvar VAR_TEMP_1, 1
+ setvar VAR_TEMP_2, 1
+ setvar VAR_TEMP_3, 1
+ setvar VAR_TEMP_4, 1
+ setvar VAR_TEMP_5, 1
+ return
diff --git a/data/scripts/check_furniture.inc b/data/scripts/check_furniture.inc
new file mode 100644
index 000000000..66df09e02
--- /dev/null
+++ b/data/scripts/check_furniture.inc
@@ -0,0 +1,27 @@
+EventScript_PictureBookshelf:: @ 81A085B
+ msgbox Text_PictureBookshelf, MSGBOX_SIGN
+ end
+
+EventScript_Bookshelf:: @ 81A0864
+ msgbox Text_Bookshelf, MSGBOX_SIGN
+ end
+
+EventScript_PokemonCenterBookshelf:: @ 81A086D
+ msgbox Text_PokemonCenterBookshelf, MSGBOX_SIGN
+ end
+
+EventScript_Vase:: @ 81A0876
+ msgbox Text_Vase, MSGBOX_SIGN
+ end
+
+EventScript_EmptyTrashCan:: @ 81A087F
+ msgbox Text_EmptyTrashCan, MSGBOX_SIGN
+ end
+
+EventScript_ShopShelf:: @ 81A0888
+ msgbox Text_ShopShelf, MSGBOX_SIGN
+ end
+
+EventScript_Blueprint:: @ 81A0891
+ msgbox Text_Blueprint, MSGBOX_SIGN
+ end
diff --git a/data/scripts/contest_hall.inc b/data/scripts/contest_hall.inc
index 2a63d97f8..a99c33492 100644
--- a/data/scripts/contest_hall.inc
+++ b/data/scripts/contest_hall.inc
@@ -11,7 +11,7 @@ VerdanturfTown_ContestLobby_EventScript_1A4E92:: @ 81A4E92
goto_if_ne FallarborTown_ContestLobby_EventScript_1A4F4E
goto_if_set FLAG_TEMP_1, FallarborTown_ContestLobby_EventScript_1A4F8F
bufferstdstring 0, VAR_0x800B
- msgbox FallarborTown_ContestLobby_Text_1A5DFC, 4
+ msgbox FallarborTown_ContestLobby_Text_1A5DFC, MSGBOX_DEFAULT
checkitem ITEM_CONTEST_PASS, 1
compare VAR_RESULT, 0
goto_if_eq FallarborTown_ContestLobby_EventScript_1A4EE1
@@ -26,7 +26,7 @@ FallarborTown_ContestLobby_EventScript_1A4EDD:: @ 81A4EDD
FallarborTown_ContestLobby_EventScript_1A4EE1:: @ 81A4EE1
compare VAR_CONTEST_RANK, 0
goto_if_eq FallarborTown_ContestLobby_EventScript_1A4EF6
- msgbox FallarborTown_ContestLobby_Text_1A6340, 4
+ msgbox FallarborTown_ContestLobby_Text_1A6340, MSGBOX_DEFAULT
releaseall
end
@@ -34,33 +34,33 @@ FallarborTown_ContestLobby_EventScript_1A4EF6:: @ 81A4EF6
msgbox FallarborTown_ContestLobby_Text_1A64F4, MSGBOX_YESNO
compare VAR_RESULT, YES
goto_if_eq FallarborTown_ContestLobby_EventScript_1A4F13
- msgbox FallarborTown_ContestLobby_Text_1A65EA, 4
+ msgbox FallarborTown_ContestLobby_Text_1A65EA, MSGBOX_DEFAULT
releaseall
end
FallarborTown_ContestLobby_EventScript_1A4F13:: @ 81A4F13
goto_if_set FLAG_RECEIVED_CONTEST_PASS, FallarborTown_ContestLobby_EventScript_1A4F44
- msgbox FallarborTown_ContestLobby_Text_1A6583, 4
- giveitem_std ITEM_CONTEST_PASS
+ msgbox FallarborTown_ContestLobby_Text_1A6583, MSGBOX_DEFAULT
+ giveitem ITEM_CONTEST_PASS
setflag FLAG_RECEIVED_CONTEST_PASS
setflag FLAG_TEMP_1
- msgbox FallarborTown_ContestLobby_Text_1A5E98, 4
+ msgbox FallarborTown_ContestLobby_Text_1A5E98, MSGBOX_DEFAULT
goto FallarborTown_ContestLobby_EventScript_1A4F8F
end
FallarborTown_ContestLobby_EventScript_1A4F44:: @ 81A4F44
- msgbox FallarborTown_ContestLobby_Text_1A6590, 4
+ msgbox FallarborTown_ContestLobby_Text_1A6590, MSGBOX_DEFAULT
releaseall
end
FallarborTown_ContestLobby_EventScript_1A4F4E:: @ 81A4F4E
- msgbox FallarborTown_ContestLobby_Text_1A685A, 4
+ msgbox FallarborTown_ContestLobby_Text_1A685A, MSGBOX_DEFAULT
switch VAR_CONTEST_PRIZE_PICKUP
case 4, FallarborTown_ContestLobby_EventScript_1A4F67
end
FallarborTown_ContestLobby_EventScript_1A4F67:: @ 81A4F67
- giveitem_std ITEM_LUXURY_BALL
+ giveitem ITEM_LUXURY_BALL
compare VAR_RESULT, 0
goto_if_eq FallarborTown_ContestLobby_EventScript_1A4F86
setvar VAR_CONTEST_PRIZE_PICKUP, 0
@@ -69,7 +69,7 @@ FallarborTown_ContestLobby_EventScript_1A4F67:: @ 81A4F67
end
FallarborTown_ContestLobby_EventScript_1A4F86:: @ 81A4F86
- msgbox FallarborTown_ContestLobby_Text_1A68C6, 2
+ msgbox FallarborTown_ContestLobby_Text_1A68C6, MSGBOX_NPC
end
FallarborTown_ContestLobby_EventScript_1A4F8F:: @ 81A4F8F
@@ -96,27 +96,27 @@ FallarborTown_ContestLobby_EventScript_1A4FCC:: @ 81A4FCC
end
FallarborTown_ContestLobby_EventScript_1A5014:: @ 81A5014
- msgbox FallarborTown_ContestLobby_Text_1A5E98, 4
+ msgbox FallarborTown_ContestLobby_Text_1A5E98, MSGBOX_DEFAULT
goto FallarborTown_ContestLobby_EventScript_1A4FCC
end
FallarborTown_ContestLobby_EventScript_1A5022:: @ 81A5022
- msgbox FallarborTown_ContestLobby_Text_1A609B, 4
+ msgbox FallarborTown_ContestLobby_Text_1A609B, MSGBOX_DEFAULT
goto FallarborTown_ContestLobby_EventScript_1A4FCC
end
FallarborTown_ContestLobby_EventScript_1A5030:: @ 81A5030
- msgbox FallarborTown_ContestLobby_Text_1A613F, 4
+ msgbox FallarborTown_ContestLobby_Text_1A613F, MSGBOX_DEFAULT
goto FallarborTown_ContestLobby_EventScript_1A4FCC
end
FallarborTown_ContestLobby_EventScript_1A503E:: @ 81A503E
- msgbox FallarborTown_ContestLobby_Text_188559, 4
+ msgbox FallarborTown_ContestLobby_Text_188559, MSGBOX_DEFAULT
release
end
FallarborTown_ContestLobby_EventScript_1A5048:: @ 81A5048
- msgbox FallarborTown_ContestLobby_Text_1A6319, 4
+ msgbox FallarborTown_ContestLobby_Text_1A6319, MSGBOX_DEFAULT
choosecontestmon
compare VAR_0x8004, 255
goto_if_eq FallarborTown_ContestLobby_EventScript_1A5097
@@ -145,7 +145,7 @@ FallarborTown_ContestLobby_EventScript_1A5097:: @ 81A5097
end
FallarborTown_ContestLobby_EventScript_1A50C8:: @ 81A50C8
- msgbox FallarborTown_ContestLobby_Text_1A664A, 4
+ msgbox FallarborTown_ContestLobby_Text_1A664A, MSGBOX_DEFAULT
goto FallarborTown_ContestLobby_EventScript_1A5048
release
end
@@ -165,19 +165,19 @@ FallarborTown_ContestLobby_EventScript_1A50FB:: @ 81A50FB
end
FallarborTown_ContestLobby_EventScript_1A511F:: @ 81A511F
- msgbox FallarborTown_ContestLobby_Text_1A669F, 4
+ msgbox FallarborTown_ContestLobby_Text_1A669F, MSGBOX_DEFAULT
goto FallarborTown_ContestLobby_EventScript_1A5048
release
end
FallarborTown_ContestLobby_EventScript_1A512E:: @ 81A512E
- msgbox FallarborTown_ContestLobby_Text_1A66DC, 4
+ msgbox FallarborTown_ContestLobby_Text_1A66DC, MSGBOX_DEFAULT
goto FallarborTown_ContestLobby_EventScript_1A5048
release
end
FallarborTown_ContestLobby_EventScript_1A513D:: @ 81A513D
- msgbox FallarborTown_ContestLobby_Text_1A67C1, 4
+ msgbox FallarborTown_ContestLobby_Text_1A67C1, MSGBOX_DEFAULT
closemessage
releaseall
setvar VAR_LINK_CONTEST_ROOM_STATE, 1
@@ -270,7 +270,7 @@ LinkContestRoom1_EventScript_1A5245:: @ 81A5245
LinkContestRoom1_EventScript_1A525F:: @ 81A525F
compare VAR_CONTEST_LOCATION, 5
goto_if_eq LinkContestRoom1_EventScript_1A5273
- msgbox LinkContestRoom1_Text_1A68F0, 3
+ msgbox LinkContestRoom1_Text_1A68F0, MSGBOX_SIGN
return
LinkContestRoom1_EventScript_1A5273:: @ 81A5273
@@ -385,7 +385,7 @@ LinkContestRoom1_EventScript_1A5377:: @ 81A5377
LinkContestRoom1_EventScript_1A53B3:: @ 81A53B3
compare VAR_CONTEST_LOCATION, 5
goto_if_eq LinkContestRoom1_EventScript_1A53C7
- msgbox LinkContestRoom1_Text_1A6A1F, 4
+ msgbox LinkContestRoom1_Text_1A6A1F, MSGBOX_DEFAULT
return
LinkContestRoom1_EventScript_1A53C7:: @ 81A53C7
@@ -782,7 +782,7 @@ LinkContestRoom1_EventScript_1A58EE:: @ 81A58EE
LinkContestRoom1_EventScript_1A5930:: @ 81A5930
compare VAR_CONTEST_LOCATION, 5
goto_if_eq LinkContestRoom1_EventScript_1A5944
- msgbox LinkContestRoom1_Text_1A6AF5, 3
+ msgbox LinkContestRoom1_Text_1A6AF5, MSGBOX_SIGN
return
LinkContestRoom1_EventScript_1A5944:: @ 81A5944
@@ -809,7 +809,7 @@ LinkContestRoom1_EventScript_1A594A:: @ 81A594A
LinkContestRoom1_EventScript_1A5984:: @ 81A5984
compare VAR_CONTEST_LOCATION, 5
goto_if_eq LinkContestRoom1_EventScript_1A5998
- msgbox LinkContestRoom1_Text_1A6C06, 4
+ msgbox LinkContestRoom1_Text_1A6C06, MSGBOX_DEFAULT
return
LinkContestRoom1_EventScript_1A5998:: @ 81A5998
@@ -821,7 +821,7 @@ LinkContestRoom1_EventScript_1A5998:: @ 81A5998
LinkContestRoom1_EventScript_1A59A2:: @ 81A59A2
compare VAR_CONTEST_LOCATION, 5
goto_if_eq LinkContestRoom1_EventScript_1A59B6
- msgbox LinkContestRoom1_Text_1A6C21, 4
+ msgbox LinkContestRoom1_Text_1A6C21, MSGBOX_DEFAULT
return
LinkContestRoom1_EventScript_1A59B6:: @ 81A59B6
@@ -833,7 +833,7 @@ LinkContestRoom1_EventScript_1A59B6:: @ 81A59B6
LinkContestRoom1_EventScript_1A59C0:: @ 81A59C0
compare VAR_CONTEST_LOCATION, 5
goto_if_eq LinkContestRoom1_EventScript_1A59D4
- msgbox LinkContestRoom1_Text_1A6C9D, 4
+ msgbox LinkContestRoom1_Text_1A6C9D, MSGBOX_DEFAULT
return
LinkContestRoom1_EventScript_1A59D4:: @ 81A59D4
@@ -845,7 +845,7 @@ LinkContestRoom1_EventScript_1A59D4:: @ 81A59D4
LinkContestRoom1_EventScript_1A59DE:: @ 81A59DE
compare VAR_CONTEST_LOCATION, 5
goto_if_eq LinkContestRoom1_EventScript_1A59F2
- msgbox LinkContestRoom1_Text_1A6D16, 4
+ msgbox LinkContestRoom1_Text_1A6D16, MSGBOX_DEFAULT
return
LinkContestRoom1_EventScript_1A59F2:: @ 81A59F2
@@ -895,7 +895,7 @@ LinkContestRoom1_EventScript_1A5A49:: @ 81A5A49
LinkContestRoom1_EventScript_1A5A75:: @ 81A5A75
compare VAR_CONTEST_LOCATION, 5
goto_if_eq LinkContestRoom1_EventScript_1A5A89
- msgbox LinkContestRoom1_Text_1A6D3C, 4
+ msgbox LinkContestRoom1_Text_1A6D3C, MSGBOX_DEFAULT
return
LinkContestRoom1_EventScript_1A5A89:: @ 81A5A89
@@ -995,7 +995,7 @@ LinkContestRoom1_EventScript_1A5BAB:: @ 81A5BAB
goto_if_eq LinkContestRoom1_EventScript_1A5C4C
call LinkContestRoom1_EventScript_1A5C12
goto_if_set FLAG_TEMP_2, LinkContestRoom1_EventScript_1A5BF6
- msgbox LinkContestRoom1_Text_1A6DC5, 3
+ msgbox LinkContestRoom1_Text_1A6DC5, MSGBOX_SIGN
waitmessage
call LinkContestRoom1_EventScript_1A5C7F
call LinkContestRoom1_EventScript_1A5CE5
@@ -1010,7 +1010,7 @@ LinkContestRoom1_EventScript_1A5BAB:: @ 81A5BAB
LinkContestRoom1_EventScript_1A5BF6:: @ 81A5BF6
incrementgamestat GAME_STAT_WON_CONTEST
- msgbox LinkContestRoom1_Text_1A6DF1, 3
+ msgbox LinkContestRoom1_Text_1A6DF1, MSGBOX_SIGN
delay 90
special sub_80C4CF8
compare VAR_0x8004, 1
@@ -1110,7 +1110,7 @@ LinkContestRoom1_EventScript_1A5CE5:: @ 81A5CE5
special ScrSpecial_GetContestWinnerIdx
compare VAR_0x8005, 3
goto_if_eq LinkContestRoom1_EventScript_1A5CFC
- msgbox LinkContestRoom1_Text_1A6DF1, 3
+ msgbox LinkContestRoom1_Text_1A6DF1, MSGBOX_SIGN
return
LinkContestRoom1_EventScript_1A5CFC:: @ 81A5CFC
@@ -1122,19 +1122,19 @@ LinkContestRoom1_EventScript_1A5CFC:: @ 81A5CFC
goto_if_eq LinkContestRoom1_EventScript_1A5D5B
compare VAR_CONTEST_RANK, 3
goto_if_eq LinkContestRoom1_EventScript_1A5D3B
- msgbox LinkContestRoom1_Text_1A6DF1, 3
+ msgbox LinkContestRoom1_Text_1A6DF1, MSGBOX_SIGN
return
LinkContestRoom1_EventScript_1A5D2D:: @ 81A5D2D
- msgbox LinkContestRoom1_Text_1A6E1F, 3
+ msgbox LinkContestRoom1_Text_1A6E1F, MSGBOX_SIGN
setvar VAR_CONTEST_PRIZE_PICKUP, 4
return
LinkContestRoom1_EventScript_1A5D3B:: @ 81A5D3B
- giveitem_std ITEM_LUXURY_BALL
+ giveitem ITEM_LUXURY_BALL
compare VAR_RESULT, 0
goto_if_eq LinkContestRoom1_EventScript_1A5D2D
- msgbox LinkContestRoom1_Text_1A6DF1, 3
+ msgbox LinkContestRoom1_Text_1A6DF1, MSGBOX_SIGN
return
LinkContestRoom1_EventScript_1A5D5B:: @ 81A5D5B
@@ -1142,76 +1142,76 @@ LinkContestRoom1_EventScript_1A5D5B:: @ 81A5D5B
incrementgamestat GAME_STAT_RECEIVED_RIBBONS
setflag FLAG_SYS_RIBBON_GET
lockall
- msgbox LinkContestRoom1_Text_1A6D6A, 4
+ msgbox LinkContestRoom1_Text_1A6D6A, MSGBOX_DEFAULT
playfanfare MUS_FANFA4
- msgbox LinkContestRoom1_Text_1A6D96, 4
+ msgbox LinkContestRoom1_Text_1A6D96, MSGBOX_DEFAULT
waitfanfare
special ScrSpecial_GetContestWinnerNick
- msgbox LinkContestRoom1_Text_1A6DAC, 4
+ msgbox LinkContestRoom1_Text_1A6DAC, MSGBOX_DEFAULT
releaseall
return
LinkContestRoom1_Movement_1A5D85:: @ 81A5D85
walk_down
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5D87:: @ 81A5D87
lock_facing_direction
walk_up
unlock_facing_direction
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5D8B:: @ 81A5D8B
walk_in_place_fastest_right
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5D8D:: @ 81A5D8D
emote_heart
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5D8F:: @ 81A5D8F
walk_in_place_fastest_down
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5D91:: @ 81A5D91
walk_left
walk_left
walk_in_place_fastest_down
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5D95:: @ 81A5D95
walk_right
walk_right
walk_in_place_fastest_down
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5D99:: @ 81A5D99
walk_up
walk_in_place_fastest_down
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5D9C:: @ 81A5D9C
delay_16
delay_16
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5D9F:: @ 81A5D9F
walk_in_place_fastest_right
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5DA1:: @ 81A5DA1
walk_in_place_fastest_left
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5DA3:: @ 81A5DA3
walk_in_place_fastest_down
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5DA5:: @ 81A5DA5
walk_left
walk_left
walk_up
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5DA9:: @ 81A5DA9
walk_left
@@ -1219,54 +1219,54 @@ LinkContestRoom1_Movement_1A5DA9:: @ 81A5DA9
walk_left
walk_left
walk_up
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5DAF:: @ 81A5DAF
face_left
delay_16
face_original_direction
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5DB3:: @ 81A5DB3
face_up
delay_16
face_original_direction
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5DB7:: @ 81A5DB7
face_right
delay_16
face_original_direction
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5DBB:: @ 81A5DBB
face_down
delay_16
face_original_direction
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5DBF:: @ 81A5DBF
face_up
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5DC1:: @ 81A5DC1
face_up
delay_16
walk_in_place_fastest_right
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5DC5:: @ 81A5DC5
walk_in_place_fastest_left
delay_16
delay_16
walk_in_place_fastest_down
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5DCA:: @ 81A5DCA
delay_16
delay_16
walk_in_place_fastest_down
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5DCE:: @ 81A5DCE
walk_up
@@ -1274,7 +1274,7 @@ LinkContestRoom1_Movement_1A5DCE:: @ 81A5DCE
walk_right
walk_right
walk_in_place_fastest_up
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5DD4:: @ 81A5DD4
walk_fast_left
@@ -1282,31 +1282,31 @@ LinkContestRoom1_Movement_1A5DD4:: @ 81A5DD4
walk_fast_left
walk_fast_down
walk_in_place_fastest_up
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5DDA:: @ 81A5DDA
walk_up
walk_right
walk_in_place_fastest_up
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5DDE:: @ 81A5DDE
walk_fast_left
walk_fast_down
walk_in_place_fastest_up
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5DE2:: @ 81A5DE2
walk_up
walk_left
walk_in_place_fastest_up
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5DE6:: @ 81A5DE6
walk_fast_right
walk_fast_down
walk_in_place_fastest_up
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5DEA:: @ 81A5DEA
walk_up
@@ -1314,7 +1314,7 @@ LinkContestRoom1_Movement_1A5DEA:: @ 81A5DEA
walk_left
walk_left
walk_in_place_fastest_up
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5DF0:: @ 81A5DF0
walk_fast_right
@@ -1322,14 +1322,14 @@ LinkContestRoom1_Movement_1A5DF0:: @ 81A5DF0
walk_fast_right
walk_fast_down
walk_in_place_fastest_up
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5DF6:: @ 81A5DF6
walk_right
walk_right
walk_up
- end_movement
+ step_end
LinkContestRoom1_Movement_1A5DFA:: @ 81A5DFA
walk_up
- end_movement
+ step_end
diff --git a/data/scripts/day_care.inc b/data/scripts/day_care.inc
index 1a7e56cfd..2eb32cc71 100644
--- a/data/scripts/day_care.inc
+++ b/data/scripts/day_care.inc
@@ -9,7 +9,7 @@ Route117_EventScript_1B222D:: @ 81B222D
goto_if_eq Route117_EventScript_1B22E7
compare VAR_RESULT, 3
goto_if_eq Route117_EventScript_1B22FE
- msgbox Route117_Text_1B25CB, 4
+ msgbox Route117_Text_1B25CB, MSGBOX_DEFAULT
release
end
@@ -20,7 +20,7 @@ Route117_EventScript_1B2262:: @ 81B2262
msgbox Route117_Text_1B28C4, MSGBOX_YESNO
compare VAR_RESULT, YES
goto_if_eq Route117_EventScript_1B2298
- msgbox Route117_Text_1B2745, 4
+ msgbox Route117_Text_1B2745, MSGBOX_DEFAULT
clearflag FLAG_PENDING_DAYCARE_EGG
special RejectEggFromDayCare
release
@@ -30,7 +30,7 @@ Route117_EventScript_1B2298:: @ 81B2298
specialvar VAR_RESULT, CalculatePlayerPartyCount
compare VAR_RESULT, 6
goto_if_ne Route117_EventScript_1B22B2
- msgbox Route117_Text_1B2766, 4
+ msgbox Route117_Text_1B2766, MSGBOX_DEFAULT
release
end
@@ -40,7 +40,7 @@ Route117_EventScript_1B22B2:: @ 81B22B2
waitfanfare
waitmessage
waitbuttonpress
- msgbox Route117_Text_1B27CD, 4
+ msgbox Route117_Text_1B27CD, MSGBOX_DEFAULT
special GiveEggFromDaycare
clearflag FLAG_PENDING_DAYCARE_EGG
release
@@ -53,12 +53,12 @@ Route117_EventScript_1B22CD:: @ 81B22CD
return
Route117_EventScript_1B22DE:: @ 81B22DE
- msgbox Route117_Text_1B27E3, 4
+ msgbox Route117_Text_1B27E3, MSGBOX_DEFAULT
return
Route117_EventScript_1B22E7:: @ 81B22E7
special GetDaycareMonNicknames
- msgbox Route117_Text_1B2710, 4
+ msgbox Route117_Text_1B2710, MSGBOX_DEFAULT
setvar VAR_0x8004, 0
call Route117_EventScript_1B22CD
release
@@ -66,7 +66,7 @@ Route117_EventScript_1B22E7:: @ 81B22E7
Route117_EventScript_1B22FE:: @ 81B22FE
special GetDaycareMonNicknames
- msgbox Route117_Text_1B2897, 4
+ msgbox Route117_Text_1B2897, MSGBOX_DEFAULT
special SetDaycareCompatibilityString
special ShowFieldMessageStringVar4
waitmessage
@@ -91,7 +91,7 @@ Route117_PokemonDayCare_EventScript_1B2327:: @ 81B2327
msgbox Route117_PokemonDayCare_Text_1B28F2, MSGBOX_YESNO
compare VAR_RESULT, YES
goto_if_eq Route117_PokemonDayCare_EventScript_1B236C
- msgbox Route117_PokemonDayCare_Text_1B2A14, 4
+ msgbox Route117_PokemonDayCare_Text_1B2A14, MSGBOX_DEFAULT
release
end
@@ -99,8 +99,8 @@ Route117_PokemonDayCare_EventScript_1B236C:: @ 81B236C
specialvar VAR_RESULT, GetNumValidDaycarePartyMons
compare VAR_RESULT, 1
goto_if_eq Route117_PokemonDayCare_EventScript_1B23F3
- msgbox Route117_PokemonDayCare_Text_1B2947, 4
- fadescreen 1
+ msgbox Route117_PokemonDayCare_Text_1B2947, MSGBOX_DEFAULT
+ fadescreen FADE_TO_BLACK
special ChooseSendDaycareMon
waitstate
compare VAR_0x8004, 255
@@ -111,7 +111,7 @@ Route117_PokemonDayCare_EventScript_1B236C:: @ 81B236C
specialvar VAR_0x8005, GetSelectedDaycareMonNickname
waitse
playmoncry VAR_0x8005, 0
- msgbox Route117_PokemonDayCare_Text_1B296E, 4
+ msgbox Route117_PokemonDayCare_Text_1B296E, MSGBOX_DEFAULT
waitmoncry
special StoreSelectedPokemonInDaycare
incrementgamestat GAME_STAT_USED_DAYCARE
@@ -122,7 +122,7 @@ Route117_PokemonDayCare_EventScript_1B236C:: @ 81B236C
end
Route117_PokemonDayCare_EventScript_1B23D0:: @ 81B23D0
- msgbox Route117_PokemonDayCare_Text_1B2A76, 4
+ msgbox Route117_PokemonDayCare_Text_1B2A76, MSGBOX_DEFAULT
release
end
@@ -134,22 +134,22 @@ Route117_PokemonDayCare_EventScript_1B23DA:: @ 81B23DA
end
Route117_PokemonDayCare_EventScript_1B23F3:: @ 81B23F3
- msgbox Route117_PokemonDayCare_Text_1B2BBB, 4
+ msgbox Route117_PokemonDayCare_Text_1B2BBB, MSGBOX_DEFAULT
release
end
Route117_PokemonDayCare_EventScript_1B23FD:: @ 81B23FD
- msgbox Route117_PokemonDayCare_Text_1B2C17, 4
+ msgbox Route117_PokemonDayCare_Text_1B2C17, MSGBOX_DEFAULT
release
end
Route117_PokemonDayCare_EventScript_1B2407:: @ 81B2407
- msgbox Route117_PokemonDayCare_Text_1B29F4, 4
+ msgbox Route117_PokemonDayCare_Text_1B29F4, MSGBOX_DEFAULT
release
end
Route117_PokemonDayCare_EventScript_1B2411:: @ 81B2411
- msgbox Route117_PokemonDayCare_Text_1B2ACC, 4
+ msgbox Route117_PokemonDayCare_Text_1B2ACC, MSGBOX_DEFAULT
return
Route117_PokemonDayCare_EventScript_1B241A:: @ 81B241A
@@ -159,7 +159,7 @@ Route117_PokemonDayCare_EventScript_1B241A:: @ 81B241A
return
Route117_PokemonDayCare_EventScript_1B242B:: @ 81B242B
- msgbox Route117_PokemonDayCare_Text_1B2A88, 4
+ msgbox Route117_PokemonDayCare_Text_1B2A88, MSGBOX_DEFAULT
setvar VAR_0x8004, 0
call Route117_PokemonDayCare_EventScript_1B241A
msgbox Route117_PokemonDayCare_Text_1B29AD, MSGBOX_YESNO
@@ -199,7 +199,7 @@ Route117_PokemonDayCare_EventScript_1B24C4:: @ 81B24C4
specialvar VAR_RESULT, HasEnoughMoneyFor
compare VAR_RESULT, 1
goto_if_eq Route117_PokemonDayCare_EventScript_1B24DE
- msgbox Route117_PokemonDayCare_Text_1B2A30, 4
+ msgbox Route117_PokemonDayCare_Text_1B2A30, MSGBOX_DEFAULT
release
end
@@ -209,10 +209,10 @@ Route117_PokemonDayCare_EventScript_1B24DE:: @ 81B24DE
specialvar VAR_RESULT, TakePokemonFromDaycare
special PayMoneyFor
playse SE_REGI
- msgbox Route117_PokemonDayCare_Text_1B2B75, 4
+ msgbox Route117_PokemonDayCare_Text_1B2B75, MSGBOX_DEFAULT
waitse
playmoncry VAR_RESULT, 0
- msgbox Route117_PokemonDayCare_Text_1B2B93, 4
+ msgbox Route117_PokemonDayCare_Text_1B2B93, MSGBOX_DEFAULT
waitmoncry
specialvar VAR_RESULT, GetDaycareState
compare VAR_RESULT, 2
@@ -228,7 +228,7 @@ Route117_PokemonDayCare_EventScript_1B2520:: @ 81B2520
end
Route117_PokemonDayCare_EventScript_1B2539:: @ 81B2539
- msgbox Route117_PokemonDayCare_Text_1B2AEF, 4
+ msgbox Route117_PokemonDayCare_Text_1B2AEF, MSGBOX_DEFAULT
release
end
@@ -252,13 +252,13 @@ Route117_PokemonDayCare_Movement_1B2543:: @ 81B2543
face_down
set_visible
walk_slow_down
- end_movement
+ step_end
@ 81B2557
end
Route117_PokemonDayCare_EventScript_1B2558:: @ 81B2558
- msgbox Route117_PokemonDayCare_Text_1B2A88, 4
+ msgbox Route117_PokemonDayCare_Text_1B2A88, MSGBOX_DEFAULT
setvar VAR_0x8004, 0
call Route117_PokemonDayCare_EventScript_1B241A
setvar VAR_0x8004, 1
@@ -266,7 +266,7 @@ Route117_PokemonDayCare_EventScript_1B2558:: @ 81B2558
msgbox Route117_PokemonDayCare_Text_1B2BF6, MSGBOX_YESNO
compare VAR_RESULT, YES
goto_if_eq Route117_PokemonDayCare_EventScript_1B2469
- msgbox Route117_PokemonDayCare_Text_1B2A76, 4
+ msgbox Route117_PokemonDayCare_Text_1B2A76, MSGBOX_DEFAULT
release
end
@@ -277,14 +277,14 @@ Route117_PokemonDayCare_EventScript_1B2558:: @ 81B2558
goto_if_eq Route117_PokemonDayCare_EventScript_1B23D0
copyvar VAR_0x8004, VAR_RESULT
specialvar VAR_RESULT, TakePokemonFromDaycare
- msgbox Route117_PokemonDayCare_Text_1B2B75, 4
- msgbox Route117_PokemonDayCare_Text_1B2A76, 4
+ msgbox Route117_PokemonDayCare_Text_1B2B75, MSGBOX_DEFAULT
+ msgbox Route117_PokemonDayCare_Text_1B2A76, MSGBOX_DEFAULT
release
end
S_EggHatch:: @ 81B25BC
lockall
- msgbox UnknownString_81B2C68, 4
+ msgbox UnknownString_81B2C68, MSGBOX_DEFAULT
special EggHatch
waitstate
releaseall
diff --git a/data/scripts/debug.inc b/data/scripts/debug.inc
index c11e78a8d..c683c90e0 100644
--- a/data/scripts/debug.inc
+++ b/data/scripts/debug.inc
@@ -2,14 +2,14 @@
DebugScript_081C1CFE:: @ 81C1CFE
setflag FLAG_SYS_GAME_CLEAR
- call EverGrandeCity_HallOfFame_EventScript_19FC13
+ call EverGrandeCity_HallOfFame_EventScript_SetGameClearFlags
end
DebugScript_081C1D07:: @ 81C1D07
checkitem ITEM_COIN_CASE, 1
compare VAR_RESULT, 1
goto_if_eq DebugScript_081C1D1D
- giveitem ITEM_COIN_CASE, 1
+ additem ITEM_COIN_CASE, 1
end
DebugScript_081C1D1D:: @ 81C1D1D
@@ -26,7 +26,7 @@ DebugScript_081C1D24:: @ 81C1D24
end
DebugScript_081C1D2A:: @ 81C1D2A
- giveitem ITEM_SS_TICKET, 1
+ additem ITEM_SS_TICKET, 1
goto DebugScript_081C1CFE
DebugScript_081C1D34:: @ 81C1D34
@@ -43,411 +43,411 @@ DebugScript_081C1D45:: @ 81C1D45
end
DebugScript_081C1D46:: @ 81C1D46
- giveitem ITEM_POTION, 99
- giveitem ITEM_ANTIDOTE, 99
- giveitem ITEM_BURN_HEAL, 99
- giveitem ITEM_ICE_HEAL, 99
- giveitem ITEM_AWAKENING, 99
- giveitem ITEM_PARALYZE_HEAL, 99
- giveitem ITEM_FULL_RESTORE, 99
- giveitem ITEM_MAX_POTION, 99
- giveitem ITEM_HYPER_POTION, 99
- giveitem ITEM_SUPER_POTION, 99
- giveitem ITEM_FULL_HEAL, 99
- giveitem ITEM_REVIVE, 99
- giveitem ITEM_MAX_REVIVE, 99
- giveitem ITEM_FRESH_WATER, 99
- giveitem ITEM_SODA_POP, 99
- giveitem ITEM_LEMONADE, 99
- giveitem ITEM_MOOMOO_MILK, 99
- giveitem ITEM_ENERGY_POWDER, 99
- giveitem ITEM_ENERGY_ROOT, 99
- giveitem ITEM_HEAL_POWDER, 99
- giveitem ITEM_ORANGE_MAIL, 92
- giveitem ITEM_RETRO_MAIL, 94
- giveitem ITEM_POTION, 89
- giveitem ITEM_MASTER_BALL, 99
- giveitem ITEM_ULTRA_BALL, 99
- giveitem ITEM_GREAT_BALL, 99
- giveitem ITEM_POKE_BALL, 99
- giveitem ITEM_NET_BALL, 99
- giveitem ITEM_DIVE_BALL, 99
- giveitem ITEM_NEST_BALL, 99
- giveitem ITEM_REPEAT_BALL, 99
- giveitem ITEM_TIMER_BALL, 99
- giveitem ITEM_LUXURY_BALL, 99
- giveitem ITEM_PREMIER_BALL, 99
- giveitem ITEM_MASTER_BALL, 99
- giveitem ITEM_MASTER_BALL, 99
- giveitem ITEM_MASTER_BALL, 99
- giveitem ITEM_MASTER_BALL, 99
- giveitem ITEM_MASTER_BALL, 99
- giveitem ITEM_MASTER_BALL, 99
- giveitem ITEM_MASTER_BALL, 99
- giveitem ITEM_MASTER_BALL, 99
- giveitem ITEM_MASTER_BALL, 99
- giveitem ITEM_GREAT_BALL, 79
- giveitem ITEM_ULTRA_BALL, 84
- giveitem ITEM_POKE_BALL, 89
- giveitem ITEM_MASTER_BALL, 74
- giveitem ITEM_TM01_FOCUS_PUNCH, 99
- giveitem ITEM_TM02_DRAGON_CLAW, 99
- giveitem ITEM_TM03_WATER_PULSE, 99
- giveitem ITEM_TM04_CALM_MIND, 99
- giveitem ITEM_TM05_ROAR, 99
- giveitem ITEM_TM06_TOXIC, 99
- giveitem ITEM_TM07_HAIL, 99
- giveitem ITEM_TM08_BULK_UP, 99
- giveitem ITEM_TM09_BULLET_SEED, 99
- giveitem ITEM_TM10_HIDDEN_POWER, 99
- giveitem ITEM_TM11_SUNNY_DAY, 99
- giveitem ITEM_TM12_TAUNT, 99
- giveitem ITEM_TM13_ICE_BEAM, 99
- giveitem ITEM_TM14_BLIZZARD, 99
- giveitem ITEM_TM15_HYPER_BEAM, 99
- giveitem ITEM_TM16_LIGHT_SCREEN, 99
- giveitem ITEM_TM17_PROTECT, 99
- giveitem ITEM_TM18_RAIN_DANCE, 99
- giveitem ITEM_TM19_GIGA_DRAIN, 99
- giveitem ITEM_TM20_SAFEGUARD, 99
- giveitem ITEM_TM21_FRUSTRATION, 99
- giveitem ITEM_TM22_SOLARBEAM, 99
- giveitem ITEM_TM23_IRON_TAIL, 99
- giveitem ITEM_TM24_THUNDERBOLT, 99
- giveitem ITEM_TM25_THUNDER, 99
- giveitem ITEM_TM26_EARTHQUAKE, 99
- giveitem ITEM_TM27_RETURN, 99
- giveitem ITEM_TM28_DIG, 99
- giveitem ITEM_TM29_PSYCHIC, 99
- giveitem ITEM_TM30_SHADOW_BALL, 99
- giveitem ITEM_TM31_BRICK_BREAK, 99
- giveitem ITEM_TM32_DOUBLE_TEAM, 99
- giveitem ITEM_TM33_REFLECT, 99
- giveitem ITEM_TM34_SHOCK_WAVE, 99
- giveitem ITEM_TM35_FLAMETHROWER, 99
- giveitem ITEM_TM36_SLUDGE_BOMB, 99
- giveitem ITEM_TM37_SANDSTORM, 99
- giveitem ITEM_TM38_FIRE_BLAST, 99
- giveitem ITEM_TM39_ROCK_TOMB, 99
- giveitem ITEM_TM40_AERIAL_ACE, 99
- giveitem ITEM_TM41_TORMENT, 99
- giveitem ITEM_TM42_FACADE, 99
- giveitem ITEM_TM43_SECRET_POWER, 99
- giveitem ITEM_TM44_REST, 99
- giveitem ITEM_TM45_ATTRACT, 99
- giveitem ITEM_TM46_THIEF, 99
- giveitem ITEM_TM47_STEEL_WING, 99
- giveitem ITEM_TM48_SKILL_SWAP, 99
- giveitem ITEM_TM49_SNATCH, 99
- giveitem ITEM_TM50_OVERHEAT, 99
- giveitem ITEM_CHERI_BERRY, 200
- giveitem ITEM_CHERI_BERRY, 200
- giveitem ITEM_CHERI_BERRY, 200
- giveitem ITEM_CHERI_BERRY, 200
- giveitem ITEM_CHERI_BERRY, 199
- giveitem ITEM_CHESTO_BERRY, 200
- giveitem ITEM_CHESTO_BERRY, 200
- giveitem ITEM_CHESTO_BERRY, 200
- giveitem ITEM_CHESTO_BERRY, 200
- giveitem ITEM_CHESTO_BERRY, 199
- giveitem ITEM_PECHA_BERRY, 200
- giveitem ITEM_PECHA_BERRY, 200
- giveitem ITEM_PECHA_BERRY, 200
- giveitem ITEM_PECHA_BERRY, 200
- giveitem ITEM_PECHA_BERRY, 199
- giveitem ITEM_RAWST_BERRY, 200
- giveitem ITEM_RAWST_BERRY, 200
- giveitem ITEM_RAWST_BERRY, 200
- giveitem ITEM_RAWST_BERRY, 200
- giveitem ITEM_RAWST_BERRY, 199
- giveitem ITEM_ASPEAR_BERRY, 200
- giveitem ITEM_ASPEAR_BERRY, 200
- giveitem ITEM_ASPEAR_BERRY, 200
- giveitem ITEM_ASPEAR_BERRY, 200
- giveitem ITEM_ASPEAR_BERRY, 199
- giveitem ITEM_LEPPA_BERRY, 200
- giveitem ITEM_LEPPA_BERRY, 200
- giveitem ITEM_LEPPA_BERRY, 200
- giveitem ITEM_LEPPA_BERRY, 200
- giveitem ITEM_LEPPA_BERRY, 199
- giveitem ITEM_ORAN_BERRY, 200
- giveitem ITEM_ORAN_BERRY, 200
- giveitem ITEM_ORAN_BERRY, 200
- giveitem ITEM_ORAN_BERRY, 200
- giveitem ITEM_ORAN_BERRY, 199
- giveitem ITEM_PERSIM_BERRY, 200
- giveitem ITEM_PERSIM_BERRY, 200
- giveitem ITEM_PERSIM_BERRY, 200
- giveitem ITEM_PERSIM_BERRY, 200
- giveitem ITEM_PERSIM_BERRY, 199
- giveitem ITEM_LUM_BERRY, 200
- giveitem ITEM_LUM_BERRY, 200
- giveitem ITEM_LUM_BERRY, 200
- giveitem ITEM_LUM_BERRY, 200
- giveitem ITEM_LUM_BERRY, 199
- giveitem ITEM_SITRUS_BERRY, 200
- giveitem ITEM_SITRUS_BERRY, 200
- giveitem ITEM_SITRUS_BERRY, 200
- giveitem ITEM_SITRUS_BERRY, 200
- giveitem ITEM_SITRUS_BERRY, 199
- giveitem ITEM_FIGY_BERRY, 200
- giveitem ITEM_FIGY_BERRY, 200
- giveitem ITEM_FIGY_BERRY, 200
- giveitem ITEM_FIGY_BERRY, 200
- giveitem ITEM_FIGY_BERRY, 199
- giveitem ITEM_WIKI_BERRY, 200
- giveitem ITEM_WIKI_BERRY, 200
- giveitem ITEM_WIKI_BERRY, 200
- giveitem ITEM_WIKI_BERRY, 200
- giveitem ITEM_WIKI_BERRY, 199
- giveitem ITEM_MAGO_BERRY, 200
- giveitem ITEM_MAGO_BERRY, 200
- giveitem ITEM_MAGO_BERRY, 200
- giveitem ITEM_MAGO_BERRY, 200
- giveitem ITEM_MAGO_BERRY, 199
- giveitem ITEM_AGUAV_BERRY, 200
- giveitem ITEM_AGUAV_BERRY, 200
- giveitem ITEM_AGUAV_BERRY, 200
- giveitem ITEM_AGUAV_BERRY, 200
- giveitem ITEM_AGUAV_BERRY, 199
- giveitem ITEM_IAPAPA_BERRY, 200
- giveitem ITEM_IAPAPA_BERRY, 200
- giveitem ITEM_IAPAPA_BERRY, 200
- giveitem ITEM_IAPAPA_BERRY, 200
- giveitem ITEM_IAPAPA_BERRY, 199
- giveitem ITEM_RAZZ_BERRY, 200
- giveitem ITEM_RAZZ_BERRY, 200
- giveitem ITEM_RAZZ_BERRY, 200
- giveitem ITEM_RAZZ_BERRY, 200
- giveitem ITEM_RAZZ_BERRY, 199
- giveitem ITEM_BLUK_BERRY, 200
- giveitem ITEM_BLUK_BERRY, 200
- giveitem ITEM_BLUK_BERRY, 200
- giveitem ITEM_BLUK_BERRY, 200
- giveitem ITEM_BLUK_BERRY, 199
- giveitem ITEM_NANAB_BERRY, 200
- giveitem ITEM_NANAB_BERRY, 200
- giveitem ITEM_NANAB_BERRY, 200
- giveitem ITEM_NANAB_BERRY, 200
- giveitem ITEM_NANAB_BERRY, 199
- giveitem ITEM_WEPEAR_BERRY, 200
- giveitem ITEM_WEPEAR_BERRY, 200
- giveitem ITEM_WEPEAR_BERRY, 200
- giveitem ITEM_WEPEAR_BERRY, 200
- giveitem ITEM_WEPEAR_BERRY, 199
- giveitem ITEM_PINAP_BERRY, 200
- giveitem ITEM_PINAP_BERRY, 200
- giveitem ITEM_PINAP_BERRY, 200
- giveitem ITEM_PINAP_BERRY, 200
- giveitem ITEM_PINAP_BERRY, 199
- giveitem ITEM_POMEG_BERRY, 200
- giveitem ITEM_POMEG_BERRY, 200
- giveitem ITEM_POMEG_BERRY, 200
- giveitem ITEM_POMEG_BERRY, 200
- giveitem ITEM_POMEG_BERRY, 199
- giveitem ITEM_KELPSY_BERRY, 200
- giveitem ITEM_KELPSY_BERRY, 200
- giveitem ITEM_KELPSY_BERRY, 200
- giveitem ITEM_KELPSY_BERRY, 200
- giveitem ITEM_KELPSY_BERRY, 199
- giveitem ITEM_QUALOT_BERRY, 200
- giveitem ITEM_QUALOT_BERRY, 200
- giveitem ITEM_QUALOT_BERRY, 200
- giveitem ITEM_QUALOT_BERRY, 200
- giveitem ITEM_QUALOT_BERRY, 199
- giveitem ITEM_HONDEW_BERRY, 200
- giveitem ITEM_HONDEW_BERRY, 200
- giveitem ITEM_HONDEW_BERRY, 200
- giveitem ITEM_HONDEW_BERRY, 200
- giveitem ITEM_HONDEW_BERRY, 199
- giveitem ITEM_GREPA_BERRY, 200
- giveitem ITEM_GREPA_BERRY, 200
- giveitem ITEM_GREPA_BERRY, 200
- giveitem ITEM_GREPA_BERRY, 200
- giveitem ITEM_GREPA_BERRY, 199
- giveitem ITEM_TAMATO_BERRY, 200
- giveitem ITEM_TAMATO_BERRY, 200
- giveitem ITEM_TAMATO_BERRY, 200
- giveitem ITEM_TAMATO_BERRY, 200
- giveitem ITEM_TAMATO_BERRY, 199
- giveitem ITEM_CORNN_BERRY, 200
- giveitem ITEM_CORNN_BERRY, 200
- giveitem ITEM_CORNN_BERRY, 200
- giveitem ITEM_CORNN_BERRY, 200
- giveitem ITEM_CORNN_BERRY, 199
- giveitem ITEM_MAGOST_BERRY, 999
- giveitem ITEM_RABUTA_BERRY, 999
- giveitem ITEM_NOMEL_BERRY, 999
- giveitem ITEM_SPELON_BERRY, 999
- giveitem ITEM_PAMTRE_BERRY, 999
- giveitem ITEM_WATMEL_BERRY, 999
- giveitem ITEM_DURIN_BERRY, 999
- giveitem ITEM_BELUE_BERRY, 999
- giveitem ITEM_LIECHI_BERRY, 999
- giveitem ITEM_GANLON_BERRY, 999
- giveitem ITEM_SALAC_BERRY, 999
- giveitem ITEM_PETAYA_BERRY, 999
- giveitem ITEM_APICOT_BERRY, 999
- giveitem ITEM_LANSAT_BERRY, 999
- giveitem ITEM_STARF_BERRY, 999
- giveitem ITEM_ENIGMA_BERRY, 999
+ additem ITEM_POTION, 99
+ additem ITEM_ANTIDOTE, 99
+ additem ITEM_BURN_HEAL, 99
+ additem ITEM_ICE_HEAL, 99
+ additem ITEM_AWAKENING, 99
+ additem ITEM_PARALYZE_HEAL, 99
+ additem ITEM_FULL_RESTORE, 99
+ additem ITEM_MAX_POTION, 99
+ additem ITEM_HYPER_POTION, 99
+ additem ITEM_SUPER_POTION, 99
+ additem ITEM_FULL_HEAL, 99
+ additem ITEM_REVIVE, 99
+ additem ITEM_MAX_REVIVE, 99
+ additem ITEM_FRESH_WATER, 99
+ additem ITEM_SODA_POP, 99
+ additem ITEM_LEMONADE, 99
+ additem ITEM_MOOMOO_MILK, 99
+ additem ITEM_ENERGY_POWDER, 99
+ additem ITEM_ENERGY_ROOT, 99
+ additem ITEM_HEAL_POWDER, 99
+ additem ITEM_ORANGE_MAIL, 92
+ additem ITEM_RETRO_MAIL, 94
+ additem ITEM_POTION, 89
+ additem ITEM_MASTER_BALL, 99
+ additem ITEM_ULTRA_BALL, 99
+ additem ITEM_GREAT_BALL, 99
+ additem ITEM_POKE_BALL, 99
+ additem ITEM_NET_BALL, 99
+ additem ITEM_DIVE_BALL, 99
+ additem ITEM_NEST_BALL, 99
+ additem ITEM_REPEAT_BALL, 99
+ additem ITEM_TIMER_BALL, 99
+ additem ITEM_LUXURY_BALL, 99
+ additem ITEM_PREMIER_BALL, 99
+ additem ITEM_MASTER_BALL, 99
+ additem ITEM_MASTER_BALL, 99
+ additem ITEM_MASTER_BALL, 99
+ additem ITEM_MASTER_BALL, 99
+ additem ITEM_MASTER_BALL, 99
+ additem ITEM_MASTER_BALL, 99
+ additem ITEM_MASTER_BALL, 99
+ additem ITEM_MASTER_BALL, 99
+ additem ITEM_MASTER_BALL, 99
+ additem ITEM_GREAT_BALL, 79
+ additem ITEM_ULTRA_BALL, 84
+ additem ITEM_POKE_BALL, 89
+ additem ITEM_MASTER_BALL, 74
+ additem ITEM_TM01_FOCUS_PUNCH, 99
+ additem ITEM_TM02_DRAGON_CLAW, 99
+ additem ITEM_TM03_WATER_PULSE, 99
+ additem ITEM_TM04_CALM_MIND, 99
+ additem ITEM_TM05_ROAR, 99
+ additem ITEM_TM06_TOXIC, 99
+ additem ITEM_TM07_HAIL, 99
+ additem ITEM_TM08_BULK_UP, 99
+ additem ITEM_TM09_BULLET_SEED, 99
+ additem ITEM_TM10_HIDDEN_POWER, 99
+ additem ITEM_TM11_SUNNY_DAY, 99
+ additem ITEM_TM12_TAUNT, 99
+ additem ITEM_TM13_ICE_BEAM, 99
+ additem ITEM_TM14_BLIZZARD, 99
+ additem ITEM_TM15_HYPER_BEAM, 99
+ additem ITEM_TM16_LIGHT_SCREEN, 99
+ additem ITEM_TM17_PROTECT, 99
+ additem ITEM_TM18_RAIN_DANCE, 99
+ additem ITEM_TM19_GIGA_DRAIN, 99
+ additem ITEM_TM20_SAFEGUARD, 99
+ additem ITEM_TM21_FRUSTRATION, 99
+ additem ITEM_TM22_SOLARBEAM, 99
+ additem ITEM_TM23_IRON_TAIL, 99
+ additem ITEM_TM24_THUNDERBOLT, 99
+ additem ITEM_TM25_THUNDER, 99
+ additem ITEM_TM26_EARTHQUAKE, 99
+ additem ITEM_TM27_RETURN, 99
+ additem ITEM_TM28_DIG, 99
+ additem ITEM_TM29_PSYCHIC, 99
+ additem ITEM_TM30_SHADOW_BALL, 99
+ additem ITEM_TM31_BRICK_BREAK, 99
+ additem ITEM_TM32_DOUBLE_TEAM, 99
+ additem ITEM_TM33_REFLECT, 99
+ additem ITEM_TM34_SHOCK_WAVE, 99
+ additem ITEM_TM35_FLAMETHROWER, 99
+ additem ITEM_TM36_SLUDGE_BOMB, 99
+ additem ITEM_TM37_SANDSTORM, 99
+ additem ITEM_TM38_FIRE_BLAST, 99
+ additem ITEM_TM39_ROCK_TOMB, 99
+ additem ITEM_TM40_AERIAL_ACE, 99
+ additem ITEM_TM41_TORMENT, 99
+ additem ITEM_TM42_FACADE, 99
+ additem ITEM_TM43_SECRET_POWER, 99
+ additem ITEM_TM44_REST, 99
+ additem ITEM_TM45_ATTRACT, 99
+ additem ITEM_TM46_THIEF, 99
+ additem ITEM_TM47_STEEL_WING, 99
+ additem ITEM_TM48_SKILL_SWAP, 99
+ additem ITEM_TM49_SNATCH, 99
+ additem ITEM_TM50_OVERHEAT, 99
+ additem ITEM_CHERI_BERRY, 200
+ additem ITEM_CHERI_BERRY, 200
+ additem ITEM_CHERI_BERRY, 200
+ additem ITEM_CHERI_BERRY, 200
+ additem ITEM_CHERI_BERRY, 199
+ additem ITEM_CHESTO_BERRY, 200
+ additem ITEM_CHESTO_BERRY, 200
+ additem ITEM_CHESTO_BERRY, 200
+ additem ITEM_CHESTO_BERRY, 200
+ additem ITEM_CHESTO_BERRY, 199
+ additem ITEM_PECHA_BERRY, 200
+ additem ITEM_PECHA_BERRY, 200
+ additem ITEM_PECHA_BERRY, 200
+ additem ITEM_PECHA_BERRY, 200
+ additem ITEM_PECHA_BERRY, 199
+ additem ITEM_RAWST_BERRY, 200
+ additem ITEM_RAWST_BERRY, 200
+ additem ITEM_RAWST_BERRY, 200
+ additem ITEM_RAWST_BERRY, 200
+ additem ITEM_RAWST_BERRY, 199
+ additem ITEM_ASPEAR_BERRY, 200
+ additem ITEM_ASPEAR_BERRY, 200
+ additem ITEM_ASPEAR_BERRY, 200
+ additem ITEM_ASPEAR_BERRY, 200
+ additem ITEM_ASPEAR_BERRY, 199
+ additem ITEM_LEPPA_BERRY, 200
+ additem ITEM_LEPPA_BERRY, 200
+ additem ITEM_LEPPA_BERRY, 200
+ additem ITEM_LEPPA_BERRY, 200
+ additem ITEM_LEPPA_BERRY, 199
+ additem ITEM_ORAN_BERRY, 200
+ additem ITEM_ORAN_BERRY, 200
+ additem ITEM_ORAN_BERRY, 200
+ additem ITEM_ORAN_BERRY, 200
+ additem ITEM_ORAN_BERRY, 199
+ additem ITEM_PERSIM_BERRY, 200
+ additem ITEM_PERSIM_BERRY, 200
+ additem ITEM_PERSIM_BERRY, 200
+ additem ITEM_PERSIM_BERRY, 200
+ additem ITEM_PERSIM_BERRY, 199
+ additem ITEM_LUM_BERRY, 200
+ additem ITEM_LUM_BERRY, 200
+ additem ITEM_LUM_BERRY, 200
+ additem ITEM_LUM_BERRY, 200
+ additem ITEM_LUM_BERRY, 199
+ additem ITEM_SITRUS_BERRY, 200
+ additem ITEM_SITRUS_BERRY, 200
+ additem ITEM_SITRUS_BERRY, 200
+ additem ITEM_SITRUS_BERRY, 200
+ additem ITEM_SITRUS_BERRY, 199
+ additem ITEM_FIGY_BERRY, 200
+ additem ITEM_FIGY_BERRY, 200
+ additem ITEM_FIGY_BERRY, 200
+ additem ITEM_FIGY_BERRY, 200
+ additem ITEM_FIGY_BERRY, 199
+ additem ITEM_WIKI_BERRY, 200
+ additem ITEM_WIKI_BERRY, 200
+ additem ITEM_WIKI_BERRY, 200
+ additem ITEM_WIKI_BERRY, 200
+ additem ITEM_WIKI_BERRY, 199
+ additem ITEM_MAGO_BERRY, 200
+ additem ITEM_MAGO_BERRY, 200
+ additem ITEM_MAGO_BERRY, 200
+ additem ITEM_MAGO_BERRY, 200
+ additem ITEM_MAGO_BERRY, 199
+ additem ITEM_AGUAV_BERRY, 200
+ additem ITEM_AGUAV_BERRY, 200
+ additem ITEM_AGUAV_BERRY, 200
+ additem ITEM_AGUAV_BERRY, 200
+ additem ITEM_AGUAV_BERRY, 199
+ additem ITEM_IAPAPA_BERRY, 200
+ additem ITEM_IAPAPA_BERRY, 200
+ additem ITEM_IAPAPA_BERRY, 200
+ additem ITEM_IAPAPA_BERRY, 200
+ additem ITEM_IAPAPA_BERRY, 199
+ additem ITEM_RAZZ_BERRY, 200
+ additem ITEM_RAZZ_BERRY, 200
+ additem ITEM_RAZZ_BERRY, 200
+ additem ITEM_RAZZ_BERRY, 200
+ additem ITEM_RAZZ_BERRY, 199
+ additem ITEM_BLUK_BERRY, 200
+ additem ITEM_BLUK_BERRY, 200
+ additem ITEM_BLUK_BERRY, 200
+ additem ITEM_BLUK_BERRY, 200
+ additem ITEM_BLUK_BERRY, 199
+ additem ITEM_NANAB_BERRY, 200
+ additem ITEM_NANAB_BERRY, 200
+ additem ITEM_NANAB_BERRY, 200
+ additem ITEM_NANAB_BERRY, 200
+ additem ITEM_NANAB_BERRY, 199
+ additem ITEM_WEPEAR_BERRY, 200
+ additem ITEM_WEPEAR_BERRY, 200
+ additem ITEM_WEPEAR_BERRY, 200
+ additem ITEM_WEPEAR_BERRY, 200
+ additem ITEM_WEPEAR_BERRY, 199
+ additem ITEM_PINAP_BERRY, 200
+ additem ITEM_PINAP_BERRY, 200
+ additem ITEM_PINAP_BERRY, 200
+ additem ITEM_PINAP_BERRY, 200
+ additem ITEM_PINAP_BERRY, 199
+ additem ITEM_POMEG_BERRY, 200
+ additem ITEM_POMEG_BERRY, 200
+ additem ITEM_POMEG_BERRY, 200
+ additem ITEM_POMEG_BERRY, 200
+ additem ITEM_POMEG_BERRY, 199
+ additem ITEM_KELPSY_BERRY, 200
+ additem ITEM_KELPSY_BERRY, 200
+ additem ITEM_KELPSY_BERRY, 200
+ additem ITEM_KELPSY_BERRY, 200
+ additem ITEM_KELPSY_BERRY, 199
+ additem ITEM_QUALOT_BERRY, 200
+ additem ITEM_QUALOT_BERRY, 200
+ additem ITEM_QUALOT_BERRY, 200
+ additem ITEM_QUALOT_BERRY, 200
+ additem ITEM_QUALOT_BERRY, 199
+ additem ITEM_HONDEW_BERRY, 200
+ additem ITEM_HONDEW_BERRY, 200
+ additem ITEM_HONDEW_BERRY, 200
+ additem ITEM_HONDEW_BERRY, 200
+ additem ITEM_HONDEW_BERRY, 199
+ additem ITEM_GREPA_BERRY, 200
+ additem ITEM_GREPA_BERRY, 200
+ additem ITEM_GREPA_BERRY, 200
+ additem ITEM_GREPA_BERRY, 200
+ additem ITEM_GREPA_BERRY, 199
+ additem ITEM_TAMATO_BERRY, 200
+ additem ITEM_TAMATO_BERRY, 200
+ additem ITEM_TAMATO_BERRY, 200
+ additem ITEM_TAMATO_BERRY, 200
+ additem ITEM_TAMATO_BERRY, 199
+ additem ITEM_CORNN_BERRY, 200
+ additem ITEM_CORNN_BERRY, 200
+ additem ITEM_CORNN_BERRY, 200
+ additem ITEM_CORNN_BERRY, 200
+ additem ITEM_CORNN_BERRY, 199
+ additem ITEM_MAGOST_BERRY, 999
+ additem ITEM_RABUTA_BERRY, 999
+ additem ITEM_NOMEL_BERRY, 999
+ additem ITEM_SPELON_BERRY, 999
+ additem ITEM_PAMTRE_BERRY, 999
+ additem ITEM_WATMEL_BERRY, 999
+ additem ITEM_DURIN_BERRY, 999
+ additem ITEM_BELUE_BERRY, 999
+ additem ITEM_LIECHI_BERRY, 999
+ additem ITEM_GANLON_BERRY, 999
+ additem ITEM_SALAC_BERRY, 999
+ additem ITEM_PETAYA_BERRY, 999
+ additem ITEM_APICOT_BERRY, 999
+ additem ITEM_LANSAT_BERRY, 999
+ additem ITEM_STARF_BERRY, 999
+ additem ITEM_ENIGMA_BERRY, 999
end
DebugScript_081C221F:: @ 81C221F
- givedecoration DECOR_SMALL_DESK
- givedecoration DECOR_SMALL_DESK
- givedecoration DECOR_SMALL_DESK
- givedecoration DECOR_SMALL_DESK
- givedecoration DECOR_SMALL_DESK
- givedecoration DECOR_SMALL_DESK
- givedecoration DECOR_SMALL_DESK
- givedecoration DECOR_SMALL_DESK
- givedecoration DECOR_SMALL_DESK
- givedecoration DECOR_SMALL_DESK
- givedecoration DECOR_SMALL_CHAIR
- givedecoration DECOR_SMALL_CHAIR
- givedecoration DECOR_SMALL_CHAIR
- givedecoration DECOR_SMALL_CHAIR
- givedecoration DECOR_SMALL_CHAIR
- givedecoration DECOR_SMALL_CHAIR
- givedecoration DECOR_SMALL_CHAIR
- givedecoration DECOR_SMALL_CHAIR
- givedecoration DECOR_SMALL_CHAIR
- givedecoration DECOR_SMALL_CHAIR
- givedecoration DECOR_RED_PLANT
- givedecoration DECOR_RED_PLANT
- givedecoration DECOR_RED_PLANT
- givedecoration DECOR_RED_PLANT
- givedecoration DECOR_RED_PLANT
- givedecoration DECOR_RED_PLANT
- givedecoration DECOR_RED_PLANT
- givedecoration DECOR_RED_PLANT
- givedecoration DECOR_RED_PLANT
- givedecoration DECOR_RED_PLANT
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_RED_BRICK
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_JUMP_MAT
- givedecoration DECOR_BALL_POSTER
- givedecoration DECOR_BALL_POSTER
- givedecoration DECOR_BALL_POSTER
- givedecoration DECOR_BALL_POSTER
- givedecoration DECOR_BALL_POSTER
- givedecoration DECOR_BALL_POSTER
- givedecoration DECOR_BALL_POSTER
- givedecoration DECOR_BALL_POSTER
- givedecoration DECOR_BALL_POSTER
- givedecoration DECOR_BALL_POSTER
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_DUSKULL_DOLL
- givedecoration DECOR_KISS_CUSHION
- givedecoration DECOR_KISS_CUSHION
- givedecoration DECOR_KISS_CUSHION
- givedecoration DECOR_KISS_CUSHION
- givedecoration DECOR_KISS_CUSHION
- givedecoration DECOR_KISS_CUSHION
- givedecoration DECOR_KISS_CUSHION
- givedecoration DECOR_KISS_CUSHION
- givedecoration DECOR_KISS_CUSHION
- givedecoration DECOR_KISS_CUSHION
+ adddecoration DECOR_SMALL_DESK
+ adddecoration DECOR_SMALL_DESK
+ adddecoration DECOR_SMALL_DESK
+ adddecoration DECOR_SMALL_DESK
+ adddecoration DECOR_SMALL_DESK
+ adddecoration DECOR_SMALL_DESK
+ adddecoration DECOR_SMALL_DESK
+ adddecoration DECOR_SMALL_DESK
+ adddecoration DECOR_SMALL_DESK
+ adddecoration DECOR_SMALL_DESK
+ adddecoration DECOR_SMALL_CHAIR
+ adddecoration DECOR_SMALL_CHAIR
+ adddecoration DECOR_SMALL_CHAIR
+ adddecoration DECOR_SMALL_CHAIR
+ adddecoration DECOR_SMALL_CHAIR
+ adddecoration DECOR_SMALL_CHAIR
+ adddecoration DECOR_SMALL_CHAIR
+ adddecoration DECOR_SMALL_CHAIR
+ adddecoration DECOR_SMALL_CHAIR
+ adddecoration DECOR_SMALL_CHAIR
+ adddecoration DECOR_RED_PLANT
+ adddecoration DECOR_RED_PLANT
+ adddecoration DECOR_RED_PLANT
+ adddecoration DECOR_RED_PLANT
+ adddecoration DECOR_RED_PLANT
+ adddecoration DECOR_RED_PLANT
+ adddecoration DECOR_RED_PLANT
+ adddecoration DECOR_RED_PLANT
+ adddecoration DECOR_RED_PLANT
+ adddecoration DECOR_RED_PLANT
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_RED_BRICK
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_JUMP_MAT
+ adddecoration DECOR_BALL_POSTER
+ adddecoration DECOR_BALL_POSTER
+ adddecoration DECOR_BALL_POSTER
+ adddecoration DECOR_BALL_POSTER
+ adddecoration DECOR_BALL_POSTER
+ adddecoration DECOR_BALL_POSTER
+ adddecoration DECOR_BALL_POSTER
+ adddecoration DECOR_BALL_POSTER
+ adddecoration DECOR_BALL_POSTER
+ adddecoration DECOR_BALL_POSTER
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_DUSKULL_DOLL
+ adddecoration DECOR_KISS_CUSHION
+ adddecoration DECOR_KISS_CUSHION
+ adddecoration DECOR_KISS_CUSHION
+ adddecoration DECOR_KISS_CUSHION
+ adddecoration DECOR_KISS_CUSHION
+ adddecoration DECOR_KISS_CUSHION
+ adddecoration DECOR_KISS_CUSHION
+ adddecoration DECOR_KISS_CUSHION
+ adddecoration DECOR_KISS_CUSHION
+ adddecoration DECOR_KISS_CUSHION
end
DebugScript_081C23E2:: @ 81C23E2
- givecoins 9999
+ addcoins 9999
end
DebugScript_081C23E6:: @ 81C23E6
@@ -458,7 +458,7 @@ DebugScript_081C23E6:: @ 81C23E6
end
DebugScript_081C23F6:: @ 81C23F6
- takemoney 999999, 0x00
+ removemoney 999999, 0
end
DebugScript_081C23FD:: @ 81C23FD
@@ -476,15 +476,15 @@ DebugScript_081C23FD:: @ 81C23FD
end
DebugScript_081C2436:: @ 81C2436
- givemon SPECIES_BARBOACH, 99, 0, 0, 0, 0
+ givemon SPECIES_BARBOACH, 99, ITEM_NONE
DebugScript_081C2445:
- givemon SPECIES_BARBOACH, 99, 0, 0, 0, 0
+ givemon SPECIES_BARBOACH, 99, ITEM_NONE
DebugScript_081C2454:
- givemon SPECIES_BARBOACH, 99, 0, 0, 0, 0
+ givemon SPECIES_BARBOACH, 99, ITEM_NONE
DebugScript_081C2463:
- givemon SPECIES_BARBOACH, 99, 0, 0, 0, 0
+ givemon SPECIES_BARBOACH, 99, ITEM_NONE
DebugScript_081C2472:
- givemon SPECIES_BARBOACH, 99, 0, 0, 0, 0
+ givemon SPECIES_BARBOACH, 99, ITEM_NONE
end
DebugScript_081C2482:: @ 81C2482
@@ -502,15 +502,15 @@ DebugScript_081C2482:: @ 81C2482
end
DebugScript_081C24BB:: @ 81C24BB
- givemon SPECIES_SHROOMISH, 99, 0, 0, 0, 0
+ givemon SPECIES_SHROOMISH, 99, ITEM_NONE
DebugScript_081C24CA:
- givemon SPECIES_SHROOMISH, 99, 0, 0, 0, 0
+ givemon SPECIES_SHROOMISH, 99, ITEM_NONE
DebugScript_081C24D9:
- givemon SPECIES_SHROOMISH, 99, 0, 0, 0, 0
+ givemon SPECIES_SHROOMISH, 99, ITEM_NONE
DebugScript_081C24E8:
- givemon SPECIES_SHROOMISH, 99, 0, 0, 0, 0
+ givemon SPECIES_SHROOMISH, 99, ITEM_NONE
DebugScript_081C24F7:
- givemon SPECIES_SHROOMISH, 99, 0, 0, 0, 0
+ givemon SPECIES_SHROOMISH, 99, ITEM_NONE
end
DebugScript_081C2507:: @ 81C2507
diff --git a/data/scripts/dynamic_npc_graphics.inc b/data/scripts/dynamic_npc_graphics.inc
new file mode 100644
index 000000000..2af18fbcd
--- /dev/null
+++ b/data/scripts/dynamic_npc_graphics.inc
@@ -0,0 +1,59 @@
+Common_EventScript_SetupRivalGfxId:: @ 81A014E
+ checkplayergender
+ compare VAR_RESULT, MALE
+ goto_if_eq EventScript_SetupRivalGfxIdFemale
+ compare VAR_RESULT, FEMALE
+ goto_if_eq EventScript_SetupRivalGfxIdMale
+ end
+
+EventScript_SetupRivalGfxIdFemale:: @ 81A0166
+ setvar VAR_OBJ_GFX_ID_0, OBJ_EVENT_GFX_RIVAL_MAY_NORMAL
+ return
+
+EventScript_SetupRivalGfxIdMale:: @ 81A016C
+ setvar VAR_OBJ_GFX_ID_0, OBJ_EVENT_GFX_RIVAL_BRENDAN_NORMAL
+ return
+
+Common_EventScript_SetupRivalOnBikeGfxId:: @ 81A0172
+ checkplayergender
+ compare VAR_RESULT, MALE
+ goto_if_eq EventScript_SetupRivalOnBikeGfxIdFemale
+ compare VAR_RESULT, FEMALE
+ goto_if_eq EventScript_SetupRivalOnBikeGfxIdMale
+ end
+
+EventScript_SetupRivalOnBikeGfxIdFemale:: @ 81A018A
+ setvar VAR_OBJ_GFX_ID_3, OBJ_EVENT_GFX_RIVAL_MAY_MACH_BIKE
+ return
+
+EventScript_SetupRivalOnBikeGfxIdMale:: @ 81A0190
+ setvar VAR_OBJ_GFX_ID_3, OBJ_EVENT_GFX_RIVAL_BRENDAN_MACH_BIKE
+ return
+
+Common_EventScript_SetupEvilTeamGfxIds:: @ 81A0196
+ .ifdef SAPPHIRE
+ setvar VAR_OBJ_GFX_ID_1, OBJ_EVENT_GFX_AQUA_MEMBER_M
+ setvar VAR_OBJ_GFX_ID_2, OBJ_EVENT_GFX_AQUA_MEMBER_F
+ setvar VAR_OBJ_GFX_ID_4, OBJ_EVENT_GFX_MAGMA_MEMBER_M
+ setvar VAR_OBJ_GFX_ID_5, OBJ_EVENT_GFX_MAGMA_MEMBER_F
+ setvar VAR_OBJ_GFX_ID_6, OBJ_EVENT_GFX_ARCHIE
+ setvar VAR_OBJ_GFX_ID_7, OBJ_EVENT_GFX_MAXIE
+ .else
+ setvar VAR_OBJ_GFX_ID_1, OBJ_EVENT_GFX_MAGMA_MEMBER_M
+ setvar VAR_OBJ_GFX_ID_2, OBJ_EVENT_GFX_MAGMA_MEMBER_F
+ setvar VAR_OBJ_GFX_ID_4, OBJ_EVENT_GFX_AQUA_MEMBER_M
+ setvar VAR_OBJ_GFX_ID_5, OBJ_EVENT_GFX_AQUA_MEMBER_F
+ setvar VAR_OBJ_GFX_ID_6, OBJ_EVENT_GFX_MAXIE
+ setvar VAR_OBJ_GFX_ID_7, OBJ_EVENT_GFX_ARCHIE
+ .endif
+ return
+
+Common_EventScript_SetupLegendaryGfxIds:: @ 81A01B5
+ .ifdef SAPPHIRE
+ setvar VAR_OBJ_GFX_ID_8, OBJ_EVENT_GFX_KYOGRE_1
+ setvar VAR_OBJ_GFX_ID_9, OBJ_EVENT_GFX_KYOGRE_2
+ .else
+ setvar VAR_OBJ_GFX_ID_8, OBJ_EVENT_GFX_GROUDON_1
+ setvar VAR_OBJ_GFX_ID_9, OBJ_EVENT_GFX_GROUDON_2
+ .endif
+ return
diff --git a/data/scripts/elite_four.inc b/data/scripts/elite_four.inc
new file mode 100644
index 000000000..39d52825e
--- /dev/null
+++ b/data/scripts/elite_four.inc
@@ -0,0 +1,62 @@
+PokemonLeague_EliteFour_SetAdvanceToNextRoomMetatiles:: @ 81A0693
+ applymovement OBJ_EVENT_ID_PLAYER, Common_Movement_Delay32
+ waitmovement 0
+ playse SE_DOOR
+ setmetatile 6, 1, METATILE_EliteFour_OpenDoor_Frame, 0
+ setmetatile 6, 2, METATILE_EliteFour_OpenDoor_Opening, 0
+ setmetatile 0, 2, METATILE_EliteFour_RightSpotlightOff, 1
+ setmetatile 1, 2, METATILE_EliteFour_LeftSpotlightOff, 1
+ setmetatile 2, 2, METATILE_EliteFour_RightSpotlightOff, 1
+ setmetatile 3, 2, METATILE_EliteFour_LeftSpotlightOff, 1
+ setmetatile 4, 2, METATILE_EliteFour_RightSpotlightOff, 1
+ setmetatile 8, 2, METATILE_EliteFour_LeftSpotlightOff, 1
+ setmetatile 9, 2, METATILE_EliteFour_RightSpotlightOff, 1
+ setmetatile 10, 2, METATILE_EliteFour_LeftSpotlightOff, 1
+ setmetatile 11, 2, METATILE_EliteFour_RightSpotlightOff, 1
+ setmetatile 12, 2, METATILE_EliteFour_LeftSpotlightOff, 1
+ special DrawWholeMapView
+ return
+
+PokemonLeague_EliteFour_EventScript_WalkInCloseDoor:: @ 81A0710
+ applymovement OBJ_EVENT_ID_PLAYER, Common_Movement_WalkUp6
+ waitmovement 0
+ playse SE_TRACK_DOOR
+ setmetatile 5, 12, METATILE_EliteFour_EntryDoor_ClosedTop, 1
+ setmetatile 6, 12, METATILE_EliteFour_EntryDoor_ClosedTop, 1
+ setmetatile 7, 12, METATILE_EliteFour_EntryDoor_ClosedTop, 1
+ setmetatile 5, 13, METATILE_EliteFour_EntryDoor_ClosedBottom, 1
+ setmetatile 6, 13, METATILE_EliteFour_EntryDoor_ClosedBottom, 1
+ setmetatile 7, 13, METATILE_EliteFour_EntryDoor_ClosedBottom, 1
+ special DrawWholeMapView
+ return
+
+@ Essentially unused, only necessary when re-entering an Elite Four room after defeating the member, which isnt normally possible
+PokemonLeague_EliteFour_EventScript_ResetAdvanceToNextRoom:: @ 81A0757
+ setmetatile 6, 1, METATILE_EliteFour_OpenDoor_Frame, 0
+ setmetatile 6, 2, METATILE_EliteFour_OpenDoor_Opening, 0
+ setmetatile 5, 12, METATILE_EliteFour_EntryDoor_ClosedTop, 1
+ setmetatile 6, 12, METATILE_EliteFour_EntryDoor_ClosedTop, 1
+ setmetatile 7, 12, METATILE_EliteFour_EntryDoor_ClosedTop, 1
+ setmetatile 5, 13, METATILE_EliteFour_EntryDoor_ClosedBottom, 1
+ setmetatile 6, 13, METATILE_EliteFour_EntryDoor_ClosedBottom, 1
+ setmetatile 7, 13, METATILE_EliteFour_EntryDoor_ClosedBottom, 1
+ setmetatile 0, 2, METATILE_EliteFour_RightSpotlightOff, 1
+ setmetatile 1, 2, METATILE_EliteFour_LeftSpotlightOff, 1
+ setmetatile 2, 2, METATILE_EliteFour_RightSpotlightOff, 1
+ setmetatile 3, 2, METATILE_EliteFour_LeftSpotlightOff, 1
+ setmetatile 4, 2, METATILE_EliteFour_RightSpotlightOff, 1
+ setmetatile 8, 2, METATILE_EliteFour_LeftSpotlightOff, 1
+ setmetatile 9, 2, METATILE_EliteFour_RightSpotlightOff, 1
+ setmetatile 10, 2, METATILE_EliteFour_LeftSpotlightOff, 1
+ setmetatile 11, 2, METATILE_EliteFour_RightSpotlightOff, 1
+ setmetatile 12, 2, METATILE_EliteFour_LeftSpotlightOff, 1
+ return
+
+PokemonLeague_EliteFour_EventScript_CloseDoor:: @ 81A07FA
+ setmetatile 5, 12, METATILE_EliteFour_EntryDoor_ClosedTop, 1
+ setmetatile 6, 12, METATILE_EliteFour_EntryDoor_ClosedTop, 1
+ setmetatile 7, 12, METATILE_EliteFour_EntryDoor_ClosedTop, 1
+ setmetatile 5, 13, METATILE_EliteFour_EntryDoor_ClosedBottom, 1
+ setmetatile 6, 13, METATILE_EliteFour_EntryDoor_ClosedBottom, 1
+ setmetatile 7, 13, METATILE_EliteFour_EntryDoor_ClosedBottom, 1
+ return
diff --git a/data/scripts/gabby_and_ty.inc b/data/scripts/gabby_and_ty.inc
index f8d57f084..cb5e230b9 100644
--- a/data/scripts/gabby_and_ty.inc
+++ b/data/scripts/gabby_and_ty.inc
@@ -124,78 +124,78 @@ Route111_EventScript_1AE41E:: @ 81AE41E
return
Route111_EventScript_1AE422:: @ 81AE422
- trainerbattle 6, TRAINER_GABBY_AND_TY_1, 0, Route111_Text_1ABED8, Route111_Text_1ABFD3, Route111_Text_1AC5CA, Route111_EventScript_1AE5A2
- msgbox Route111_Text_1AC59E, 4
+ trainerbattle_double TRAINER_GABBY_AND_TY_1, Route111_Text_1ABED8, Route111_Text_1ABFD3, Route111_Text_1AC5CA, Route111_EventScript_1AE5A2
+ msgbox Route111_Text_1AC59E, MSGBOX_DEFAULT
release
end
Route111_EventScript_1AE442:: @ 81AE442
- trainerbattle 6, TRAINER_GABBY_AND_TY_1, 0, Route111_Text_1AC73B, Route111_Text_1AC892, Route111_Text_1AC820, Route111_EventScript_1AE5A2
- msgbox Route111_Text_1AC7E4, 4
+ trainerbattle_double TRAINER_GABBY_AND_TY_1, Route111_Text_1AC73B, Route111_Text_1AC892, Route111_Text_1AC820, Route111_EventScript_1AE5A2
+ msgbox Route111_Text_1AC7E4, MSGBOX_DEFAULT
release
end
Route118_EventScript_1AE462:: @ 81AE462
- trainerbattle 6, TRAINER_GABBY_AND_TY_2, 0, Route118_Text_1ABF50, Route118_Text_1AC6F8, Route118_Text_1AC5CA, Route118_EventScript_1AE60F
- msgbox Route118_Text_1AC59E, 4
+ trainerbattle_double TRAINER_GABBY_AND_TY_2, Route118_Text_1ABF50, Route118_Text_1AC6F8, Route118_Text_1AC5CA, Route118_EventScript_1AE60F
+ msgbox Route118_Text_1AC59E, MSGBOX_DEFAULT
release
end
Route118_EventScript_1AE482:: @ 81AE482
- trainerbattle 6, TRAINER_GABBY_AND_TY_2, 0, Route118_Text_1AC790, Route118_Text_1AC8D7, Route118_Text_1AC820, Route118_EventScript_1AE60F
- msgbox Route118_Text_1AC7E4, 4
+ trainerbattle_double TRAINER_GABBY_AND_TY_2, Route118_Text_1AC790, Route118_Text_1AC8D7, Route118_Text_1AC820, Route118_EventScript_1AE60F
+ msgbox Route118_Text_1AC7E4, MSGBOX_DEFAULT
release
end
Route120_EventScript_1AE4A2:: @ 81AE4A2
- trainerbattle 6, TRAINER_GABBY_AND_TY_3, 0, Route120_Text_1ABF50, Route120_Text_1AC6F8, Route120_Text_1AC5CA, Route120_EventScript_1AE60F
- msgbox Route120_Text_1AC59E, 4
+ trainerbattle_double TRAINER_GABBY_AND_TY_3, Route120_Text_1ABF50, Route120_Text_1AC6F8, Route120_Text_1AC5CA, Route120_EventScript_1AE60F
+ msgbox Route120_Text_1AC59E, MSGBOX_DEFAULT
release
end
Route120_EventScript_1AE4C2:: @ 81AE4C2
- trainerbattle 6, TRAINER_GABBY_AND_TY_3, 0, Route120_Text_1AC790, Route120_Text_1AC8D7, Route120_Text_1AC820, Route120_EventScript_1AE60F
- msgbox Route120_Text_1AC7E4, 4
+ trainerbattle_double TRAINER_GABBY_AND_TY_3, Route120_Text_1AC790, Route120_Text_1AC8D7, Route120_Text_1AC820, Route120_EventScript_1AE60F
+ msgbox Route120_Text_1AC7E4, MSGBOX_DEFAULT
release
end
Route111_EventScript_1AE4E2:: @ 81AE4E2
- trainerbattle 6, TRAINER_GABBY_AND_TY_4, 0, Route111_Text_1ABF50, Route111_Text_1AC6F8, Route111_Text_1AC5CA, Route111_EventScript_1AE60F
- msgbox Route111_Text_1AC59E, 4
+ trainerbattle_double TRAINER_GABBY_AND_TY_4, Route111_Text_1ABF50, Route111_Text_1AC6F8, Route111_Text_1AC5CA, Route111_EventScript_1AE60F
+ msgbox Route111_Text_1AC59E, MSGBOX_DEFAULT
release
end
Route111_EventScript_1AE502:: @ 81AE502
- trainerbattle 6, TRAINER_GABBY_AND_TY_4, 0, Route111_Text_1AC790, Route111_Text_1AC8D7, Route111_Text_1AC820, Route111_EventScript_1AE60F
- msgbox Route111_Text_1AC7E4, 4
+ trainerbattle_double TRAINER_GABBY_AND_TY_4, Route111_Text_1AC790, Route111_Text_1AC8D7, Route111_Text_1AC820, Route111_EventScript_1AE60F
+ msgbox Route111_Text_1AC7E4, MSGBOX_DEFAULT
release
end
Route118_EventScript_1AE522:: @ 81AE522
- trainerbattle 6, TRAINER_GABBY_AND_TY_5, 0, Route118_Text_1ABF50, Route118_Text_1AC6F8, Route118_Text_1AC5CA, Route118_EventScript_1AE60F
- msgbox Route118_Text_1AC59E, 4
+ trainerbattle_double TRAINER_GABBY_AND_TY_5, Route118_Text_1ABF50, Route118_Text_1AC6F8, Route118_Text_1AC5CA, Route118_EventScript_1AE60F
+ msgbox Route118_Text_1AC59E, MSGBOX_DEFAULT
release
end
Route118_EventScript_1AE542:: @ 81AE542
- trainerbattle 6, TRAINER_GABBY_AND_TY_5, 0, Route118_Text_1AC790, Route118_Text_1AC8D7, Route118_Text_1AC820, Route118_EventScript_1AE60F
- msgbox Route118_Text_1AC7E4, 4
+ trainerbattle_double TRAINER_GABBY_AND_TY_5, Route118_Text_1AC790, Route118_Text_1AC8D7, Route118_Text_1AC820, Route118_EventScript_1AE60F
+ msgbox Route118_Text_1AC7E4, MSGBOX_DEFAULT
release
end
Route111_EventScript_1AE562:: @ 81AE562
Route118_EventScript_1AE562:: @ 81AE562
Route120_EventScript_1AE562:: @ 81AE562
- trainerbattle 6, TRAINER_GABBY_AND_TY_6, 0, Route111_Text_1ABF50, Route111_Text_1AC6F8, Route111_Text_1AC5CA, Route111_EventScript_1AE60F
- msgbox Route111_Text_1AC59E, 4
+ trainerbattle_double TRAINER_GABBY_AND_TY_6, Route111_Text_1ABF50, Route111_Text_1AC6F8, Route111_Text_1AC5CA, Route111_EventScript_1AE60F
+ msgbox Route111_Text_1AC59E, MSGBOX_DEFAULT
release
end
Route111_EventScript_1AE582:: @ 81AE582
Route118_EventScript_1AE582:: @ 81AE582
Route120_EventScript_1AE582:: @ 81AE582
- trainerbattle 6, TRAINER_GABBY_AND_TY_6, 0, Route111_Text_1AC790, Route111_Text_1AC8D7, Route111_Text_1AC820, Route111_EventScript_1AE60F
- msgbox Route111_Text_1AC7E4, 4
+ trainerbattle_double TRAINER_GABBY_AND_TY_6, Route111_Text_1AC790, Route111_Text_1AC8D7, Route111_Text_1AC820, Route111_EventScript_1AE60F
+ msgbox Route111_Text_1AC7E4, MSGBOX_DEFAULT
release
end
@@ -220,13 +220,13 @@ Route111_EventScript_1AE5E0:: @ 81AE5E0
Route111_EventScript_1AE5EB:: @ 81AE5EB
applymovement VAR_0x8004, Route111_Movement_1AE69B
- applymovement VAR_0x8005, Route111_Movement_1A0841
+ applymovement VAR_0x8005, Common_Movement_WalkInPlaceFastestUp
waitmovement 0
return
Route111_EventScript_1AE5FD:: @ 81AE5FD
applymovement VAR_0x8004, Route111_Movement_1AE69D
- applymovement VAR_0x8005, Route111_Movement_1A083F
+ applymovement VAR_0x8005, Common_Movement_WalkInPlaceFastestLeft
waitmovement 0
return
@@ -245,7 +245,7 @@ Route120_EventScript_1AE60F:: @ 81AE60F
specialvar VAR_RESULT, GabbyAndTyGetLastQuote
compare VAR_RESULT, 0
goto_if_eq Route111_EventScript_1AE69F
- msgbox Route111_Text_1AC10A, 4
+ msgbox Route111_Text_1AC10A, MSGBOX_DEFAULT
specialvar VAR_RESULT, GabbyAndTyGetLastBattleTrivia
switch VAR_RESULT
case 0, Route111_EventScript_1AE6AD
@@ -257,15 +257,15 @@ Route120_EventScript_1AE60F:: @ 81AE60F
Route111_Movement_1AE699:: @ 81AE699
walk_in_place_down
- end_movement
+ step_end
Route111_Movement_1AE69B:: @ 81AE69B
walk_in_place_up
- end_movement
+ step_end
Route111_Movement_1AE69D:: @ 81AE69D
walk_in_place_left
- end_movement
+ step_end
Route111_EventScript_1AE69F:: @ 81AE69F
msgbox Route111_Text_1AC60B, MSGBOX_YESNO
@@ -300,26 +300,26 @@ Route111_EventScript_1AE6E5:: @ 81AE6E5
Route111_EventScript_1AE6F3:: @ 81AE6F3
compare VAR_RESULT, NO
goto_if_eq Route111_EventScript_1AE72D
- msgbox Route111_Text_1AC40F, 4
+ msgbox Route111_Text_1AC40F, MSGBOX_DEFAULT
setvar VAR_0x8004, 10
- call Route111_EventScript_1A00F3
+ call Common_EventScript_ShowEasyChatScreen
lock
faceplayer
compare VAR_RESULT, 0
goto_if_eq Route111_EventScript_1AE72D
- msgbox Route111_Text_1AC487, 4
+ msgbox Route111_Text_1AC487, MSGBOX_DEFAULT
special GabbyAndTyAfterInterview
setflag FLAG_TEMP_1
release
end
Route111_EventScript_1AE72D:: @ 81AE72D
- msgbox Route111_Text_1AC553, 4
+ msgbox Route111_Text_1AC553, MSGBOX_DEFAULT
setflag FLAG_TEMP_1
release
end
Route111_EventScript_1AE73A:: @ 81AE73A
- msgbox Route111_Text_1AC59E, 4
+ msgbox Route111_Text_1AC59E, MSGBOX_DEFAULT
release
end
diff --git a/data/scripts/hall_of_fame.inc b/data/scripts/hall_of_fame.inc
new file mode 100644
index 000000000..21ea702d4
--- /dev/null
+++ b/data/scripts/hall_of_fame.inc
@@ -0,0 +1,34 @@
+EverGrandeCity_HallOfFame_EventScript_SetGameClearFlags:: @ 819FC13
+ clearflag FLAG_HIDE_LILYCOVE_MOTEL_PEOPLE
+ call EverGrandeCity_HallOfFame_EventScript_ResetEliteFour
+ setflag FLAG_HIDE_BRINEY_SLATEPORT_SHIPYARD
+ clearflag FLAG_HIDE_BRINEY_AND_PEEKO_SS_TIDAL
+ clearflag FLAG_HIDE_STEVENS_LETTER
+ setvar VAR_STEVENS_HOUSE_STATE, 1
+ clearflag FLAG_HIDE_WALLY_DEFEATED_VICTORY_ROAD
+ clearflag FLAG_HIDE_SS_TIDAL_SLATEPORT_HARBOR
+ clearflag FLAG_HIDE_SS_TIDAL_LILYCOVE_HARBOR
+ special UpdateTrainerFanClubGameClear
+ call_if_unset FLAG_RECEIVED_SS_TICKET, EverGrandeCity_HallOfFame_EventScript_ReadyReceiveSSTicketEvent
+ call_if_unset FLAG_LATIOS_OR_LATIAS_ROAMING, EverGrandeCity_HallOfFame_EventScript_ReadyLatiTVEvent
+ call_if_unset FLAG_RECEIVED_BELDUM, EverGrandeCity_HallOfFame_EventScript_ShowStevensBeldum
+ call_if_unset FLAG_RECEIVED_HM08, EverGrandeCity_HallOfFame_EventScript_ShowHM08
+ return
+
+EverGrandeCity_HallOfFame_EventScript_ShowStevensBeldum:: @ 819FC5A
+ clearflag FLAG_HIDE_BELDUM_BALL_STEVENS_HOUSE
+ return
+
+EverGrandeCity_HallOfFame_EventScript_ShowHM08:: @ 819FC5E
+ clearflag FLAG_ITEM_MOSSDEEP_STEVENS_HOUSE_HM08
+ return
+
+EverGrandeCity_HallOfFame_EventScript_ReadyReceiveSSTicketEvent:: @ 819FC62
+ setvar VAR_LITTLEROOT_HOUSES_STATE, 3
+ setvar VAR_LITTLEROOT_HOUSES_STATE_2, 3
+ clearflag FLAG_HIDE_NORMAN_LITTLEROOT
+ return
+
+EverGrandeCity_HallOfFame_EventScript_ReadyLatiTVEvent:: @ 819FC70
+ setflag FLAG_SYS_TV_LATI
+ return
diff --git a/data/scripts/magma_chimney.inc b/data/scripts/magma_chimney.inc
index ff31d8b97..70e91f09b 100644
--- a/data/scripts/magma_chimney.inc
+++ b/data/scripts/magma_chimney.inc
@@ -4,7 +4,7 @@ MtChimney_EventScript_1B2C95:: @ 81B2C95
call_if_unset FLAG_EVIL_LEADER_PLEASE_STOP, MtChimney_EventScript_1B2CB9
call_if_set FLAG_EVIL_LEADER_PLEASE_STOP, MtChimney_EventScript_1B2CC2
closemessage
- applymovement 1, MtChimney_Movement_1A083D
+ applymovement 1, Common_Movement_FaceOriginalDirection
waitmovement 0
setflag FLAG_EVIL_LEADER_PLEASE_STOP
release
@@ -12,69 +12,69 @@ MtChimney_EventScript_1B2C95:: @ 81B2C95
MtChimney_EventScript_1B2CB9:: @ 81B2CB9
.ifdef SAPPHIRE
- msgbox MtChimney_Text_1B350B, 4
+ msgbox MtChimney_Text_1B350B, MSGBOX_DEFAULT
.else
- msgbox MtChimney_Text_1B3EC1, 4
+ msgbox MtChimney_Text_1B3EC1, MSGBOX_DEFAULT
.endif
return
MtChimney_EventScript_1B2CC2:: @ 81B2CC2
.ifdef SAPPHIRE
- msgbox MtChimney_Text_1B3598, 4
+ msgbox MtChimney_Text_1B3598, MSGBOX_DEFAULT
.else
- msgbox MtChimney_Text_1B3F8C, 4
+ msgbox MtChimney_Text_1B3F8C, MSGBOX_DEFAULT
.endif
return
MtChimney_EventScript_1B2CCB:: @ 81B2CCB
lockall
.ifdef SAPPHIRE
- msgbox MtChimney_Text_1B2DEE, 4
+ msgbox MtChimney_Text_1B2DEE, MSGBOX_DEFAULT
.else
- msgbox MtChimney_Text_1B37BB, 4
+ msgbox MtChimney_Text_1B37BB, MSGBOX_DEFAULT
.endif
- applymovement 2, MtChimney_Movement_1A0839
+ applymovement 2, Common_Movement_FacePlayer
waitmovement 0
playse SE_PIN
- applymovement 2, MtChimney_Movement_1A0833
+ applymovement 2, Common_Movement_ExclamationMark
waitmovement 0
- applymovement 2, MtChimney_Movement_1A0835
+ applymovement 2, Common_Movement_Delay48
waitmovement 0
.ifdef SAPPHIRE
- msgbox MtChimney_Text_1B2ED9, 4
+ msgbox MtChimney_Text_1B2ED9, MSGBOX_DEFAULT
.else
- msgbox MtChimney_Text_1B38B3, 4
+ msgbox MtChimney_Text_1B38B3, MSGBOX_DEFAULT
.endif
.ifdef SAPPHIRE
- trainerbattle 3, TRAINER_MT_CHIMNEY_GRUNT_3, 0, MtChimney_Text_1B3099
+ trainerbattle_no_intro TRAINER_MT_CHIMNEY_GRUNT_3, MtChimney_Text_1B3099
.else
- trainerbattle 3, TRAINER_MT_CHIMNEY_GRUNT_3, 0, MtChimney_Text_1B3A68
+ trainerbattle_no_intro TRAINER_MT_CHIMNEY_GRUNT_3, MtChimney_Text_1B3A68
.endif
.ifdef SAPPHIRE
- msgbox MtChimney_Text_1B30C2, 4
+ msgbox MtChimney_Text_1B30C2, MSGBOX_DEFAULT
.else
- msgbox MtChimney_Text_1B3A90, 4
+ msgbox MtChimney_Text_1B3A90, MSGBOX_DEFAULT
.endif
closemessage
delay 30
- fadescreen 1
+ fadescreen FADE_TO_BLACK
removeobject 2
removeobject 3
removeobject 22
setflag FLAG_HIDE_EVIL_TEAM_MT_CHIMNEY
- fadescreen 0
+ fadescreen FADE_FROM_BLACK
setobjectxyperm 1, 10, 12
addobject 1
compare VAR_FACING, 4
call_if_eq MtChimney_EventScript_1B2D7D
compare VAR_FACING, 2
call_if_eq MtChimney_EventScript_1B2D88
- applymovement 255, MtChimney_Movement_1A083F
+ applymovement OBJ_EVENT_ID_PLAYER, Common_Movement_WalkInPlaceFastestLeft
waitmovement 0
.ifdef SAPPHIRE
- msgbox MtChimney_Text_1B3608, 4
+ msgbox MtChimney_Text_1B3608, MSGBOX_DEFAULT
.else
- msgbox MtChimney_Text_1B3FFE, 4
+ msgbox MtChimney_Text_1B3FFE, MSGBOX_DEFAULT
.endif
closemessage
compare VAR_FACING, 4
diff --git a/data/scripts/magma_summit.inc b/data/scripts/magma_summit.inc
index 0992a62c0..403bf2e37 100644
--- a/data/scripts/magma_summit.inc
+++ b/data/scripts/magma_summit.inc
@@ -1,29 +1,29 @@
MtPyre_Summit_EventScript_1B2DA9:: @ 81B2DA9
.ifdef SAPPHIRE
- trainerbattle 0, TRAINER_MT_PYRE_SUMMIT_GRUNT_1, 0, UnknownString_81B50C3, UnknownString_81B50F5
- msgbox UnknownString_81B5131, 6
+ trainerbattle_single TRAINER_MT_PYRE_SUMMIT_GRUNT_1, UnknownString_81B50C3, UnknownString_81B50F5
+ msgbox UnknownString_81B5131, MSGBOX_AUTOCLOSE
.else
- trainerbattle 0, TRAINER_MT_PYRE_SUMMIT_GRUNT_1, 0, MtPyre_Summit_Text_1B5CFD, MtPyre_Summit_Text_1B5D30
- msgbox MtPyre_Summit_Text_1B5D6D, 6
+ trainerbattle_single TRAINER_MT_PYRE_SUMMIT_GRUNT_1, MtPyre_Summit_Text_1B5CFD, MtPyre_Summit_Text_1B5D30
+ msgbox MtPyre_Summit_Text_1B5D6D, MSGBOX_AUTOCLOSE
.endif
end
MtPyre_Summit_EventScript_1B2DC0:: @ 81B2DC0
.ifdef SAPPHIRE
- trainerbattle 0, TRAINER_MT_PYRE_SUMMIT_GRUNT_2, 0, UnknownString_81B5166, UnknownString_81B519F
- msgbox UnknownString_81B51B5, 6
+ trainerbattle_single TRAINER_MT_PYRE_SUMMIT_GRUNT_2, UnknownString_81B5166, UnknownString_81B519F
+ msgbox UnknownString_81B51B5, MSGBOX_AUTOCLOSE
.else
- trainerbattle 0, TRAINER_MT_PYRE_SUMMIT_GRUNT_2, 0, MtPyre_Summit_Text_1B5DA2, MtPyre_Summit_Text_1B5DDB
- msgbox MtPyre_Summit_Text_1B5DF1, 6
+ trainerbattle_single TRAINER_MT_PYRE_SUMMIT_GRUNT_2, MtPyre_Summit_Text_1B5DA2, MtPyre_Summit_Text_1B5DDB
+ msgbox MtPyre_Summit_Text_1B5DF1, MSGBOX_AUTOCLOSE
.endif
end
MtPyre_Summit_EventScript_1B2DD7:: @ 81B2DD7
.ifdef SAPPHIRE
- trainerbattle 0, TRAINER_MT_PYRE_SUMMIT_GRUNT_3, 0, UnknownString_81B51EB, UnknownString_81B5224
- msgbox UnknownString_81B5248, 6
+ trainerbattle_single TRAINER_MT_PYRE_SUMMIT_GRUNT_3, UnknownString_81B51EB, UnknownString_81B5224
+ msgbox UnknownString_81B5248, MSGBOX_AUTOCLOSE
.else
- trainerbattle 0, TRAINER_MT_PYRE_SUMMIT_GRUNT_3, 0, MtPyre_Summit_Text_1B5E27, MtPyre_Summit_Text_1B5E60
- msgbox MtPyre_Summit_Text_1B5E84, 6
+ trainerbattle_single TRAINER_MT_PYRE_SUMMIT_GRUNT_3, MtPyre_Summit_Text_1B5E27, MtPyre_Summit_Text_1B5E60
+ msgbox MtPyre_Summit_Text_1B5E84, MSGBOX_AUTOCLOSE
.endif
end
diff --git a/data/scripts/mauville_man.inc b/data/scripts/mauville_man.inc
index 9e2db94a1..b3a91702b 100644
--- a/data/scripts/mauville_man.inc
+++ b/data/scripts/mauville_man.inc
@@ -34,12 +34,12 @@ yes_hear_song:
compare VAR_RESULT, FALSE
@ Prompt new lyrics only if song hasn't been changed
goto_if_eq prompt_write_lyrics
- msgbox gTextBard_OhWhatAMovingSong, 4
+ msgbox gTextBard_OhWhatAMovingSong, MSGBOX_DEFAULT
release
end
dont_hear_song:
- msgbox gTextBard_OhYouveLeftMe, 4
+ msgbox gTextBard_OhYouveLeftMe, MSGBOX_DEFAULT
release
end
@@ -53,12 +53,12 @@ prompt_write_lyrics:
write_lyrics:
setvar VAR_0x8004, 6
- call MauvilleCity_PokemonCenter_1F_EventScript_1A00F3
+ call Common_EventScript_ShowEasyChatScreen
lock
faceplayer
compare VAR_RESULT, NO
goto_if_eq dont_write_lyrics
- msgbox gTextBard_ThankYouKindly, 4
+ msgbox gTextBard_ThankYouKindly, MSGBOX_DEFAULT
setvar VAR_0x8004, 1
@ Give the player ear rape again
special ScrSpecial_PlayBardSong
@@ -67,12 +67,12 @@ write_lyrics:
compare VAR_RESULT, NO
goto_if_eq write_lyrics @ Keep looping until player responds YES
special ScrSpecial_SaveBardSongLyrics
- msgbox gTextBard_OkayThatsIt, 4
+ msgbox gTextBard_OkayThatsIt, MSGBOX_DEFAULT
release
end
dont_write_lyrics:
- msgbox gTextBard_OhYouveLeftMe2, 4
+ msgbox gTextBard_OhYouveLeftMe2, MSGBOX_DEFAULT
release
end
@@ -85,11 +85,11 @@ SpeakToHipster:
lock
faceplayer
setflag FLAG_SYS_HIPSTER_MEET
- msgbox gTextHipster_TheyCallMeTheHipster, 4
+ msgbox gTextHipster_TheyCallMeTheHipster, MSGBOX_DEFAULT
special ScrSpecial_GetHipsterSpokenFlag
compare VAR_RESULT, FALSE
goto_if_eq hipster_first_time
- msgbox gTextHipster_TaughtYouAlready, 4
+ msgbox gTextHipster_TaughtYouAlready, MSGBOX_DEFAULT
release
end
@@ -97,12 +97,12 @@ hipster_first_time:
special ScrSpecial_HipsterTeachWord
compare VAR_RESULT, TRUE @ TRUE if player learned a new word
goto_if_eq teach_new_word
- msgbox gTextHipster_YouAlreadyKnowALot, 4
+ msgbox gTextHipster_YouAlreadyKnowALot, MSGBOX_DEFAULT
release
end
teach_new_word:
- msgbox gTextHipster_HaveYouHeardAbout, 4
+ msgbox gTextHipster_HaveYouHeardAbout, MSGBOX_DEFAULT
special ScrSpecial_SetHipsterSpokenFlag
release
end
@@ -129,11 +129,11 @@ SpeakToTrader:
end
dont_want_to_trade:
- msgbox gTextTrader_FeelUnwanted1, 2
+ msgbox gTextTrader_FeelUnwanted1, MSGBOX_NPC
end
already_traded:
- msgbox gTextTrader_TradedAlready, 2
+ msgbox gTextTrader_TradedAlready, MSGBOX_NPC
end
do_trader_menu_get:
@@ -153,7 +153,7 @@ do_trader_menu_get:
end
cancelled_get_menu:
- msgbox gTextTrader_DontWantAnything, 2
+ msgbox gTextTrader_DontWantAnything, MSGBOX_NPC
end
rare_item_cant_trade_away:
@@ -169,11 +169,11 @@ dont_want_item:
end
player_has_no_decorations:
- msgbox gTextTrader_YouDontHaveDecorations, 2
+ msgbox gTextTrader_YouDontHaveDecorations, MSGBOX_NPC
end
do_trader_menu_give:
- msgbox gTextTrader_PickDecorationYoullTrade, 4
+ msgbox gTextTrader_PickDecorationYoullTrade, MSGBOX_DEFAULT
special ScrSpecial_TraderMenuGiveDecoration
waitstate
compare VAR_0x8006, 0
@@ -187,20 +187,20 @@ do_trader_menu_give:
compare VAR_RESULT, NO
goto_if_eq do_trader_menu_give
special ScrSpecial_TraderDoDecorationTrade
- msgbox gTextTrader_ThenWellTrade, 2
+ msgbox gTextTrader_ThenWellTrade, MSGBOX_NPC
end
cancelled_give_menu:
- msgbox gTextTrader_FeelUnwanted2, 2
+ msgbox gTextTrader_FeelUnwanted2, MSGBOX_NPC
end
decoration_is_in_use:
- msgbox gTextTrader_InUseYouCantTradeIt, 4
+ msgbox gTextTrader_InUseYouCantTradeIt, MSGBOX_DEFAULT
goto do_trader_menu_give
end
decorations_full:
- msgbox gTextTrader_NoRoomForThis, 2
+ msgbox gTextTrader_NoRoomForThis, MSGBOX_NPC
end
@@ -243,7 +243,7 @@ cancel_story_menu:
goto_if_eq dont_hear_story
goto yes_hear_story
no_stat_update:
- msgbox gTextStoryteller_CouldThereBeOtherTrainers, 4
+ msgbox gTextStoryteller_CouldThereBeOtherTrainers, MSGBOX_DEFAULT
msgbox gTextStoryteller_HearAnotherLegendaryTale, MSGBOX_YESNO
compare VAR_RESULT, YES
goto_if_eq choose_story
@@ -256,7 +256,7 @@ yes_hear_story:
goto_if_eq cant_record_story @ story list is full
goto prompt_record_story
no_stories_recorded:
- msgbox gTextStoryteller_ButIKnowOfNoLegendaryTrainers, 4
+ msgbox gTextStoryteller_ButIKnowOfNoLegendaryTrainers, MSGBOX_DEFAULT
prompt_record_story:
msgbox gTextStoryteller_HaveYouAnyTales, MSGBOX_YESNO
compare VAR_RESULT, NO
@@ -264,25 +264,25 @@ prompt_record_story:
specialvar VAR_RESULT, ScrSpecial_StorytellerInitializeRandomStat
compare VAR_RESULT, TRUE
goto_if_eq stat_update
- msgbox gTextStoryteller_ImNotSatisfied, 4
+ msgbox gTextStoryteller_ImNotSatisfied, MSGBOX_DEFAULT
closemessage
release
end
stat_update:
- msgbox gTextStoryteller_BirthOfANewLegend, 4
+ msgbox gTextStoryteller_BirthOfANewLegend, MSGBOX_DEFAULT
closemessage
release
end
dont_hear_story:
- msgbox gTextStoryteller_OhIFeelStifled, 4
+ msgbox gTextStoryteller_OhIFeelStifled, MSGBOX_DEFAULT
closemessage
release
end
cant_record_story:
- msgbox gTextStoryteller_WishMorePeopleWould, 4
+ msgbox gTextStoryteller_WishMorePeopleWould, MSGBOX_DEFAULT
closemessage
release
end
@@ -321,7 +321,7 @@ tell_another_giddy_tale:
end
also_i_was_thinking:
- msgbox gTextGiddy_AlsoIWasThinking, 4
+ msgbox gTextGiddy_AlsoIWasThinking, MSGBOX_DEFAULT
goto tell_giddy_tale
end
@@ -337,12 +337,12 @@ tell_giddy_tale:
end
dont_hear_giddy:
- msgbox gTextGiddy_YouveDeflatedMe, 4
+ msgbox gTextGiddy_YouveDeflatedMe, MSGBOX_DEFAULT
release
end
bye_bye:
- msgbox gTextGiddy_ByeBye, 4
+ msgbox gTextGiddy_ByeBye, MSGBOX_DEFAULT
release
end
diff --git a/data/scripts/movement.inc b/data/scripts/movement.inc
new file mode 100644
index 000000000..fb2d1ae2c
--- /dev/null
+++ b/data/scripts/movement.inc
@@ -0,0 +1,71 @@
+Common_Movement_QuestionMark:: @ 81A0831
+ emote_question_mark
+ step_end
+
+Common_Movement_ExclamationMark:: @ 81A0833
+ emote_exclamation_mark
+ step_end
+
+Common_Movement_Delay48:: @ 81A0835
+ delay_16
+ delay_16
+ delay_16
+ step_end
+
+Common_Movement_FacePlayer:: @ 81A0839
+ face_player
+ step_end
+
+Common_Movement_FaceAwayPlayer:: @ 81A083B
+ face_away_player
+ step_end
+
+Common_Movement_FaceOriginalDirection:: @ 81A083D
+ face_original_direction
+ step_end
+
+Common_Movement_WalkInPlaceFastestLeft:: @ 81A083F
+ walk_in_place_fastest_left
+ step_end
+
+Common_Movement_WalkInPlaceFastestUp:: @ 81A0841
+ walk_in_place_fastest_up
+ step_end
+
+Common_Movement_WalkInPlaceFastestRight:: @ 81A0843
+ walk_in_place_fastest_right
+ step_end
+
+Common_Movement_WalkInPlaceFastestDown:: @ 81A0845
+ walk_in_place_fastest_down
+ step_end
+
+Common_Movement_WalkUp6:: @ 81A0847
+ walk_up
+ walk_up
+ walk_up
+ walk_up
+ walk_up
+ walk_up
+ step_end
+
+Common_Movement_WalkUp4:: @ 81A084E
+ walk_up
+ walk_up
+ walk_up
+ walk_up
+ step_end
+
+Common_Movement_Delay32:: @ 81A0853
+ delay_16
+ delay_16
+ step_end
+
+Common_Movement_WalkUp:: @ 81A0856
+ walk_up
+ step_end
+
+Common_Movement_WalkUp2:: @ 81A0858
+ walk_up
+ walk_up
+ step_end
diff --git a/data/scripts/mystery_event_club.inc b/data/scripts/mystery_event_club.inc
index 34c546a39..0577cad57 100644
--- a/data/scripts/mystery_event_club.inc
+++ b/data/scripts/mystery_event_club.inc
@@ -2,12 +2,12 @@ PetalburgCity_PokemonCenter_1F_EventScript_1B1B14:: @ 81B1B14
lock
faceplayer
goto_if_set FLAG_SYS_CHAT_USED, PetalburgCity_PokemonCenter_1F_EventScript_1B1BDB
- msgbox PetalburgCity_PokemonCenter_1F_Text_1B1C97, 4
+ msgbox PetalburgCity_PokemonCenter_1F_Text_1B1C97, MSGBOX_DEFAULT
goto PetalburgCity_PokemonCenter_1F_EventScript_1B1B2D
end
PetalburgCity_PokemonCenter_1F_EventScript_1B1B2D:: @ 81B1B2D
- msgbox PetalburgCity_PokemonCenter_1F_Text_1B1D10, 4
+ msgbox PetalburgCity_PokemonCenter_1F_Text_1B1D10, MSGBOX_DEFAULT
multichoice 17, 6, 20, 0
switch VAR_RESULT
case 0, PetalburgCity_PokemonCenter_1F_EventScript_1B1B7A
@@ -17,15 +17,15 @@ PetalburgCity_PokemonCenter_1F_EventScript_1B1B2D:: @ 81B1B2D
end
PetalburgCity_PokemonCenter_1F_EventScript_1B1B6C:: @ 81B1B6C
- msgbox PetalburgCity_PokemonCenter_1F_Text_1B1D3A, 4
+ msgbox PetalburgCity_PokemonCenter_1F_Text_1B1D3A, MSGBOX_DEFAULT
goto PetalburgCity_PokemonCenter_1F_EventScript_1B1B2D
end
PetalburgCity_PokemonCenter_1F_EventScript_1B1B7A:: @ 81B1B7A
- msgbox PetalburgCity_PokemonCenter_1F_Text_1B1F7B, 4
+ msgbox PetalburgCity_PokemonCenter_1F_Text_1B1F7B, MSGBOX_DEFAULT
closemessage
setvar VAR_0x8004, 0
- call PetalburgCity_PokemonCenter_1F_EventScript_1A00F3
+ call Common_EventScript_ShowEasyChatScreen
lock
faceplayer
compare VAR_0x8004, 1
@@ -37,7 +37,7 @@ PetalburgCity_PokemonCenter_1F_EventScript_1B1B7A:: @ 81B1B7A
end
PetalburgCity_PokemonCenter_1F_EventScript_1B1BB1:: @ 81B1BB1
- msgbox PetalburgCity_PokemonCenter_1F_Text_1B1FF0, 4
+ msgbox PetalburgCity_PokemonCenter_1F_Text_1B1FF0, MSGBOX_DEFAULT
release
end
@@ -46,22 +46,22 @@ PetalburgCity_PokemonCenter_1F_EventScript_1B1BBB:: @ 81B1BBB
special sub_80EB7C4
waitmessage
delay 80
- msgbox PetalburgCity_PokemonCenter_1F_Text_1B2137, 4
+ msgbox PetalburgCity_PokemonCenter_1F_Text_1B2137, MSGBOX_DEFAULT
release
end
PetalburgCity_PokemonCenter_1F_EventScript_1B1BD1:: @ 81B1BD1
- msgbox PetalburgCity_PokemonCenter_1F_Text_1B1FA3, 4
+ msgbox PetalburgCity_PokemonCenter_1F_Text_1B1FA3, MSGBOX_DEFAULT
release
end
PetalburgCity_PokemonCenter_1F_EventScript_1B1BDB:: @ 81B1BDB
- msgbox PetalburgCity_PokemonCenter_1F_Text_1B202F, 4
+ msgbox PetalburgCity_PokemonCenter_1F_Text_1B202F, MSGBOX_DEFAULT
goto PetalburgCity_PokemonCenter_1F_EventScript_1B1BE9
end
PetalburgCity_PokemonCenter_1F_EventScript_1B1BE9:: @ 81B1BE9
- msgbox PetalburgCity_PokemonCenter_1F_Text_1B2063, 4
+ msgbox PetalburgCity_PokemonCenter_1F_Text_1B2063, MSGBOX_DEFAULT
multichoice 17, 6, 20, 0
switch VAR_RESULT
case 0, PetalburgCity_PokemonCenter_1F_EventScript_1B1C36
@@ -71,15 +71,15 @@ PetalburgCity_PokemonCenter_1F_EventScript_1B1BE9:: @ 81B1BE9
end
PetalburgCity_PokemonCenter_1F_EventScript_1B1C28:: @ 81B1C28
- msgbox PetalburgCity_PokemonCenter_1F_Text_1B1D3A, 4
+ msgbox PetalburgCity_PokemonCenter_1F_Text_1B1D3A, MSGBOX_DEFAULT
goto PetalburgCity_PokemonCenter_1F_EventScript_1B1BE9
end
PetalburgCity_PokemonCenter_1F_EventScript_1B1C36:: @ 81B1C36
- msgbox PetalburgCity_PokemonCenter_1F_Text_1B207F, 4
+ msgbox PetalburgCity_PokemonCenter_1F_Text_1B207F, MSGBOX_DEFAULT
closemessage
setvar VAR_0x8004, 0
- call PetalburgCity_PokemonCenter_1F_EventScript_1A00F3
+ call Common_EventScript_ShowEasyChatScreen
lock
faceplayer
compare VAR_0x8004, 1
@@ -91,7 +91,7 @@ PetalburgCity_PokemonCenter_1F_EventScript_1B1C36:: @ 81B1C36
end
PetalburgCity_PokemonCenter_1F_EventScript_1B1C6D:: @ 81B1C6D
- msgbox PetalburgCity_PokemonCenter_1F_Text_1B20CE, 4
+ msgbox PetalburgCity_PokemonCenter_1F_Text_1B20CE, MSGBOX_DEFAULT
release
end
@@ -99,7 +99,7 @@ PetalburgCity_PokemonCenter_1F_EventScript_1B1C77:: @ 81B1C77
goto_if_unset FLAG_BADGE05_GET, PetalburgCity_PokemonCenter_1F_EventScript_1B1C96
goto_if_set FLAG_SYS_EXDATA_ENABLE, PetalburgCity_PokemonCenter_1F_EventScript_1B1C96
setflag FLAG_SYS_EXDATA_ENABLE
- msgbox PetalburgCity_PokemonCenter_1F_Text_1B21CC, 3
+ msgbox PetalburgCity_PokemonCenter_1F_Text_1B21CC, MSGBOX_SIGN
release
end
diff --git a/data/scripts/new_game.inc b/data/scripts/new_game.inc
new file mode 100644
index 000000000..f27b43107
--- /dev/null
+++ b/data/scripts/new_game.inc
@@ -0,0 +1,218 @@
+EventScript_ResetAllBerryTrees: @ 19F940
+ setberrytree 2, ITEM_TO_BERRY(ITEM_ORAN_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 1, ITEM_TO_BERRY(ITEM_PECHA_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 11, ITEM_TO_BERRY(ITEM_ORAN_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 13, ITEM_TO_BERRY(ITEM_PECHA_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 4, ITEM_TO_BERRY(ITEM_ORAN_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 76, ITEM_TO_BERRY(ITEM_CHERI_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 8, ITEM_TO_BERRY(ITEM_CHERI_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 10, ITEM_TO_BERRY(ITEM_LEPPA_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 25, ITEM_TO_BERRY(ITEM_PINAP_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 26, ITEM_TO_BERRY(ITEM_CHESTO_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 66, ITEM_TO_BERRY(ITEM_CHESTO_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 67, ITEM_TO_BERRY(ITEM_PINAP_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 69, ITEM_TO_BERRY(ITEM_KELPSY_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 70, ITEM_TO_BERRY(ITEM_KELPSY_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 71, ITEM_TO_BERRY(ITEM_KELPSY_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 55, ITEM_TO_BERRY(ITEM_BLUK_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 56, ITEM_TO_BERRY(ITEM_BLUK_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 5, ITEM_TO_BERRY(ITEM_CHERI_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 6, ITEM_TO_BERRY(ITEM_LEPPA_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 7, ITEM_TO_BERRY(ITEM_CHERI_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 16, ITEM_TO_BERRY(ITEM_NANAB_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 17, ITEM_TO_BERRY(ITEM_NANAB_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 18, ITEM_TO_BERRY(ITEM_NANAB_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 29, ITEM_TO_BERRY(ITEM_WEPEAR_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 28, ITEM_TO_BERRY(ITEM_WEPEAR_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 27, ITEM_TO_BERRY(ITEM_WEPEAR_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 24, ITEM_TO_BERRY(ITEM_RAWST_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 23, ITEM_TO_BERRY(ITEM_PECHA_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 22, ITEM_TO_BERRY(ITEM_PECHA_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 21, ITEM_TO_BERRY(ITEM_RAWST_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 19, ITEM_TO_BERRY(ITEM_RAZZ_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 20, ITEM_TO_BERRY(ITEM_RAZZ_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 80, ITEM_TO_BERRY(ITEM_ORAN_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 81, ITEM_TO_BERRY(ITEM_ORAN_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 77, ITEM_TO_BERRY(ITEM_PERSIM_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 78, ITEM_TO_BERRY(ITEM_PERSIM_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 68, ITEM_TO_BERRY(ITEM_PERSIM_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 31, ITEM_TO_BERRY(ITEM_SITRUS_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 33, ITEM_TO_BERRY(ITEM_SITRUS_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 34, ITEM_TO_BERRY(ITEM_POMEG_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 35, ITEM_TO_BERRY(ITEM_POMEG_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 36, ITEM_TO_BERRY(ITEM_POMEG_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 83, ITEM_TO_BERRY(ITEM_HONDEW_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 84, ITEM_TO_BERRY(ITEM_HONDEW_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 85, ITEM_TO_BERRY(ITEM_SITRUS_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 86, ITEM_TO_BERRY(ITEM_LEPPA_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 37, ITEM_TO_BERRY(ITEM_ASPEAR_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 38, ITEM_TO_BERRY(ITEM_ASPEAR_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 39, ITEM_TO_BERRY(ITEM_ASPEAR_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 40, ITEM_TO_BERRY(ITEM_PECHA_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 41, ITEM_TO_BERRY(ITEM_PECHA_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 42, ITEM_TO_BERRY(ITEM_PECHA_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 46, ITEM_TO_BERRY(ITEM_WEPEAR_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 45, ITEM_TO_BERRY(ITEM_PINAP_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 44, ITEM_TO_BERRY(ITEM_NANAB_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 43, ITEM_TO_BERRY(ITEM_RAZZ_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 47, ITEM_TO_BERRY(ITEM_PERSIM_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 48, ITEM_TO_BERRY(ITEM_ASPEAR_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 49, ITEM_TO_BERRY(ITEM_RAWST_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 50, ITEM_TO_BERRY(ITEM_CHESTO_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 52, ITEM_TO_BERRY(ITEM_NANAB_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 53, ITEM_TO_BERRY(ITEM_NANAB_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 62, ITEM_TO_BERRY(ITEM_LEPPA_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 64, ITEM_TO_BERRY(ITEM_LEPPA_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 58, ITEM_TO_BERRY(ITEM_POMEG_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 59, ITEM_TO_BERRY(ITEM_POMEG_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 60, ITEM_TO_BERRY(ITEM_GREPA_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 61, ITEM_TO_BERRY(ITEM_GREPA_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 79, ITEM_TO_BERRY(ITEM_QUALOT_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 14, ITEM_TO_BERRY(ITEM_QUALOT_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 15, ITEM_TO_BERRY(ITEM_POMEG_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 30, ITEM_TO_BERRY(ITEM_POMEG_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 65, ITEM_TO_BERRY(ITEM_GREPA_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 72, ITEM_TO_BERRY(ITEM_GREPA_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 73, ITEM_TO_BERRY(ITEM_QUALOT_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 74, ITEM_TO_BERRY(ITEM_QUALOT_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 87, ITEM_TO_BERRY(ITEM_PECHA_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 88, ITEM_TO_BERRY(ITEM_SITRUS_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 89, ITEM_TO_BERRY(ITEM_RAWST_BERRY), BERRY_STAGE_BERRIES
+ setberrytree 82, ITEM_TO_BERRY(ITEM_LIECHI_BERRY), BERRY_STAGE_BERRIES
+ return
+
+EventScript_ResetAllMapFlags:: @ 819FA81
+ setflag FLAG_LINK_CONTEST_ROOM_POKEBALL
+ setflag FLAG_HIDE_VICTORIA_WINSTRATE
+ setflag FLAG_HIDE_VIVI_WINSTRATE
+ setflag FLAG_HIDE_VICKI_WINSTRATE
+ setflag FLAG_HIDE_BIRCH_IN_LAB
+ setflag FLAG_HIDE_RIVAL_BIRCH_LAB
+ setflag FLAG_HIDE_WALLY_PETALBURG
+ setflag FLAG_UNKNOWN_363
+ setflag FLAG_HIDE_GRUNT_RUSTBORO
+ setflag FLAG_HIDE_DEVON_RUSTBORO
+ setflag FLAG_HIDE_RIVAL_RUSTBORO
+ setflag FLAG_HIDE_FAT_MAN_LITTLEROOT
+ setflag FLAG_HIDE_MR_BRINEY_ROUTE104_HOUSE
+ setflag FLAG_HIDE_PEEKO_BRINEY_HOUSE
+ setflag FLAG_HIDE_MR_BRINEY_ROUTE104
+ setflag FLAG_HIDE_MR_BRINEY_DEWFORD_TOWN
+ setflag FLAG_HIDE_MR_BRINEY_ROUTE109
+ setflag FLAG_HIDE_MR_BRINEY_BOAT_DEWFORD
+ setflag FLAG_HIDE_MR_BRINEY_BOAT_ROUTE109
+ setflag FLAG_HIDE_FLOWER_SHOP_WORKER_OUTSIDE
+ setflag FLAG_UNKNOWN_2E1
+ setflag FLAG_UNKNOWN_2EB
+ setflag FLAG_UNKNOWN_2EC
+ setflag FLAG_UNKNOWN_2ED
+ setflag FLAG_UNKNOWN_2F4
+ setflag FLAG_HIDE_LILYCOVE_CONTEST_ATTENDENT_1
+ setflag FLAG_HIDE_ARTIST_LILCOVE_CONTEST
+ setflag FLAG_HIDE_LILYCOVE_MUSEUM_PAINTING_LADY
+ setflag FLAG_HIDE_LILYCOVE_MUSEUM_PAINTING_GIRL
+ setflag FLAG_HIDE_LILYCOVE_MUSEUM_PAINTING_MAN
+ setflag FLAG_HIDE_LILYCOVE_MUSEUM_PAINTER
+ setflag FLAG_HIDE_LILYCOVE_MUSEUM_VISITORS
+ setflag FLAG_HIDE_PETALBURG_GYM_GUIDE
+ setflag FLAG_UNKNOWN_30E
+ setflag FLAG_UNKNOWN_30F
+ setflag FLAG_HIDE_NORMAN_LITTLEROOT
+ setflag FLAG_HIDE_MAY_PICHU_DOLL
+ setflag FLAG_HIDE_FANCLUB_OLD_LADY
+ setflag FLAG_HIDE_FANCLUB_BOY
+ setflag FLAG_HIDE_FANCLUB_LITTLE_BOY
+ setflag FLAG_HIDE_FANCLUB_LADY
+ setflag FLAG_HIDE_GABBY_AND_TY_ROUTE118_1
+ setflag FLAG_HIDE_GABBY_AND_TY_ROUTE120_1
+ setflag FLAG_HIDE_GABBY_AND_TY_ROUTE111_2
+ setflag FLAG_HIDE_GABBY_AND_TY_ROUTE118_2
+ setflag FLAG_HIDE_GABBY_AND_TY_ROUTE120_2
+ setflag FLAG_HIDE_GABBY_AND_TY_ROUTE111_3
+ setflag FLAG_HIDE_GABBY_AND_TY_ROUTE118_3
+ setflag FLAG_HIDE_CONTEST_REPORTER_FALLARBOR
+ setflag FLAG_HIDE_CONTEST_REPORTER_VERDANTURF
+ setflag FLAG_HIDE_CONTEST_REPORTER_SLATEPORT
+ setflag FLAG_HIDE_CONTEST_REPORTER_LILYCOVE
+ setflag FLAG_HIDE_WALLY_WANDAS_HOUSE
+ setflag FLAG_HIDE_BOYFRIEND_WANDAS_HOUSE
+ setflag FLAG_HIDE_WALLY_FATHER_WANDAS_HOUSE
+ setflag FLAG_HIDE_GIRLFRIEND_WANDAS_HOUSE
+ setflag FLAG_HIDE_WALLY_FATHER_PETALBURG
+ setflag FLAG_HIDE_WALLY_MOTHER_PETALBURG
+ setflag FLAG_HIDE_WALLY_PETALBURG_GYM
+ setflag FLAG_HIDE_WALLACE_SOOTOPOLIS_GYM
+ setflag FLAG_HIDE_WALLACE_SOOTOPOLIS
+ setflag FLAG_HIDE_BRINEY_SLATEPORT_SHIPYARD
+ setflag FLAG_UNKNOWN_337
+ setflag FLAG_HIDE_EVIL_LEADER_SEAFLOOR_CAVERN
+ setflag FLAG_HIDE_OTHER_LEADER_SEAFLOOR_CAVERN
+ setflag FLAG_HIDE_OTHER_TEAM_GRUNTS_SEAFLOOR_CAVERN
+ setflag FLAG_HIDE_AWAKENED_MON_SEAFLOOR_CAVERN
+ setflag FLAG_HIDE_STERN_SLATEPORT_HARBOR
+ setflag FLAG_UNKNOWN_34B
+ setflag FLAG_UNKNOWN_34C
+ setflag FLAG_UNKNOWN_34F
+ setflag FLAG_HIDE_GRUNT_1_SLATEPORT_HARBOR
+ setflag FLAG_HIDE_GRUNT_2_SLATEPORT_HARBOR
+ setflag FLAG_HIDE_SS_TIDAL_SLATEPORT_HARBOR
+ setflag FLAG_HIDE_SS_TIDAL_LILYCOVE_HARBOR
+ setflag FLAG_HIDE_GABBY_AND_TY_SLATEPORT
+ setflag FLAG_HIDE_STERN_SLATEPORT
+ setflag FLAG_HIDE_SUBMARINE_SHADOW_SLATEPORT_HARBOR
+ setflag FLAG_HIDE_RIVAL_ROUTE119
+ setflag FLAG_HIDE_CAVE_OF_ORIGIN_ENTRANCE_WOMAN_1
+ setflag FLAG_HIDE_CAVE_OF_ORIGIN_ENTRANCE_WOMAN_2
+ setflag FLAG_HIDE_STEVEN_SOOTOPOLIS
+ setflag FLAG_HIDE_LANETTE
+ setflag FLAG_HIDE_TRICKMASTER_ENTRANCE
+ setflag FLAG_HIDE_MT_CHIMNEY_PEOPLE
+ setflag FLAG_HIDE_BRINEY_RUSTURF_TUNNEL
+ setflag FLAG_HIDE_BRINEY_ROUTE116
+ setflag FLAG_HIDE_PEEKO_RUSTURF_TUNNEL
+ setflag FLAG_HIDE_GRUNT_RUSTURF_TUNNEL
+ setflag FLAG_HIDE_BOYFRIEND_RUSTURF_TUNNEL
+ setflag FLAG_HIDE_GIRLFRIEND_RUSTURF_TUNNEL
+ setflag FLAG_HIDE_EVIL_TEAM_LEADER_OCEANIC_MUSEUM_2F
+ setflag FLAG_HIDE_GRUNT_1_OCEANIC_MUSEUM_2F
+ setflag FLAG_HIDE_GRUNT_2_OCEANIC_MUSEUM_2F
+ setflag FLAG_HIDE_OCEANIC_MUSEUM_VISITORS
+ setflag FLAG_HIDE_BATTLE_TOWER_OPPONENT
+ setflag FLAG_HIDE_AWARD_MAN_BATTLE_TOWER
+ setflag FLAG_HIDE_MOM_LITTLEROOT
+ setflag FLAG_HIDE_MOM_UPSTAIRS
+ setflag FLAG_HIDE_WEATHER_INSTITUTE_WORKERS_1F
+ setflag FLAG_UNKNOWN_BIRCH_380
+ setflag FLAG_HIDE_BIRCH_ROUTE101
+ setflag FLAG_HIDE_BIRCH_ROUTE103
+ setflag FLAG_HIDE_FERRY_SAILOR_LILYCOVE
+ setflag FLAG_HIDE_LATIOS_OR_LATIAS_FLYING
+ setflag FLAG_HIDE_LATIOS_OR_LATIAS_STATIONARY
+ setflag FLAG_UNKNOWN_393
+ setflag FLAG_HIDE_WATTSON_MAUVILLE
+ setflag FLAG_HIDE_RIVAL_CHAMPIONS_ROOM
+ setflag FLAG_HIDE_BIRCH_CHAMPIONS_ROOM
+ setflag FLAG_HIDE_RIVAL_ON_BIKE_ROUTE110
+ setflag FLAG_HIDE_RIVAL_ROUTE119_ON_BIKE
+ setflag FLAG_HIDE_LILYCOVE_MOTEL_PEOPLE
+ setflag FLAG_HIDE_RIVAL_LAVARIDGE_1
+ setflag FLAG_HIDE_RIVAL_LAVARIDGE_2
+ setflag FLAG_HIDE_WINGULL_MOSSDEEP_HOUSE
+ setflag FLAG_HIDE_OTHER_TEAM_METEOR_FALLS_1F
+ setflag FLAG_HIDE_SLUDGE_BOMB_MAN_DEWFORD_HALL
+ setflag FLAG_HIDE_PROF_COSMO_FALLARBOR
+ setflag FLAG_HIDE_STEVEN_ROUTE128
+ setflag FLAG_HIDE_EVIL_LEADER_ROUTE128
+ setflag FLAG_HIDE_OTHER_LEADER_ROUTE128
+ setflag FLAG_HIDE_DEVON_EMPLOYEE_ROUTE116
+ setflag FLAG_HIDE_TM_SALESMAN_SLATEPORT
+ setflag FLAG_HIDE_WALLY_BATTLE_VICTORY_ROAD
+ setflag FLAG_HIDE_BRINEY_AND_PEEKO_SS_TIDAL
+ setflag FLAG_HIDE_BELDUM_BALL_STEVENS_HOUSE
+ setflag FLAG_ITEM_MOSSDEEP_STEVENS_HOUSE_HM08
+ setflag FLAG_HIDE_STEVENS_LETTER
+ setflag FLAG_HIDE_RIVAL_OLDALE_TOWN
+ setflag FLAG_HIDE_WALLY_DEFEATED_VICTORY_ROAD
+ setflag FLAG_HIDE_BOY_ROUTE101
+ call EventScript_ResetAllBerryTrees
+ end
diff --git a/data/scripts/obtain_item.inc b/data/scripts/obtain_item.inc
new file mode 100644
index 000000000..2be28646e
--- /dev/null
+++ b/data/scripts/obtain_item.inc
@@ -0,0 +1,161 @@
+Std_ObtainItem: @ 819FDF7
+ additem VAR_0x8000, VAR_0x8001
+ copyvar VAR_0x8007, VAR_RESULT
+ call EventScript_ObtainItemMessage
+ return
+
+EventScript_ObtainItemMessage: @ 819FE07
+ bufferitemname 1, VAR_0x8000
+ checkitemtype VAR_0x8000
+ call EventScript_BufferPocketNameAndTryFanfare
+ compare VAR_0x8007, TRUE
+ call_if_eq EventScript_ObtainedItem
+ compare VAR_0x8007, FALSE
+ call_if_eq EventScript_NoRoomForItem
+ return
+
+EventScript_BufferPocketNameAndTryFanfare:
+ switch VAR_RESULT
+ case POCKET_ITEMS, EventScript_BufferItemsPocket
+ case POCKET_KEY_ITEMS, EventScript_BufferKeyItemsPocket
+ case POCKET_POKE_BALLS, EventScript_BufferPokeballsPocket
+ case POCKET_TM_HM, EventScript_BufferTMHMsPocket
+ case POCKET_BERRIES, EventScript_BufferBerriesPocket
+ end
+
+EventScript_BufferItemsPocket:
+ bufferstdstring 2, STDSTRING_ITEMS
+ compare VAR_0x8007, TRUE
+ call_if_eq EventScript_PlayFanfareObtainedItem
+ return
+
+EventScript_BufferKeyItemsPocket:
+ bufferstdstring 2, STDSTRING_KEYITEMS
+ compare VAR_0x8007, TRUE
+ call_if_eq EventScript_PlayFanfareObtainedItem
+ return
+
+EventScript_BufferPokeballsPocket:
+ bufferstdstring 2, STDSTRING_POKEBALLS
+ compare VAR_0x8007, TRUE
+ call_if_eq EventScript_PlayFanfareObtainedItem
+ return
+
+EventScript_BufferTMHMsPocket:
+ bufferstdstring 2, STDSTRING_TMHMS
+ compare VAR_0x8007, TRUE
+ call_if_eq EventScript_PlayFanfareObtainedTMHM
+ return
+
+EventScript_BufferBerriesPocket:
+ bufferstdstring 2, STDSTRING_BERRIES
+ compare VAR_0x8007, TRUE
+ call_if_eq EventScript_PlayFanfareObtainedItem
+ return
+
+EventScript_ObtainedItem: @ 819FEB7
+ message Text_ObtainedTheItem
+ waitfanfare
+ waitmessage
+ msgbox Text_PutItemInPocket
+ setvar VAR_RESULT, TRUE
+ return
+
+EventScript_NoRoomForItem: @ 819FECC
+ setvar VAR_RESULT, FALSE
+ return
+
+EventScript_PlayFanfareObtainedItem:
+ playfanfare MUS_FANFA4
+ return
+
+EventScript_PlayFanfareObtainedTMHM:
+ playfanfare MUS_ME_WAZA
+ return
+
+Std_ObtainDecoration: @ 819FEDA
+ adddecoration VAR_0x8000
+ copyvar VAR_0x8007, VAR_RESULT
+ call EventScript_ObtainDecorationMessage
+ return
+
+EventScript_ObtainDecorationMessage: @ 819FEE8
+ bufferdecorationname 1, VAR_0x8000
+ compare VAR_0x8007, TRUE
+ call_if_eq EventScript_ObtainedDecor
+ compare VAR_0x8007, FALSE
+ call_if_eq EventScript_NoRoomForDecor
+ return
+
+EventScript_ObtainedDecor: @ 819FF03
+ playfanfare MUS_FANFA4
+ message Text_ObtainedTheDecor
+ waitfanfare
+ waitmessage
+ msgbox Text_TheDecorWasTransferredToThePC
+ setvar VAR_RESULT, TRUE
+ return
+
+EventScript_NoRoomForDecor: @ 819FF1B
+ setvar VAR_RESULT, FALSE
+ return
+
+Std_FindItem: @ 819FF21
+ lock
+ faceplayer
+ waitse
+ additem VAR_0x8000, VAR_0x8001
+ copyvar VAR_0x8007, VAR_RESULT
+ bufferitemname 1, VAR_0x8000
+ checkitemtype VAR_0x8000
+ call EventScript_BufferPocketNameAndTryFanfare
+ compare VAR_0x8007, TRUE
+ call_if_eq EventScript_PickUpItem
+ compare VAR_0x8007, FALSE
+ call_if_eq EventScript_NoRoomToPickUpItem
+ release
+ return
+
+EventScript_PickUpItem: @ 819FF52
+ removeobject VAR_LAST_TALKED
+ message Text_FoundOneItem
+ waitfanfare
+ waitmessage
+ msgbox Text_PutItemInPocket
+ return
+
+EventScript_NoRoomToPickUpItem: @ 819FF65
+ msgbox Text_ObtainedTheItem
+ msgbox Text_TooBadBagIsFull
+ setvar VAR_RESULT, FALSE
+ return
+
+EventScript_HiddenItem:: @ 819FF7B
+ lockall
+ waitse
+ additem VAR_0x8005
+ copyvar VAR_0x8007, VAR_RESULT
+ bufferitemname 1, VAR_0x8005
+ checkitemtype VAR_0x8005
+ call EventScript_BufferPocketNameAndTryFanfare
+ compare VAR_0x8007, TRUE
+ goto_if_eq EventScript_PickUpHiddenItem
+ compare VAR_0x8007, FALSE
+ goto_if_eq EventScript_NoRoomToPickUpHiddenItem
+ end
+
+EventScript_PickUpHiddenItem:
+ message Text_FoundOneItem
+ waitfanfare
+ waitmessage
+ msgbox Text_PutItemInPocket
+ special SetHiddenItemFlag
+ releaseall
+ end
+
+EventScript_NoRoomToPickUpHiddenItem:
+ msgbox Text_FoundOneItem
+ msgbox Text_TooBadBagIsFull
+ setvar VAR_RESULT, FALSE
+ releaseall
+ end
diff --git a/data/scripts/pc.inc b/data/scripts/pc.inc
new file mode 100644
index 000000000..91b47004d
--- /dev/null
+++ b/data/scripts/pc.inc
@@ -0,0 +1,66 @@
+EventScript_PC:: @ 81A0009
+ lockall
+ setvar VAR_0x8004, 0
+ special DoPCTurnOnEffect
+ playse SE_PC_ON
+ msgbox Text_BootUpPC, MSGBOX_DEFAULT
+ goto EventScript_PCMainMenu
+ end
+
+EventScript_PCMainMenu:
+ message Text_WhichPCShouldBeAccessed
+ waitmessage
+ special ScriptMenu_CreatePCMultichoice
+ waitstate
+ goto EventScript_AccessPC
+ end
+
+EventScript_AccessPC:
+ switch VAR_RESULT
+ case 0, EventScript_AccessPokemonStorage
+ case 1, EventScript_AccessPlayersPC
+ case 2, EventScript_AccessHallOfFame
+ case 3, EventScript_TurnOffPC
+ case MULTI_B_PRESSED, EventScript_TurnOffPC
+ end
+
+EventScript_AccessPlayersPC:
+ playse SE_PC_LOGON
+ msgbox Text_AccessedPlayersPC, MSGBOX_DEFAULT
+ special PlayerPC
+ waitstate
+ goto EventScript_PCMainMenu
+ end
+
+EventScript_AccessPokemonStorage:
+ playse SE_PC_LOGON
+ call_if_unset FLAG_SYS_PC_LANETTE, EventScript_AccessSomeonesPC
+ call_if_set FLAG_SYS_PC_LANETTE, EventScript_AccessLanettesPC
+ msgbox Text_StorageSystemOpened, MSGBOX_DEFAULT
+ special ShowPokemonStorageSystem
+ waitstate
+ goto EventScript_PCMainMenu
+ end
+
+EventScript_AccessSomeonesPC:
+ msgbox Text_AccessedSomeonesPC, MSGBOX_DEFAULT
+ return
+
+EventScript_AccessLanettesPC:
+ msgbox Text_AccessedLanettesPC, MSGBOX_DEFAULT
+ return
+
+EventScript_TurnOffPC:
+ setvar VAR_0x8004, 0
+ playse SE_PC_OFF
+ special DoPCTurnOffEffect
+ releaseall
+ end
+
+EventScript_AccessHallOfFame:
+ goto_if_unset FLAG_SYS_GAME_CLEAR, EventScript_TurnOffPC
+ playse SE_PC_LOGON
+ special AccessHallOfFamePC
+ waitstate
+ goto EventScript_AccessPC
+ end
diff --git a/data/scripts/pkmn_center_nurse.inc b/data/scripts/pkmn_center_nurse.inc
new file mode 100644
index 000000000..79359ae55
--- /dev/null
+++ b/data/scripts/pkmn_center_nurse.inc
@@ -0,0 +1,57 @@
+Common_EventScript_PkmnCenterNurse:: @ 819FD5B
+ lock
+ faceplayer
+ msgbox gText_NurseJoy_Welcome, MSGBOX_YESNO
+ compare VAR_RESULT, YES
+ goto_if_eq EventScript_PkmnCenterNurse_HealPkmn
+ compare VAR_RESULT, NO
+ goto_if_eq EventScript_PkmnCenterNurse_Goodbye
+ end
+
+EventScript_PkmnCenterNurse_HealPkmn:: @ 819FD7C
+ incrementgamestat GAME_STAT_USED_POKECENTER
+ message gText_NurseJoy_OkayIllTakeYourPokemon
+ waitmessage
+ applymovement VAR_0x800B, Common_Movement_WalkInPlaceFastestLeft
+ waitmovement 0
+ dofieldeffect FLDEFF_POKECENTER_HEAL
+ waitfieldeffect FLDEFF_POKECENTER_HEAL
+ applymovement VAR_0x800B, Common_Movement_WalkInPlaceFastestDown
+ waitmovement 0
+ special ScrSpecial_HealPlayerParty
+ goto_if_unset FLAG_POKERUS_EXPLAINED, EventScript_PkmnCenterNurse_CheckPokerus
+ goto EventScript_PkmnCenterNurse_ReturnPkmn
+ end
+
+EventScript_PkmnCenterNurse_ReturnPkmn:: @ 819FDB0
+ message gText_NurseJoy_ThankYouForWaiting
+ waitmessage
+ applymovement VAR_0x800B, Movement_PkmnCenterNurse_Bow
+ waitmovement 0
+ message gText_NurseJoy_WeHopeToSeeYouAgain
+ waitmessage
+ return
+
+EventScript_PkmnCenterNurse_Goodbye:: @ 819FDC7
+ message gText_NurseJoy_WeHopeToSeeYouAgain
+ waitmessage
+ return
+
+EventScript_PkmnCenterNurse_CheckPokerus:: @ 819FDCE
+ specialvar VAR_RESULT, IsPokerusInParty
+ compare VAR_RESULT, TRUE
+ goto_if_eq EventScript_PkmnCenterNurse_ExplainPokerus
+ compare VAR_RESULT, FALSE
+ goto_if_eq EventScript_PkmnCenterNurse_ReturnPkmn
+ end
+
+EventScript_PkmnCenterNurse_ExplainPokerus:: @ 819FDEA
+ message gText_NurseJoy_Pokerus
+ waitmessage
+ setflag FLAG_POKERUS_EXPLAINED
+ return
+
+Movement_PkmnCenterNurse_Bow:: @ 819FDF4
+ nurse_joy_bow
+ delay_4
+ step_end
diff --git a/data/scripts/players_house.inc b/data/scripts/players_house.inc
index a4de5d113..2b746dbe0 100644
--- a/data/scripts/players_house.inc
+++ b/data/scripts/players_house.inc
@@ -5,42 +5,42 @@ LittlerootTown_MaysHouse_2F_EventScript_1B6950:: @ 81B6950
LittlerootTown_BrendansHouse_1F_EventScript_1B6956:: @ 81B6956
LittlerootTown_MaysHouse_1F_EventScript_1B6956:: @ 81B6956
- msgbox LittlerootTown_BrendansHouse_1F_Text_172429, 4
- applymovement VAR_0x8004, LittlerootTown_BrendansHouse_1F_Movement_1A0839
+ msgbox LittlerootTown_BrendansHouse_1F_Text_172429, MSGBOX_DEFAULT
+ applymovement VAR_0x8004, Common_Movement_FacePlayer
waitmovement 0
compare VAR_0x8005, 0
call_if_eq LittlerootTown_BrendansHouse_1F_EventScript_1B699F
compare VAR_0x8005, 1
call_if_eq LittlerootTown_BrendansHouse_1F_EventScript_1B69AA
- msgbox LittlerootTown_BrendansHouse_1F_Text_172453, 4
+ msgbox LittlerootTown_BrendansHouse_1F_Text_172453, MSGBOX_DEFAULT
closemessage
setvar VAR_LITTLEROOT_INTRO_STATE, 4
- applymovement 255, LittlerootTown_BrendansHouse_1F_Movement_1B69B5
- applymovement VAR_0x8004, LittlerootTown_BrendansHouse_1F_Movement_1A0841
+ applymovement OBJ_EVENT_ID_PLAYER, LittlerootTown_BrendansHouse_1F_Movement_1B69B5
+ applymovement VAR_0x8004, Common_Movement_WalkInPlaceFastestUp
waitmovement 0
releaseall
end
LittlerootTown_BrendansHouse_1F_EventScript_1B699F:: @ 81B699F
- applymovement 255, LittlerootTown_BrendansHouse_1F_Movement_1A0843
+ applymovement OBJ_EVENT_ID_PLAYER, Common_Movement_WalkInPlaceFastestRight
waitmovement 0
return
LittlerootTown_BrendansHouse_1F_EventScript_1B69AA:: @ 81B69AA
- applymovement 255, LittlerootTown_BrendansHouse_1F_Movement_1A083F
+ applymovement OBJ_EVENT_ID_PLAYER, Common_Movement_WalkInPlaceFastestLeft
waitmovement 0
return
LittlerootTown_BrendansHouse_1F_Movement_1B69B5:: @ 81B69B5
walk_up
- end_movement
+ step_end
LittlerootTown_BrendansHouse_1F_EventScript_1B69B7:: @ 81B69B7
LittlerootTown_MaysHouse_1F_EventScript_1B69B7:: @ 81B69B7
- msgbox LittlerootTown_BrendansHouse_1F_Text_172531, 4
+ msgbox LittlerootTown_BrendansHouse_1F_Text_172531, MSGBOX_DEFAULT
closemessage
- applymovement VAR_0x8004, LittlerootTown_BrendansHouse_1F_Movement_1A0841
- applymovement 255, LittlerootTown_BrendansHouse_1F_Movement_1B6CDC
+ applymovement VAR_0x8004, Common_Movement_WalkInPlaceFastestUp
+ applymovement OBJ_EVENT_ID_PLAYER, LittlerootTown_BrendansHouse_1F_Movement_1B6CDC
waitmovement 0
releaseall
end
@@ -60,7 +60,7 @@ LittlerootTown_MaysHouse_2F_EventScript_1B69DF:: @ 81B69DF
LittlerootTown_BrendansHouse_2F_EventScript_1B69EB:: @ 81B69EB
LittlerootTown_MaysHouse_2F_EventScript_1B69EB:: @ 81B69EB
goto_if_set FLAG_SET_WALL_CLOCK, LittlerootTown_BrendansHouse_2F_EventScript_1B6A91
- msgbox LittlerootTown_BrendansHouse_2F_Text_172E18, 4
+ msgbox LittlerootTown_BrendansHouse_2F_Text_172E18, MSGBOX_DEFAULT
call LittlerootTown_BrendansHouse_2F_EventScript_1B6A9B
delay 30
setvar VAR_LITTLEROOT_INTRO_STATE, 6
@@ -82,9 +82,9 @@ LittlerootTown_BrendansHouse_2F_EventScript_1B6A31:: @ 81B6A31
addobject VAR_0x8008
applymovement VAR_0x8008, LittlerootTown_BrendansHouse_2F_Movement_1B6AA2
waitmovement 0
- applymovement 255, LittlerootTown_BrendansHouse_2F_Movement_1A0843
+ applymovement OBJ_EVENT_ID_PLAYER, Common_Movement_WalkInPlaceFastestRight
waitmovement 0
- msgbox LittlerootTown_BrendansHouse_2F_Text_172E4C, 4
+ msgbox LittlerootTown_BrendansHouse_2F_Text_172E4C, MSGBOX_DEFAULT
closemessage
applymovement VAR_0x8008, LittlerootTown_BrendansHouse_2F_Movement_1B6AA9
waitmovement 0
@@ -95,9 +95,9 @@ LittlerootTown_BrendansHouse_2F_EventScript_1B6A61:: @ 81B6A61
addobject VAR_0x8008
applymovement VAR_0x8008, LittlerootTown_BrendansHouse_2F_Movement_1B6AAD
waitmovement 0
- applymovement 255, LittlerootTown_BrendansHouse_2F_Movement_1A083F
+ applymovement OBJ_EVENT_ID_PLAYER, Common_Movement_WalkInPlaceFastestLeft
waitmovement 0
- msgbox LittlerootTown_BrendansHouse_2F_Text_172E4C, 4
+ msgbox LittlerootTown_BrendansHouse_2F_Text_172E4C, MSGBOX_DEFAULT
closemessage
applymovement VAR_0x8008, LittlerootTown_BrendansHouse_2F_Movement_1B6AB4
waitmovement 0
@@ -105,14 +105,14 @@ LittlerootTown_BrendansHouse_2F_EventScript_1B6A61:: @ 81B6A61
LittlerootTown_BrendansHouse_2F_EventScript_1B6A91:: @ 81B6A91
incrementgamestat GAME_STAT_CHECKED_CLOCK
- fadescreen 1
+ fadescreen FADE_TO_BLACK
special ScrSpecial_ViewWallClock
waitstate
releaseall
end
LittlerootTown_BrendansHouse_2F_EventScript_1B6A9B:: @ 81B6A9B
- fadescreen 1
+ fadescreen FADE_TO_BLACK
special StartWallClock
waitstate
return
@@ -124,13 +124,13 @@ LittlerootTown_BrendansHouse_2F_Movement_1B6AA2:: @ 81B6AA2
delay_16
delay_8
walk_left
- end_movement
+ step_end
LittlerootTown_BrendansHouse_2F_Movement_1B6AA9:: @ 81B6AA9
walk_right
walk_up
delay_8
- end_movement
+ step_end
LittlerootTown_BrendansHouse_2F_Movement_1B6AAD:: @ 81B6AAD
delay_8
@@ -139,13 +139,13 @@ LittlerootTown_BrendansHouse_2F_Movement_1B6AAD:: @ 81B6AAD
delay_16
delay_8
walk_right
- end_movement
+ step_end
LittlerootTown_BrendansHouse_2F_Movement_1B6AB4:: @ 81B6AB4
walk_left
walk_up
delay_8
- end_movement
+ step_end
LittlerootTown_BrendansHouse_1F_EventScript_1B6AB8:: @ 81B6AB8
LittlerootTown_MaysHouse_1F_EventScript_1B6AB8:: @ 81B6AB8
@@ -154,23 +154,23 @@ LittlerootTown_MaysHouse_1F_EventScript_1B6AB8:: @ 81B6AB8
end
LittlerootTown_BrendansHouse_1F_EventScript_1B6ABF:: @ 81B6ABF
- applymovement VAR_0x8005, LittlerootTown_BrendansHouse_1F_Movement_1A0843
+ applymovement VAR_0x8005, Common_Movement_WalkInPlaceFastestRight
waitmovement 0
call LittlerootTown_BrendansHouse_1F_EventScript_1B6B9D
- applymovement 255, LittlerootTown_BrendansHouse_1F_Movement_1B6CCC
+ applymovement OBJ_EVENT_ID_PLAYER, LittlerootTown_BrendansHouse_1F_Movement_1B6CCC
waitmovement 0
playbgm MUS_INTER_V, FALSE
- msgbox LittlerootTown_BrendansHouse_1F_Text_1725C9, 4
+ msgbox LittlerootTown_BrendansHouse_1F_Text_1725C9, MSGBOX_DEFAULT
closemessage
applymovement VAR_0x8005, LittlerootTown_BrendansHouse_1F_Movement_1B6BDB
waitmovement 0
- applymovement 255, LittlerootTown_BrendansHouse_1F_Movement_1B6CD2
+ applymovement OBJ_EVENT_ID_PLAYER, LittlerootTown_BrendansHouse_1F_Movement_1B6CD2
waitmovement 0
call LittlerootTown_BrendansHouse_1F_EventScript_1B6BBE
- applymovement 255, LittlerootTown_BrendansHouse_1F_Movement_1A083F
+ applymovement OBJ_EVENT_ID_PLAYER, Common_Movement_WalkInPlaceFastestLeft
waitmovement 0
- msgbox LittlerootTown_BrendansHouse_1F_Text_1725FE, 4
- msgbox LittlerootTown_BrendansHouse_1F_Text_172644, 4
+ msgbox LittlerootTown_BrendansHouse_1F_Text_1725FE, MSGBOX_DEFAULT
+ msgbox LittlerootTown_BrendansHouse_1F_Text_172644, MSGBOX_DEFAULT
closemessage
setvar VAR_TEMP_1, 1
applymovement VAR_0x8005, LittlerootTown_BrendansHouse_1F_Movement_1B6BE1
@@ -179,23 +179,23 @@ LittlerootTown_BrendansHouse_1F_EventScript_1B6ABF:: @ 81B6ABF
end
LittlerootTown_MaysHouse_1F_EventScript_1B6B2E:: @ 81B6B2E
- applymovement VAR_0x8005, LittlerootTown_MaysHouse_1F_Movement_1A083F
+ applymovement VAR_0x8005, Common_Movement_WalkInPlaceFastestLeft
waitmovement 0
call LittlerootTown_MaysHouse_1F_EventScript_1B6B9D
- applymovement 255, LittlerootTown_MaysHouse_1F_Movement_1B6CD4
+ applymovement OBJ_EVENT_ID_PLAYER, LittlerootTown_MaysHouse_1F_Movement_1B6CD4
waitmovement 0
playbgm MUS_INTER_V, FALSE
- msgbox LittlerootTown_MaysHouse_1F_Text_1725C9, 4
+ msgbox LittlerootTown_MaysHouse_1F_Text_1725C9, MSGBOX_DEFAULT
closemessage
applymovement VAR_0x8005, LittlerootTown_MaysHouse_1F_Movement_1B6BDE
waitmovement 0
- applymovement 255, LittlerootTown_MaysHouse_1F_Movement_1B6CDA
+ applymovement OBJ_EVENT_ID_PLAYER, LittlerootTown_MaysHouse_1F_Movement_1B6CDA
waitmovement 0
call LittlerootTown_MaysHouse_1F_EventScript_1B6BBE
- applymovement 255, LittlerootTown_MaysHouse_1F_Movement_1A0843
+ applymovement OBJ_EVENT_ID_PLAYER, Common_Movement_WalkInPlaceFastestRight
waitmovement 0
- msgbox LittlerootTown_MaysHouse_1F_Text_1725FE, 4
- msgbox LittlerootTown_MaysHouse_1F_Text_172644, 4
+ msgbox LittlerootTown_MaysHouse_1F_Text_1725FE, MSGBOX_DEFAULT
+ msgbox LittlerootTown_MaysHouse_1F_Text_172644, MSGBOX_DEFAULT
closemessage
setvar VAR_TEMP_1, 1
applymovement VAR_0x8005, LittlerootTown_MaysHouse_1F_Movement_1B6BE5
@@ -206,19 +206,19 @@ LittlerootTown_MaysHouse_1F_EventScript_1B6B2E:: @ 81B6B2E
LittlerootTown_BrendansHouse_1F_EventScript_1B6B9D:: @ 81B6B9D
LittlerootTown_MaysHouse_1F_EventScript_1B6B9D:: @ 81B6B9D
playse SE_PIN
- applymovement VAR_0x8005, LittlerootTown_BrendansHouse_1F_Movement_1A0833
+ applymovement VAR_0x8005, Common_Movement_ExclamationMark
waitmovement 0
- applymovement VAR_0x8005, LittlerootTown_BrendansHouse_1F_Movement_1A0835
+ applymovement VAR_0x8005, Common_Movement_Delay48
waitmovement 0
- msgbox LittlerootTown_BrendansHouse_1F_Text_1725A3, 4
+ msgbox LittlerootTown_BrendansHouse_1F_Text_1725A3, MSGBOX_DEFAULT
closemessage
return
LittlerootTown_BrendansHouse_1F_EventScript_1B6BBE:: @ 81B6BBE
LittlerootTown_MaysHouse_1F_EventScript_1B6BBE:: @ 81B6BBE
- applymovement 255, LittlerootTown_BrendansHouse_1F_Movement_1A0841
+ applymovement OBJ_EVENT_ID_PLAYER, Common_Movement_WalkInPlaceFastestUp
waitmovement 0
- msgbox LittlerootTown_BrendansHouse_1F_Text_172841, 4
+ msgbox LittlerootTown_BrendansHouse_1F_Text_172841, MSGBOX_DEFAULT
fadedefaultbgm
special TurnOffTVScreen
setflag FLAG_SYS_TV_HOME
@@ -228,24 +228,24 @@ LittlerootTown_MaysHouse_1F_EventScript_1B6BBE:: @ 81B6BBE
LittlerootTown_BrendansHouse_1F_Movement_1B6BDB:: @ 81B6BDB
walk_left
walk_in_place_fastest_right
- end_movement
+ step_end
LittlerootTown_MaysHouse_1F_Movement_1B6BDE:: @ 81B6BDE
walk_right
walk_in_place_fastest_left
- end_movement
+ step_end
LittlerootTown_BrendansHouse_1F_Movement_1B6BE1:: @ 81B6BE1
walk_left
walk_down
walk_in_place_fastest_right
- end_movement
+ step_end
LittlerootTown_MaysHouse_1F_Movement_1B6BE5:: @ 81B6BE5
walk_right
walk_down
walk_in_place_fastest_left
- end_movement
+ step_end
LittlerootTown_BrendansHouse_1F_EventScript_1B6BE9:: @ 81B6BE9
LittlerootTown_MaysHouse_1F_EventScript_1B6BE9:: @ 81B6BE9
@@ -261,46 +261,46 @@ LittlerootTown_MaysHouse_1F_EventScript_1B6BE9:: @ 81B6BE9
goto_if_eq LittlerootTown_BrendansHouse_1F_EventScript_1B6C80
compare VAR_LITTLEROOT_INTRO_STATE, 7
goto_if_ge LittlerootTown_BrendansHouse_1F_EventScript_1B6C9C
- msgbox LittlerootTown_BrendansHouse_1F_Text_172429, 4
+ msgbox LittlerootTown_BrendansHouse_1F_Text_172429, MSGBOX_DEFAULT
release
end
LittlerootTown_BrendansHouse_1F_EventScript_1B6C33:: @ 81B6C33
- msgbox LittlerootTown_BrendansHouse_1F_Text_172BBC, 4
+ msgbox LittlerootTown_BrendansHouse_1F_Text_172BBC, MSGBOX_DEFAULT
release
end
LittlerootTown_BrendansHouse_1F_EventScript_1B6C3D:: @ 81B6C3D
goto_if_set FLAG_RECEIVED_AMULET_COIN, LittlerootTown_BrendansHouse_1F_EventScript_1B6C72
- msgbox LittlerootTown_BrendansHouse_1F_Text_172782, 4
- giveitem_std ITEM_AMULET_COIN
+ msgbox LittlerootTown_BrendansHouse_1F_Text_172782, MSGBOX_DEFAULT
+ giveitem ITEM_AMULET_COIN
compare VAR_RESULT, 0
- goto_if_eq LittlerootTown_BrendansHouse_1F_EventScript_1A029B
- msgbox LittlerootTown_BrendansHouse_1F_Text_1727CD, 4
+ goto_if_eq Common_EventScript_ShowBagIsFull
+ msgbox LittlerootTown_BrendansHouse_1F_Text_1727CD, MSGBOX_DEFAULT
setflag FLAG_RECEIVED_AMULET_COIN
release
end
LittlerootTown_BrendansHouse_1F_EventScript_1B6C72:: @ 81B6C72
- msgbox LittlerootTown_BrendansHouse_1F_Text_172717, 4
+ msgbox LittlerootTown_BrendansHouse_1F_Text_172717, MSGBOX_DEFAULT
goto LittlerootTown_BrendansHouse_1F_EventScript_1B6C8A
end
LittlerootTown_BrendansHouse_1F_EventScript_1B6C80:: @ 81B6C80
- msgbox LittlerootTown_BrendansHouse_1F_Text_1726D2, 4
+ msgbox LittlerootTown_BrendansHouse_1F_Text_1726D2, MSGBOX_DEFAULT
release
end
LittlerootTown_BrendansHouse_1F_EventScript_1B6C8A:: @ 81B6C8A
closemessage
- call LittlerootTown_BrendansHouse_1F_EventScript_1A02CA
+ call Common_EventScript_OutOfCenterPartyHeal
incrementgamestat GAME_STAT_RESTED_AT_HOME
- msgbox LittlerootTown_BrendansHouse_1F_Text_17276B, 4
+ msgbox LittlerootTown_BrendansHouse_1F_Text_17276B, MSGBOX_DEFAULT
release
end
LittlerootTown_BrendansHouse_1F_EventScript_1B6C9C:: @ 81B6C9C
- msgbox LittlerootTown_BrendansHouse_1F_Text_1726E7, 4
+ msgbox LittlerootTown_BrendansHouse_1F_Text_1726E7, MSGBOX_DEFAULT
release
end
@@ -310,7 +310,7 @@ LittlerootTown_MaysHouse_1F_EventScript_1B6CA6:: @ 81B6CA6
faceplayer
waitse
playmoncry SPECIES_MACHOKE, 0
- msgbox LittlerootTown_BrendansHouse_1F_Text_17281D, 4
+ msgbox LittlerootTown_BrendansHouse_1F_Text_17281D, MSGBOX_DEFAULT
waitmoncry
release
end
@@ -321,7 +321,7 @@ LittlerootTown_MaysHouse_1F_EventScript_1B6CB9:: @ 81B6CB9
faceplayer
waitse
playmoncry SPECIES_MACHOKE, 0
- msgbox LittlerootTown_BrendansHouse_1F_Text_172831, 4
+ msgbox LittlerootTown_BrendansHouse_1F_Text_172831, MSGBOX_DEFAULT
waitmoncry
release
end
@@ -332,11 +332,11 @@ LittlerootTown_BrendansHouse_1F_Movement_1B6CCC:: @ 81B6CCC
walk_left
walk_left
walk_left
- end_movement
+ step_end
LittlerootTown_BrendansHouse_1F_Movement_1B6CD2:: @ 81B6CD2
walk_left
- end_movement
+ step_end
LittlerootTown_MaysHouse_1F_Movement_1B6CD4:: @ 81B6CD4
walk_down
@@ -344,15 +344,15 @@ LittlerootTown_MaysHouse_1F_Movement_1B6CD4:: @ 81B6CD4
walk_right
walk_right
walk_right
- end_movement
+ step_end
LittlerootTown_MaysHouse_1F_Movement_1B6CDA:: @ 81B6CDA
walk_right
- end_movement
+ step_end
LittlerootTown_BrendansHouse_1F_Movement_1B6CDC:: @ 81B6CDC
walk_up
- end_movement
+ step_end
LittlerootTown_BrendansHouse_1F_EventScript_1B6CDE:: @ 81B6CDE
LittlerootTown_MaysHouse_1F_EventScript_1B6CDE:: @ 81B6CDE
@@ -366,27 +366,27 @@ LittlerootTown_MaysHouse_1F_EventScript_1B6CDE:: @ 81B6CDE
call_if_eq LittlerootTown_BrendansHouse_1F_EventScript_1B6E1D
compare VAR_0x8008, 1
call_if_eq LittlerootTown_BrendansHouse_1F_EventScript_1B6E28
- applymovement VAR_0x8009, LittlerootTown_BrendansHouse_1F_Movement_1A0839
+ applymovement VAR_0x8009, Common_Movement_FacePlayer
waitmovement 0
playse SE_PIN
- applymovement VAR_0x8009, LittlerootTown_BrendansHouse_1F_Movement_1A0833
+ applymovement VAR_0x8009, Common_Movement_ExclamationMark
waitmovement 0
- applymovement VAR_0x8009, LittlerootTown_BrendansHouse_1F_Movement_1A0835
+ applymovement VAR_0x8009, Common_Movement_Delay48
waitmovement 0
delay 20
compare VAR_0x8008, 0
call_if_eq LittlerootTown_BrendansHouse_1F_EventScript_1B6DCD
compare VAR_0x8008, 1
call_if_eq LittlerootTown_BrendansHouse_1F_EventScript_1B6DD8
- msgbox LittlerootTown_BrendansHouse_1F_Text_17298B, 4
- giveitem_std ITEM_SS_TICKET
- msgbox LittlerootTown_BrendansHouse_1F_Text_172A7D, 4
+ msgbox LittlerootTown_BrendansHouse_1F_Text_17298B, MSGBOX_DEFAULT
+ giveitem ITEM_SS_TICKET
+ msgbox LittlerootTown_BrendansHouse_1F_Text_172A7D, MSGBOX_DEFAULT
closemessage
compare VAR_0x8008, 0
call_if_eq LittlerootTown_BrendansHouse_1F_EventScript_1B6DE3
compare VAR_0x8008, 1
call_if_eq LittlerootTown_BrendansHouse_1F_EventScript_1B6DEE
- msgbox LittlerootTown_BrendansHouse_1F_Text_172B5E, 4
+ msgbox LittlerootTown_BrendansHouse_1F_Text_172B5E, MSGBOX_DEFAULT
closemessage
compare VAR_0x8008, 0
call_if_eq LittlerootTown_BrendansHouse_1F_EventScript_1B6DF9
@@ -433,44 +433,44 @@ LittlerootTown_BrendansHouse_1F_EventScript_1B6DEE:: @ 81B6DEE
return
LittlerootTown_BrendansHouse_1F_EventScript_1B6DF9:: @ 81B6DF9
- applymovement 255, LittlerootTown_BrendansHouse_1F_Movement_1B6E4F
+ applymovement OBJ_EVENT_ID_PLAYER, LittlerootTown_BrendansHouse_1F_Movement_1B6E4F
applymovement VAR_0x8009, LittlerootTown_BrendansHouse_1F_Movement_1B6E3D
waitmovement 0
return
LittlerootTown_BrendansHouse_1F_EventScript_1B6E0B:: @ 81B6E0B
- applymovement 255, LittlerootTown_BrendansHouse_1F_Movement_1B6E4F
+ applymovement OBJ_EVENT_ID_PLAYER, LittlerootTown_BrendansHouse_1F_Movement_1B6E4F
applymovement VAR_0x8009, LittlerootTown_BrendansHouse_1F_Movement_1B6E43
waitmovement 0
return
LittlerootTown_BrendansHouse_1F_EventScript_1B6E1D:: @ 81B6E1D
- applymovement 255, LittlerootTown_BrendansHouse_1F_Movement_1B6E49
+ applymovement OBJ_EVENT_ID_PLAYER, LittlerootTown_BrendansHouse_1F_Movement_1B6E49
waitmovement 0
return
LittlerootTown_BrendansHouse_1F_EventScript_1B6E28:: @ 81B6E28
- applymovement 255, LittlerootTown_BrendansHouse_1F_Movement_1B6E54
+ applymovement OBJ_EVENT_ID_PLAYER, LittlerootTown_BrendansHouse_1F_Movement_1B6E54
waitmovement 0
return
LittlerootTown_BrendansHouse_1F_Movement_1B6E33:: @ 81B6E33
walk_right
walk_right
- end_movement
+ step_end
LittlerootTown_BrendansHouse_1F_Movement_1B6E36:: @ 81B6E36
walk_left
walk_left
- end_movement
+ step_end
LittlerootTown_BrendansHouse_1F_Movement_1B6E39:: @ 81B6E39
walk_left
- end_movement
+ step_end
LittlerootTown_BrendansHouse_1F_Movement_1B6E3B:: @ 81B6E3B
walk_right
- end_movement
+ step_end
LittlerootTown_BrendansHouse_1F_Movement_1B6E3D:: @ 81B6E3D
walk_down
@@ -478,7 +478,7 @@ LittlerootTown_BrendansHouse_1F_Movement_1B6E3D:: @ 81B6E3D
walk_right
walk_down
delay_8
- end_movement
+ step_end
LittlerootTown_BrendansHouse_1F_Movement_1B6E43:: @ 81B6E43
walk_down
@@ -486,7 +486,7 @@ LittlerootTown_BrendansHouse_1F_Movement_1B6E43:: @ 81B6E43
walk_left
walk_down
delay_8
- end_movement
+ step_end
LittlerootTown_BrendansHouse_1F_Movement_1B6E49:: @ 81B6E49
delay_16
@@ -494,14 +494,14 @@ LittlerootTown_BrendansHouse_1F_Movement_1B6E49:: @ 81B6E49
walk_down
walk_down
walk_in_place_fastest_left
- end_movement
+ step_end
LittlerootTown_BrendansHouse_1F_Movement_1B6E4F:: @ 81B6E4F
delay_16
delay_16
delay_16
walk_in_place_fastest_down
- end_movement
+ step_end
LittlerootTown_BrendansHouse_1F_Movement_1B6E54:: @ 81B6E54
delay_16
@@ -509,4 +509,4 @@ LittlerootTown_BrendansHouse_1F_Movement_1B6E54:: @ 81B6E54
walk_down
walk_down
walk_in_place_fastest_right
- end_movement
+ step_end
diff --git a/data/scripts/pokeblocks.inc b/data/scripts/pokeblocks.inc
index 95525b4c9..8d4a92cf4 100644
--- a/data/scripts/pokeblocks.inc
+++ b/data/scripts/pokeblocks.inc
@@ -9,7 +9,7 @@ FallarborTown_ContestLobby_EventScript_1B7604:: @ 81B7604
SlateportCity_ContestLobby_EventScript_1B761E:: @ 81B761E
setvar VAR_0x8008, 2
setvar VAR_0x8009, 2
- applymovement 6, SlateportCity_ContestLobby_Movement_1A083D
+ applymovement 6, Common_Movement_FaceOriginalDirection
applymovement VAR_0x8008, SlateportCity_ContestLobby_Movement_1B7821
waitmovement 0
goto SlateportCity_ContestLobby_EventScript_1B7681
@@ -26,8 +26,8 @@ VerdanturfTown_ContestLobby_EventScript_1B763F:: @ 81B763F
LilycoveCity_ContestLobby_EventScript_1B7659:: @ 81B7659
setvar VAR_0x8008, 3
setvar VAR_0x8009, 3
- applymovement 9, LilycoveCity_ContestLobby_Movement_1A083D
- applymovement 10, LilycoveCity_ContestLobby_Movement_1A083D
+ applymovement 9, Common_Movement_FaceOriginalDirection
+ applymovement 10, Common_Movement_FaceOriginalDirection
applymovement VAR_0x8008, LilycoveCity_ContestLobby_Movement_1B7821
waitmovement 0
goto LilycoveCity_ContestLobby_EventScript_1B7681
@@ -52,7 +52,7 @@ FallarborTown_ContestLobby_EventScript_1B76A1:: @ 81B76A1
specialvar VAR_RESULT, PlayerHasBerries
compare VAR_RESULT, 0
goto_if_eq FallarborTown_ContestLobby_EventScript_1B770E
- msgbox FallarborTown_ContestLobby_Text_1B6E9D, 4
+ msgbox FallarborTown_ContestLobby_Text_1B6E9D, MSGBOX_DEFAULT
specialvar VAR_RESULT, GetFirstFreePokeblockSlot
compare VAR_RESULT, -1
goto_if_ne FallarborTown_ContestLobby_EventScript_1B76EF
@@ -61,7 +61,7 @@ FallarborTown_ContestLobby_EventScript_1B76A1:: @ 81B76A1
end
FallarborTown_ContestLobby_EventScript_1B76E5:: @ 81B76E5
- msgbox FallarborTown_ContestLobby_Text_1B6EA8, 4
+ msgbox FallarborTown_ContestLobby_Text_1B6EA8, MSGBOX_DEFAULT
releaseall
end
@@ -74,49 +74,49 @@ FallarborTown_ContestLobby_EventScript_1B76EF:: @ 81B76EF
end
FallarborTown_ContestLobby_EventScript_1B770E:: @ 81B770E
- msgbox FallarborTown_ContestLobby_Text_1B6FF0, 4
- dodailyevents
+ msgbox FallarborTown_ContestLobby_Text_1B6FF0, MSGBOX_DEFAULT
+ dotimebasedevents
goto_if_set FLAG_DAILY_RECEIVED_BERRY_FALLARBOR, FallarborTown_ContestLobby_EventScript_1B774F
goto FallarborTown_ContestLobby_EventScript_1B7759
end
FallarborTown_ContestLobby_EventScript_1B7726:: @ 81B7726
- msgbox FallarborTown_ContestLobby_Text_1B6F1F, 4
+ msgbox FallarborTown_ContestLobby_Text_1B6F1F, MSGBOX_DEFAULT
goto FallarborTown_ContestLobby_EventScript_1B7734
end
FallarborTown_ContestLobby_EventScript_1B7734:: @ 81B7734
- msgbox FallarborTown_ContestLobby_Text_1B6EF1, 4
+ msgbox FallarborTown_ContestLobby_Text_1B6EF1, MSGBOX_DEFAULT
goto FallarborTown_ContestLobby_EventScript_1B7742
end
FallarborTown_ContestLobby_EventScript_1B7742:: @ 81B7742
copyvar VAR_0x8004, VAR_0x8009
- fadescreen 1
+ fadescreen FADE_TO_BLACK
special DoBerryBlending
waitstate
releaseall
end
FallarborTown_ContestLobby_EventScript_1B774F:: @ 81B774F
- msgbox FallarborTown_ContestLobby_Text_1B70F6, 4
+ msgbox FallarborTown_ContestLobby_Text_1B70F6, MSGBOX_DEFAULT
releaseall
end
FallarborTown_ContestLobby_EventScript_1B7759:: @ 81B7759
- msgbox FallarborTown_ContestLobby_Text_1B704A, 4
- giveitem_std ITEM_PECHA_BERRY
+ msgbox FallarborTown_ContestLobby_Text_1B704A, MSGBOX_DEFAULT
+ giveitem ITEM_PECHA_BERRY
setflag FLAG_DAILY_RECEIVED_BERRY_FALLARBOR
goto FallarborTown_ContestLobby_EventScript_1B76EF
end
FallarborTown_ContestLobby_EventScript_1B7776:: @ 81B7776
- msgbox FallarborTown_ContestLobby_Text_1B717C, 4
+ msgbox FallarborTown_ContestLobby_Text_1B717C, MSGBOX_DEFAULT
releaseall
end
FallarborTown_ContestLobby_EventScript_1B7780:: @ 81B7780
- msgbox FallarborTown_ContestLobby_Text_1B71D2, 4
+ msgbox FallarborTown_ContestLobby_Text_1B71D2, MSGBOX_DEFAULT
releaseall
end
@@ -146,7 +146,7 @@ SlateportCity_ContestLobby_EventScript_1B77B6:: @ 81B77B6
VerdanturfTown_ContestLobby_EventScript_1B77B6:: @ 81B77B6
lock
faceplayer
- msgbox FallarborTown_ContestLobby_Text_1B742F, 4
+ msgbox FallarborTown_ContestLobby_Text_1B742F, MSGBOX_DEFAULT
specialvar VAR_RESULT, PlayerHasBerries
compare VAR_RESULT, 1
goto_if_eq FallarborTown_ContestLobby_EventScript_1B77DC
@@ -155,26 +155,26 @@ VerdanturfTown_ContestLobby_EventScript_1B77B6:: @ 81B77B6
end
FallarborTown_ContestLobby_EventScript_1B77DC:: @ 81B77DC
- msgbox FallarborTown_ContestLobby_Text_1B7469, 4
+ msgbox FallarborTown_ContestLobby_Text_1B7469, MSGBOX_DEFAULT
release
end
FallarborTown_ContestLobby_EventScript_1B77E6:: @ 81B77E6
- dodailyevents
+ dotimebasedevents
goto_if_set FLAG_DAILY_RECEIVED_BERRY_FALLARBOR, FallarborTown_ContestLobby_EventScript_1B77F6
goto FallarborTown_ContestLobby_EventScript_1B7800
end
FallarborTown_ContestLobby_EventScript_1B77F6:: @ 81B77F6
- msgbox FallarborTown_ContestLobby_Text_1B7578, 4
+ msgbox FallarborTown_ContestLobby_Text_1B7578, MSGBOX_DEFAULT
release
end
FallarborTown_ContestLobby_EventScript_1B7800:: @ 81B7800
- msgbox FallarborTown_ContestLobby_Text_1B74B4, 4
- giveitem_std ITEM_PECHA_BERRY
+ msgbox FallarborTown_ContestLobby_Text_1B74B4, MSGBOX_DEFAULT
+ giveitem ITEM_PECHA_BERRY
setflag FLAG_DAILY_RECEIVED_BERRY_FALLARBOR
- msgbox FallarborTown_ContestLobby_Text_1B753A, 4
+ msgbox FallarborTown_ContestLobby_Text_1B753A, MSGBOX_DEFAULT
release
end
@@ -183,7 +183,7 @@ LilycoveCity_ContestLobby_Movement_1B7821:: @ 81B7821
SlateportCity_ContestLobby_Movement_1B7821:: @ 81B7821
VerdanturfTown_ContestLobby_Movement_1B7821:: @ 81B7821
walk_in_place_fastest_right
- end_movement
+ step_end
FallarborTown_ContestLobby_EventScript_1B7823:: @ 81B7823
goto FallarborTown_ContestLobby_EventScript_1B783B
@@ -228,12 +228,12 @@ FallarborTown_ContestLobby_EventScript_1B7878:: @ 81B7878
end
FallarborTown_ContestLobby_EventScript_1B7897:: @ 81B7897
- msgbox FallarborTown_ContestLobby_Text_1B7381, 4
+ msgbox FallarborTown_ContestLobby_Text_1B7381, MSGBOX_DEFAULT
releaseall
end
FallarborTown_ContestLobby_EventScript_1B78A1:: @ 81B78A1
- call S_DoSaveDialog
+ call Common_EventScript_SaveGame
compare VAR_RESULT, 0
goto_if_eq FallarborTown_ContestLobby_EventScript_1B7936
message FallarborTown_ContestLobby_Text_1B7304
@@ -253,23 +253,23 @@ FallarborTown_ContestLobby_EventScript_1B78A1:: @ 81B78A1
end
FallarborTown_ContestLobby_EventScript_1B78F3:: @ 81B78F3
- msgbox FallarborTown_ContestLobby_Text_1B733B, 4
+ msgbox FallarborTown_ContestLobby_Text_1B733B, MSGBOX_DEFAULT
goto FallarborTown_ContestLobby_EventScript_1B791D
end
FallarborTown_ContestLobby_EventScript_1B7901:: @ 81B7901
- msgbox FallarborTown_ContestLobby_Text_1B7347, 4
+ msgbox FallarborTown_ContestLobby_Text_1B7347, MSGBOX_DEFAULT
goto FallarborTown_ContestLobby_EventScript_1B791D
end
FallarborTown_ContestLobby_EventScript_1B790F:: @ 81B790F
- msgbox FallarborTown_ContestLobby_Text_1B735A, 4
+ msgbox FallarborTown_ContestLobby_Text_1B735A, MSGBOX_DEFAULT
goto FallarborTown_ContestLobby_EventScript_1B791D
end
FallarborTown_ContestLobby_EventScript_1B791D:: @ 81B791D
setvar VAR_0x8004, 0
- fadescreen 1
+ fadescreen FADE_TO_BLACK
removeobject 240
removeobject 239
removeobject 238
@@ -284,41 +284,41 @@ FallarborTown_ContestLobby_EventScript_1B7936:: @ 81B7936
end
FallarborTown_ContestLobby_EventScript_1B7938:: @ 81B7938
- msgbox FallarborTown_ContestLobby_Text_1B73B7, 4
+ msgbox FallarborTown_ContestLobby_Text_1B73B7, MSGBOX_DEFAULT
releaseall
end
FallarborTown_ContestLobby_EventScript_1B7942:: @ 81B7942
- msgbox FallarborTown_ContestLobby_Text_1B73F1, 4
+ msgbox FallarborTown_ContestLobby_Text_1B73F1, MSGBOX_DEFAULT
releaseall
end
FallarborTown_ContestLobby_EventScript_1B794C:: @ 81B794C
special CloseLink
- msgbox FallarborTown_ContestLobby_Text_1A4A30, 4
+ msgbox FallarborTown_ContestLobby_Text_1A4A30, MSGBOX_DEFAULT
releaseall
end
FallarborTown_ContestLobby_EventScript_1B7959:: @ 81B7959
special CloseLink
- msgbox FallarborTown_ContestLobby_Text_1A4B1D, 4
+ msgbox FallarborTown_ContestLobby_Text_1A4B1D, MSGBOX_DEFAULT
releaseall
end
FallarborTown_ContestLobby_EventScript_1B7966:: @ 81B7966
special CloseLink
- msgbox FallarborTown_ContestLobby_Text_1A10EB, 4
+ msgbox FallarborTown_ContestLobby_Text_1A10EB, MSGBOX_DEFAULT
releaseall
end
FallarborTown_ContestLobby_EventScript_1B7973:: @ 81B7973
special CloseLink
- msgbox FallarborTown_ContestLobby_Text_1A4A85, 4
+ msgbox FallarborTown_ContestLobby_Text_1A4A85, MSGBOX_DEFAULT
releaseall
end
FallarborTown_ContestLobby_EventScript_1B7980:: @ 81B7980
- fadescreen 1
+ fadescreen FADE_TO_BLACK
specialvar VAR_RESULT, GetLinkPartnerNames
copyvar VAR_0x8008, VAR_RESULT
copyvar VAR_0x8004, VAR_0x8008
@@ -327,7 +327,7 @@ FallarborTown_ContestLobby_EventScript_1B7980:: @ 81B7980
end
FallarborTown_ContestLobby_EventScript_1B799A:: @ 81B799A
- fadescreen 0
+ fadescreen FADE_FROM_BLACK
switch VAR_0x8008
case 2, FallarborTown_ContestLobby_EventScript_1B78F3
case 3, FallarborTown_ContestLobby_EventScript_1B7901
diff --git a/data/scripts/prof_birch.inc b/data/scripts/prof_birch.inc
new file mode 100644
index 000000000..92c79a07a
--- /dev/null
+++ b/data/scripts/prof_birch.inc
@@ -0,0 +1,84 @@
+ProfBirch_EventScript_UpdateLocation:: @ 81A02F4
+ compare VAR_PETALBURG_GYM_STATE, 0
+ goto_if_eq Common_EventScript_Return
+ compare VAR_BIRCH_STATE, 0
+ call_if_eq ProfBirch_EventScript_MoveToLab
+ compare VAR_BIRCH_STATE, 1
+ call_if_eq ProfBirch_EventScript_MoveToLab
+ compare VAR_BIRCH_STATE, 2
+ call_if_eq ProfBirch_EventScript_MoveToRoute101
+ compare VAR_BIRCH_STATE, 3
+ call_if_eq ProfBirch_EventScript_MoveToRoute101
+ compare VAR_BIRCH_STATE, 4
+ call_if_eq ProfBirch_EventScript_MoveToRoute103
+ compare VAR_BIRCH_STATE, 5
+ call_if_eq ProfBirch_EventScript_MoveToRoute103
+ compare VAR_BIRCH_STATE, 6
+ call_if_eq ProfBirch_EventScript_MoveToLab
+ compare VAR_BIRCH_STATE, 7
+ call_if_eq ProfBirch_EventScript_MoveToLab
+ return
+
+ProfBirch_EventScript_MoveToLab:: @ 81A0358
+ clearflag FLAG_HIDE_BIRCH_IN_LAB
+ clearflag FLAG_UNKNOWN_BIRCH_380
+ setflag FLAG_HIDE_BIRCH_ROUTE101
+ setflag FLAG_HIDE_BIRCH_ROUTE103
+ return
+
+ProfBirch_EventScript_MoveToRoute101:: @ 81A0365
+ clearflag FLAG_HIDE_BIRCH_ROUTE101
+ setflag FLAG_HIDE_BIRCH_IN_LAB
+ setflag FLAG_UNKNOWN_BIRCH_380
+ setflag FLAG_HIDE_BIRCH_ROUTE103
+ return
+
+ProfBirch_EventScript_MoveToRoute103:: @ 81A0372
+ clearflag FLAG_HIDE_BIRCH_ROUTE103
+ setflag FLAG_HIDE_BIRCH_ROUTE101
+ setflag FLAG_HIDE_BIRCH_IN_LAB
+ setflag FLAG_UNKNOWN_BIRCH_380
+ return
+
+ProfBirch_EventScript_AskRatePokedex:: @ 81A037F
+ lock
+ faceplayer
+ msgbox gBirchDexRatingText_ComeToShowMePokedex, MSGBOX_YESNO
+ compare VAR_RESULT, NO
+ goto_if_eq ProfBirch_EventScript_DeclineRating
+ call ProfBirch_EventScript_RatePokedex
+ release
+ end
+
+ProfBirch_EventScript_DeclineRating:: @ 81A039B
+ msgbox gBirchDexRatingText_Cancel, MSGBOX_DEFAULT
+ release
+ end
+
+ProfBirch_EventScript_ShowRatingMessage:: @ 81A03A5
+ copyvar VAR_0x8004, VAR_0x8009
+ special ShowPokedexRatingMessage
+ waitmessage
+ waitbuttonpress
+ return
+
+ProfBirch_EventScript_RatePokedex:: @ 81A03B0
+ setvar VAR_0x8004, 0
+ specialvar VAR_RESULT, ScriptGetPokedexInfo
+ copyvar VAR_0x8008, VAR_0x8005
+ copyvar VAR_0x8009, VAR_0x8006
+ copyvar VAR_0x800A, VAR_RESULT
+ buffernumberstring 0, VAR_0x8008 @ Num Hoenn seen
+ buffernumberstring 1, VAR_0x8009 @ Num Hoenn caught
+ msgbox gBirchDexRatingText_SoYouveSeenAndCaught, MSGBOX_DEFAULT
+ call ProfBirch_EventScript_ShowRatingMessage
+ compare VAR_0x800A, 0
+ goto_if_eq Common_EventScript_Return @ National dex not enabled
+ setvar VAR_0x8004, 1
+ specialvar VAR_RESULT, ScriptGetPokedexInfo
+ copyvar VAR_0x8008, VAR_0x8005
+ copyvar VAR_0x8009, VAR_0x8006
+ buffernumberstring 0, VAR_0x8008 @ Num National seen
+ buffernumberstring 1, VAR_0x8009 @ Num National caught
+ msgbox gBirchDexRatingText_OnANationwideBasis, MSGBOX_DEFAULT
+ return
diff --git a/data/scripts/record_mix.inc b/data/scripts/record_mix.inc
new file mode 100644
index 000000000..6415f9ceb
--- /dev/null
+++ b/data/scripts/record_mix.inc
@@ -0,0 +1,22 @@
+@ Seems this was superseded by the Record Center, and the below scripts are now unused
+EventScript_MixRecordsPrompt: @ 819FFD5
+ lock
+ faceplayer
+ msgbox UnusedMixRecordsPromptText, MSGBOX_YESNO
+ compare VAR_RESULT, YES
+ goto_if_eq EventScript_MixRecords
+ compare VAR_RESULT, NO
+ goto_if_eq EventScript_EndMixRecords
+ goto EventScript_EndMixRecords
+
+EventScript_MixRecords: @ 819FFFA
+ special RecordMixingPlayerSpotTriggered
+ waitstate
+ lock
+ faceplayer
+EventScript_EndMixRecords: @ 81A0000
+ message UnusedMixRecordsSeeYouAgainText
+ waitmessage
+ waitbuttonpress
+ release
+ end
diff --git a/data/scripts/safari_zone.inc b/data/scripts/safari_zone.inc
index aad2e3237..68efec328 100644
--- a/data/scripts/safari_zone.inc
+++ b/data/scripts/safari_zone.inc
@@ -52,7 +52,7 @@ gUnknown_081C346A:: @ 81C346A
end
EventScript_1C348E:
- fadescreen 1
+ fadescreen FADE_TO_BLACK
special OpenPokeblockCaseOnFeeder
waitstate
compare VAR_RESULT, 0xFFFF
diff --git a/data/scripts/secret_base.inc b/data/scripts/secret_base.inc
new file mode 100644
index 000000000..8a82583b2
--- /dev/null
+++ b/data/scripts/secret_base.inc
@@ -0,0 +1,683 @@
+gUnknown_081A2C51:: @ 81A2C51
+ special sub_80BB70C
+ special CheckPlayerHasSecretBase
+ compare VAR_RESULT, 1
+ goto_if_eq AskToMoveSecretBase
+ checkpartymove MOVE_SECRET_POWER
+ setfieldeffectargument 0, VAR_RESULT
+ buffermovename 1, MOVE_SECRET_POWER
+ compare VAR_0x8007, 1
+ goto_if_eq EventScript_1A2CB0
+ compare VAR_0x8007, 2
+ goto_if_eq EventScript_1A2CB0
+ compare VAR_0x8007, 3
+ goto_if_eq EventScript_1A2CB0
+ compare VAR_0x8007, 4
+ goto_if_eq EventScript_1A2CB0
+ compare VAR_0x8007, 5
+ goto_if_eq EventScript_1A2D08
+ compare VAR_0x8007, 6
+ goto_if_eq EventScript_1A2D60
+ end
+
+EventScript_1A2CB0:
+ lockall
+ compare VAR_RESULT, 6
+ goto_if_eq EventScript_1A2CF1
+ bufferpartymonnick 0, VAR_RESULT
+ msgbox UnknownString_8198F34, MSGBOX_YESNO
+ compare VAR_RESULT, NO
+ goto_if_eq EventScript_1A2F3A
+ msgbox UsedCutRockSmashText, MSGBOX_DEFAULT
+ closemessage
+ dofieldeffect FLDEFF_USE_SECRET_POWER_CAVE
+ waitstate
+ goto EventScript_1A2CFA
+ end
+
+DoSecretBaseCaveFieldEffectScript:: @ 81A2CE6
+ lockall
+ dofieldeffect FLDEFF_USE_SECRET_POWER_CAVE
+ waitstate
+ goto EventScript_1A2CFA
+ end
+
+EventScript_1A2CF1:
+ msgbox UnknownString_8198F10, MSGBOX_SIGN
+ end
+
+EventScript_1A2CFA:
+ msgbox UnknownString_8198F6E, MSGBOX_DEFAULT
+ goto EventScript_1A2DB8
+ end
+
+EventScript_1A2D08:
+ lockall
+ compare VAR_RESULT, 6
+ goto_if_eq EventScript_1A2D49
+ bufferpartymonnick 0, VAR_RESULT
+ msgbox UnknownString_81A197B, MSGBOX_YESNO
+ compare VAR_RESULT, NO
+ goto_if_eq EventScript_1A2F3A
+ msgbox UsedCutRockSmashText, MSGBOX_DEFAULT
+ closemessage
+ dofieldeffect FLDEFF_USE_SECRET_POWER_TREE
+ waitstate
+ goto EventScript_1A2D52
+ end
+
+DoSecretBaseTreeFieldEffectScript:: @ 81A2D3E
+ lockall
+ dofieldeffect FLDEFF_USE_SECRET_POWER_TREE
+ waitstate
+ goto EventScript_1A2D52
+ end
+
+EventScript_1A2D49:
+ msgbox UnknownString_81A1948, MSGBOX_SIGN
+ end
+
+EventScript_1A2D52:
+ msgbox UnknownString_81A19C4, MSGBOX_DEFAULT
+ goto EventScript_1A2DB8
+ end
+
+EventScript_1A2D60:
+ lockall
+ compare VAR_RESULT, 6
+ goto_if_eq EventScript_1A2DA1
+ bufferpartymonnick 0, VAR_RESULT
+ msgbox UnknownString_81A1A4B, MSGBOX_YESNO
+ compare VAR_RESULT, NO
+ goto_if_eq EventScript_1A2F3A
+ msgbox UsedCutRockSmashText, MSGBOX_DEFAULT
+ closemessage
+ dofieldeffect FLDEFF_USE_SECRET_POWER_SHRUB
+ waitstate
+ goto EventScript_1A2DAA
+ end
+
+DoSecretBaseShrubFieldEffectScript:: @ 81A2D96
+ lockall
+ dofieldeffect FLDEFF_USE_SECRET_POWER_SHRUB
+ waitstate
+ goto EventScript_1A2DAA
+ end
+
+EventScript_1A2DA1:
+ msgbox UnknownString_81A1A03, MSGBOX_SIGN
+ end
+
+EventScript_1A2DAA:
+ msgbox UnknownString_81A1AA9, MSGBOX_DEFAULT
+ goto EventScript_1A2DB8
+ end
+
+EventScript_1A2DB8:
+ closemessage
+ playse SE_KAIDAN
+ setvar VAR_INIT_SECRET_BASE, 0
+ setflag FLAG_DECORATION_1
+ special sub_80BB8CC
+ special sub_80BBAF0
+ setvar VAR_0x8004, 0
+ setvar VAR_0x8005, 0
+ special sub_80BBDD0
+ setvar VAR_SECRET_BASE_INITIALIZED, 1
+ waitstate
+ end
+
+SecretBase_EventScript_FirstEntrance:: @ 81A2DDE
+ applymovement OBJ_EVENT_ID_PLAYER, SecretBase_RedCave1_Movement_1A2E11
+ waitmovement 0
+ setvar VAR_INIT_SECRET_BASE, 1
+ msgbox SecretBase_RedCave1_Text_198F89, MSGBOX_YESNO
+ compare VAR_RESULT, YES
+ goto_if_eq SecretBase_RedCave1_EventScript_1A2E08
+ closemessage
+ playse SE_KAIDAN
+ special sub_80BC440
+ end
+
+SecretBase_RedCave1_EventScript_1A2E08:: @ 81A2E08
+ closemessage
+ setflag FLAG_RECEIVED_SECRET_POWER
+ special sub_80BBC78
+ waitstate
+ end
+
+SecretBase_RedCave1_Movement_1A2E11:: @ 81A2E11
+ walk_up
+ walk_up
+ step_end
+
+gUnknown_081A2E14:: @ 81A2E14
+ lockall
+ setvar VAR_INIT_SECRET_BASE, 1
+ playse SE_KAIDAN
+ special sub_80BC114
+ compare VAR_RESULT, 0
+ goto_if_eq EventScript_1A2E38
+ clearflag FLAG_DECORATION_1
+ special sub_80BBAF0
+ setvar VAR_SECRET_BASE_INITIALIZED, 0
+ waitstate
+ end
+
+EventScript_1A2E38:
+ setflag FLAG_DECORATION_1
+ special sub_80BBAF0
+ setvar VAR_SECRET_BASE_INITIALIZED, 0
+ waitstate
+ end
+
+AskToMoveSecretBase:
+ checkpartymove MOVE_SECRET_POWER
+ compare VAR_RESULT, 6
+ goto_if_eq EventScript_1A2EF7
+ setfieldeffectargument 0, VAR_RESULT
+ setorcopyvar VAR_0x8004, VAR_RESULT
+ lockall
+ special GetSecretBaseNearbyMapName
+ msgbox UnknownString_81A3C71, MSGBOX_YESNO
+ compare VAR_RESULT, NO
+ goto_if_eq EventScript_1A2F3A
+ msgbox SecretBase_Text_AllDecorationsWillBeReturned, MSGBOX_YESNO
+ compare VAR_RESULT, NO
+ goto_if_eq EventScript_1A2F3A
+ fadescreen FADE_TO_BLACK
+ special MoveSecretBase
+ closemessage
+ fadescreen FADE_FROM_BLACK
+ msgbox UnknownString_81A3CC9, MSGBOX_YESNO
+ compare VAR_RESULT, NO
+ goto_if_eq EventScript_1A2F3A
+ bufferpartymonnick 0, VAR_0x8004
+ buffermovename 1, MOVE_SECRET_POWER
+ msgbox UsedCutRockSmashText, MSGBOX_DEFAULT
+ closemessage
+ closemessage
+ compare VAR_0x8007, 1
+ goto_if_eq DoSecretBaseCaveFieldEffectScript
+ compare VAR_0x8007, 2
+ goto_if_eq DoSecretBaseCaveFieldEffectScript
+ compare VAR_0x8007, 3
+ goto_if_eq DoSecretBaseCaveFieldEffectScript
+ compare VAR_0x8007, 4
+ goto_if_eq DoSecretBaseCaveFieldEffectScript
+ compare VAR_0x8007, 5
+ goto_if_eq DoSecretBaseTreeFieldEffectScript
+ compare VAR_0x8007, 6
+ goto_if_eq DoSecretBaseShrubFieldEffectScript
+ releaseall
+ end
+
+EventScript_1A2EF7::
+ compare VAR_0x8007, 1
+ goto_if_eq EventScript_1A2CF1
+ compare VAR_0x8007, 2
+ goto_if_eq EventScript_1A2CF1
+ compare VAR_0x8007, 3
+ goto_if_eq EventScript_1A2CF1
+ compare VAR_0x8007, 4
+ goto_if_eq EventScript_1A2CF1
+ compare VAR_0x8007, 5
+ goto_if_eq EventScript_1A2D49
+ compare VAR_0x8007, 6
+ goto_if_eq EventScript_1A2DA1
+ end
+
+EventScript_1A2F3A::
+ closemessage
+ releaseall
+ end
+
+SecretBase_EventScript_SetDecorationFlags:: @ 81A2F3D
+ setflag FLAG_DECORATION_2
+ setflag FLAG_DECORATION_3
+ setflag FLAG_DECORATION_4
+ setflag FLAG_DECORATION_5
+ setflag FLAG_DECORATION_6
+ setflag FLAG_DECORATION_7
+ setflag FLAG_DECORATION_8
+ setflag FLAG_DECORATION_9
+ setflag FLAG_DECORATION_10
+ setflag FLAG_DECORATION_11
+ setflag FLAG_DECORATION_12
+ setflag FLAG_DECORATION_13
+ setflag FLAG_DECORATION_14
+ setflag FLAG_DECORATION_15
+ return
+
+SecretBase_EventScript_InitDecorations:: @ 81A2F68
+ setvar VAR_0x8004, 0
+ setvar VAR_0x8005, 0
+ special sub_80BBDD0
+ setvar VAR_SECRET_BASE_INITIALIZED, 1
+ end
+
+gUnknown_081A2F7B:: @ 81A2F7B
+ setvar VAR_0x8005, 0
+ goto EventScript_1A2F86
+ end
+
+EventScript_1A2F86:
+ special sub_80FF474
+ end
+
+gUnknown_081A2F8A:: @ 81A2F8A
+ setvar VAR_0x8004, 0
+ goto EventScript_1A2F95
+ end
+
+EventScript_1A2F95:
+ special sub_8100A7C
+ compare VAR_RESULT, 1
+ goto_if_eq EventScript_1A2FBF
+ addvar VAR_0x8004, 1
+ compare VAR_0x8005, 0
+ goto_if_eq EventScript_1A2F95
+ removeobject VAR_0x8006
+ setflag VAR_0x8005
+ goto EventScript_1A2F95
+ end
+
+EventScript_1A2FBF:
+ end
+
+SecretBase_BlueCave1_EventScript_1A2FC0:: @ 81A2FC0
+SecretBase_BlueCave2_EventScript_1A2FC0:: @ 81A2FC0
+SecretBase_BlueCave3_EventScript_1A2FC0:: @ 81A2FC0
+SecretBase_BlueCave4_EventScript_1A2FC0:: @ 81A2FC0
+SecretBase_BrownCave1_EventScript_1A2FC0:: @ 81A2FC0
+SecretBase_BrownCave2_EventScript_1A2FC0:: @ 81A2FC0
+SecretBase_BrownCave3_EventScript_1A2FC0:: @ 81A2FC0
+SecretBase_BrownCave4_EventScript_1A2FC0:: @ 81A2FC0
+SecretBase_RedCave1_EventScript_1A2FC0:: @ 81A2FC0
+SecretBase_RedCave2_EventScript_1A2FC0:: @ 81A2FC0
+SecretBase_RedCave3_EventScript_1A2FC0:: @ 81A2FC0
+SecretBase_RedCave4_EventScript_1A2FC0:: @ 81A2FC0
+SecretBase_Shrub1_EventScript_1A2FC0:: @ 81A2FC0
+SecretBase_Shrub2_EventScript_1A2FC0:: @ 81A2FC0
+SecretBase_Shrub3_EventScript_1A2FC0:: @ 81A2FC0
+SecretBase_Shrub4_EventScript_1A2FC0:: @ 81A2FC0
+SecretBase_Tree1_EventScript_1A2FC0:: @ 81A2FC0
+SecretBase_Tree2_EventScript_1A2FC0:: @ 81A2FC0
+SecretBase_Tree3_EventScript_1A2FC0:: @ 81A2FC0
+SecretBase_Tree4_EventScript_1A2FC0:: @ 81A2FC0
+SecretBase_YellowCave1_EventScript_1A2FC0:: @ 81A2FC0
+SecretBase_YellowCave2_EventScript_1A2FC0:: @ 81A2FC0
+SecretBase_YellowCave3_EventScript_1A2FC0:: @ 81A2FC0
+SecretBase_YellowCave4_EventScript_1A2FC0:: @ 81A2FC0
+ special sub_80BCE90
+ compare VAR_0x8004, 0
+ goto_if_eq SecretBase_RedCave1_EventScript_1A3032
+ compare VAR_0x8004, 1
+ goto_if_eq SecretBase_RedCave1_EventScript_1A30AE
+ compare VAR_0x8004, 2
+ goto_if_eq SecretBase_RedCave1_EventScript_1A312A
+ compare VAR_0x8004, 3
+ goto_if_eq SecretBase_RedCave1_EventScript_1A31A6
+ compare VAR_0x8004, 4
+ goto_if_eq SecretBase_RedCave1_EventScript_1A3222
+ compare VAR_0x8004, 5
+ goto_if_eq SecretBase_RedCave1_EventScript_1A329E
+ compare VAR_0x8004, 6
+ goto_if_eq SecretBase_RedCave1_EventScript_1A331A
+ compare VAR_0x8004, 7
+ goto_if_eq SecretBase_RedCave1_EventScript_1A3396
+ compare VAR_0x8004, 8
+ goto_if_eq SecretBase_RedCave1_EventScript_1A3412
+ compare VAR_0x8004, 9
+ goto_if_eq SecretBase_RedCave1_EventScript_1A348E
+ end
+
+SecretBase_RedCave1_EventScript_1A3032:: @ 81A3032
+ goto_if_unset FLAG_SYS_GAME_CLEAR, SecretBase_RedCave1_EventScript_1A3086
+ compare VAR_RESULT, 1
+ goto_if_eq SecretBase_RedCave1_EventScript_1A30A5
+ lock
+ faceplayer
+ msgbox SecretBase_RedCave1_Text_1A1AEA, MSGBOX_YESNO
+ compare VAR_RESULT, NO
+ goto_if_eq SecretBase_RedCave1_EventScript_1A308F
+ setvar VAR_RESULT, 1
+ special sub_80BCE4C
+ call Common_EventScript_SaveGame
+ compare VAR_RESULT, 0
+ goto_if_eq SecretBase_RedCave1_EventScript_1A308F
+ erasebox 0, 0, 15, 10
+ msgbox SecretBase_RedCave1_Text_1A1B83, MSGBOX_DEFAULT
+ goto SecretBase_RedCave1_EventScript_1A350A
+ end
+
+SecretBase_RedCave1_EventScript_1A3086:: @ 81A3086
+ msgbox SecretBase_RedCave1_Text_1A1C3B, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A308F:: @ 81A308F
+ setvar VAR_RESULT, 0
+ special sub_80BCE4C
+ erasebox 0, 0, 15, 10
+ msgbox SecretBase_RedCave1_Text_1A1B97, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A30A5:: @ 81A30A5
+ msgbox SecretBase_RedCave1_Text_1A1BF8, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A30AE:: @ 81A30AE
+ goto_if_unset FLAG_SYS_GAME_CLEAR, SecretBase_RedCave1_EventScript_1A3102
+ compare VAR_RESULT, 1
+ goto_if_eq SecretBase_RedCave1_EventScript_1A3121
+ lock
+ faceplayer
+ msgbox SecretBase_RedCave1_Text_1A1E67, MSGBOX_YESNO
+ compare VAR_RESULT, NO
+ goto_if_eq SecretBase_RedCave1_EventScript_1A310B
+ setvar VAR_RESULT, 1
+ special sub_80BCE4C
+ call Common_EventScript_SaveGame
+ compare VAR_RESULT, 0
+ goto_if_eq SecretBase_RedCave1_EventScript_1A310B
+ erasebox 0, 0, 15, 10
+ msgbox SecretBase_RedCave1_Text_1A1F04, MSGBOX_DEFAULT
+ goto SecretBase_RedCave1_EventScript_1A350A
+ end
+
+SecretBase_RedCave1_EventScript_1A3102:: @ 81A3102
+ msgbox SecretBase_RedCave1_Text_1A1FBD, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A310B:: @ 81A310B
+ setvar VAR_RESULT, 0
+ special sub_80BCE4C
+ erasebox 0, 0, 15, 10
+ msgbox SecretBase_RedCave1_Text_1A1F2E, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A3121:: @ 81A3121
+ msgbox SecretBase_RedCave1_Text_1A1F88, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A312A:: @ 81A312A
+ goto_if_unset FLAG_SYS_GAME_CLEAR, SecretBase_RedCave1_EventScript_1A317E
+ compare VAR_RESULT, 1
+ goto_if_eq SecretBase_RedCave1_EventScript_1A319D
+ lock
+ faceplayer
+ msgbox SecretBase_RedCave1_Text_1A218F, MSGBOX_YESNO
+ compare VAR_RESULT, NO
+ goto_if_eq SecretBase_RedCave1_EventScript_1A3187
+ setvar VAR_RESULT, 1
+ special sub_80BCE4C
+ call Common_EventScript_SaveGame
+ compare VAR_RESULT, 0
+ goto_if_eq SecretBase_RedCave1_EventScript_1A3187
+ erasebox 0, 0, 15, 10
+ msgbox SecretBase_RedCave1_Text_1A2220, MSGBOX_DEFAULT
+ goto SecretBase_RedCave1_EventScript_1A350A
+ end
+
+SecretBase_RedCave1_EventScript_1A317E:: @ 81A317E
+ msgbox SecretBase_RedCave1_Text_1A22FA, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A3187:: @ 81A3187
+ setvar VAR_RESULT, 0
+ special sub_80BCE4C
+ erasebox 0, 0, 15, 10
+ msgbox SecretBase_RedCave1_Text_1A2230, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A319D:: @ 81A319D
+ msgbox SecretBase_RedCave1_Text_1A2280, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A31A6:: @ 81A31A6
+ goto_if_unset FLAG_SYS_GAME_CLEAR, SecretBase_RedCave1_EventScript_1A31FA
+ compare VAR_RESULT, 1
+ goto_if_eq SecretBase_RedCave1_EventScript_1A3219
+ lock
+ faceplayer
+ msgbox SecretBase_RedCave1_Text_1A24E1, MSGBOX_YESNO
+ compare VAR_RESULT, NO
+ goto_if_eq SecretBase_RedCave1_EventScript_1A3203
+ setvar VAR_RESULT, 1
+ special sub_80BCE4C
+ call Common_EventScript_SaveGame
+ compare VAR_RESULT, 0
+ goto_if_eq SecretBase_RedCave1_EventScript_1A3203
+ erasebox 0, 0, 15, 10
+ msgbox SecretBase_RedCave1_Text_1A256F, MSGBOX_DEFAULT
+ goto SecretBase_RedCave1_EventScript_1A350A
+ end
+
+SecretBase_RedCave1_EventScript_1A31FA:: @ 81A31FA
+ msgbox SecretBase_RedCave1_Text_1A2609, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A3203:: @ 81A3203
+ setvar VAR_RESULT, 0
+ special sub_80BCE4C
+ erasebox 0, 0, 15, 10
+ msgbox SecretBase_RedCave1_Text_1A258A, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A3219:: @ 81A3219
+ msgbox SecretBase_RedCave1_Text_1A25D2, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A3222:: @ 81A3222
+ goto_if_unset FLAG_SYS_GAME_CLEAR, SecretBase_RedCave1_EventScript_1A3276
+ compare VAR_RESULT, 1
+ goto_if_eq SecretBase_RedCave1_EventScript_1A3295
+ lock
+ faceplayer
+ msgbox SecretBase_RedCave1_Text_1A2830, MSGBOX_YESNO
+ compare VAR_RESULT, NO
+ goto_if_eq SecretBase_RedCave1_EventScript_1A327F
+ setvar VAR_RESULT, 1
+ special sub_80BCE4C
+ call Common_EventScript_SaveGame
+ compare VAR_RESULT, 0
+ goto_if_eq SecretBase_RedCave1_EventScript_1A327F
+ erasebox 0, 0, 15, 10
+ msgbox SecretBase_RedCave1_Text_1A28D7, MSGBOX_DEFAULT
+ goto SecretBase_RedCave1_EventScript_1A350A
+ end
+
+SecretBase_RedCave1_EventScript_1A3276:: @ 81A3276
+ msgbox SecretBase_RedCave1_Text_1A297C, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A327F:: @ 81A327F
+ setvar VAR_RESULT, 0
+ special sub_80BCE4C
+ erasebox 0, 0, 15, 10
+ msgbox SecretBase_RedCave1_Text_1A28F4, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A3295:: @ 81A3295
+ msgbox SecretBase_RedCave1_Text_1A294D, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A329E:: @ 81A329E
+ goto_if_unset FLAG_SYS_GAME_CLEAR, SecretBase_RedCave1_EventScript_1A32F2
+ compare VAR_RESULT, 1
+ goto_if_eq SecretBase_RedCave1_EventScript_1A3311
+ lock
+ faceplayer
+ msgbox SecretBase_RedCave1_Text_1A1CB2, MSGBOX_YESNO
+ compare VAR_RESULT, NO
+ goto_if_eq SecretBase_RedCave1_EventScript_1A32FB
+ setvar VAR_RESULT, 1
+ special sub_80BCE4C
+ call Common_EventScript_SaveGame
+ compare VAR_RESULT, 0
+ goto_if_eq SecretBase_RedCave1_EventScript_1A32FB
+ erasebox 0, 0, 15, 10
+ msgbox SecretBase_RedCave1_Text_1A1D48, MSGBOX_DEFAULT
+ goto SecretBase_RedCave1_EventScript_1A350A
+ end
+
+SecretBase_RedCave1_EventScript_1A32F2:: @ 81A32F2
+ msgbox SecretBase_RedCave1_Text_1A1DF6, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A32FB:: @ 81A32FB
+ setvar VAR_RESULT, 0
+ special sub_80BCE4C
+ erasebox 0, 0, 15, 10
+ msgbox SecretBase_RedCave1_Text_1A1D59, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A3311:: @ 81A3311
+ msgbox SecretBase_RedCave1_Text_1A1DC0, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A331A:: @ 81A331A
+ goto_if_unset FLAG_SYS_GAME_CLEAR, SecretBase_RedCave1_EventScript_1A336E
+ compare VAR_RESULT, 1
+ goto_if_eq SecretBase_RedCave1_EventScript_1A338D
+ lock
+ faceplayer
+ msgbox SecretBase_RedCave1_Text_1A2026, MSGBOX_YESNO
+ compare VAR_RESULT, NO
+ goto_if_eq SecretBase_RedCave1_EventScript_1A3377
+ setvar VAR_RESULT, 1
+ special sub_80BCE4C
+ call Common_EventScript_SaveGame
+ compare VAR_RESULT, 0
+ goto_if_eq SecretBase_RedCave1_EventScript_1A3377
+ erasebox 0, 0, 15, 10
+ msgbox SecretBase_RedCave1_Text_1A2095, MSGBOX_DEFAULT
+ goto SecretBase_RedCave1_EventScript_1A350A
+ end
+
+SecretBase_RedCave1_EventScript_1A336E:: @ 81A336E
+ msgbox SecretBase_RedCave1_Text_1A2147, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A3377:: @ 81A3377
+ setvar VAR_RESULT, 0
+ special sub_80BCE4C
+ erasebox 0, 0, 15, 10
+ msgbox SecretBase_RedCave1_Text_1A20AE, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A338D:: @ 81A338D
+ msgbox SecretBase_RedCave1_Text_1A2109, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A3396:: @ 81A3396
+ goto_if_unset FLAG_SYS_GAME_CLEAR, SecretBase_RedCave1_EventScript_1A33EA
+ compare VAR_RESULT, 1
+ goto_if_eq SecretBase_RedCave1_EventScript_1A3409
+ lock
+ faceplayer
+ msgbox SecretBase_RedCave1_Text_1A236A, MSGBOX_YESNO
+ compare VAR_RESULT, NO
+ goto_if_eq SecretBase_RedCave1_EventScript_1A33F3
+ setvar VAR_RESULT, 1
+ special sub_80BCE4C
+ call Common_EventScript_SaveGame
+ compare VAR_RESULT, 0
+ goto_if_eq SecretBase_RedCave1_EventScript_1A33F3
+ erasebox 0, 0, 15, 10
+ msgbox SecretBase_RedCave1_Text_1A2405, MSGBOX_DEFAULT
+ goto SecretBase_RedCave1_EventScript_1A350A
+ end
+
+SecretBase_RedCave1_EventScript_1A33EA:: @ 81A33EA
+ msgbox SecretBase_RedCave1_Text_1A2480, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A33F3:: @ 81A33F3
+ setvar VAR_RESULT, 0
+ special sub_80BCE4C
+ erasebox 0, 0, 15, 10
+ msgbox SecretBase_RedCave1_Text_1A2420, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A3409:: @ 81A3409
+ msgbox SecretBase_RedCave1_Text_1A2446, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A3412:: @ 81A3412
+ goto_if_unset FLAG_SYS_GAME_CLEAR, SecretBase_RedCave1_EventScript_1A3466
+ compare VAR_RESULT, 1
+ goto_if_eq SecretBase_RedCave1_EventScript_1A3485
+ lock
+ faceplayer
+ msgbox SecretBase_RedCave1_Text_1A2663, MSGBOX_YESNO
+ compare VAR_RESULT, NO
+ goto_if_eq SecretBase_RedCave1_EventScript_1A346F
+ setvar VAR_RESULT, 1
+ special sub_80BCE4C
+ call Common_EventScript_SaveGame
+ compare VAR_RESULT, 0
+ goto_if_eq SecretBase_RedCave1_EventScript_1A346F
+ erasebox 0, 0, 15, 10
+ msgbox SecretBase_RedCave1_Text_1A2710, MSGBOX_DEFAULT
+ goto SecretBase_RedCave1_EventScript_1A350A
+ end
+
+SecretBase_RedCave1_EventScript_1A3466:: @ 81A3466
+ msgbox SecretBase_RedCave1_Text_1A27A4, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A346F:: @ 81A346F
+ setvar VAR_RESULT, 0
+ special sub_80BCE4C
+ erasebox 0, 0, 15, 10
+ msgbox SecretBase_RedCave1_Text_1A2736, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A3485:: @ 81A3485
+ msgbox SecretBase_RedCave1_Text_1A276A, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A348E:: @ 81A348E
+ goto_if_unset FLAG_SYS_GAME_CLEAR, SecretBase_RedCave1_EventScript_1A34E2
+ compare VAR_RESULT, 1
+ goto_if_eq SecretBase_RedCave1_EventScript_1A3501
+ lock
+ faceplayer
+ msgbox SecretBase_RedCave1_Text_1A2A13, MSGBOX_YESNO
+ compare VAR_RESULT, NO
+ goto_if_eq SecretBase_RedCave1_EventScript_1A34EB
+ setvar VAR_RESULT, 1
+ special sub_80BCE4C
+ call Common_EventScript_SaveGame
+ compare VAR_RESULT, 0
+ goto_if_eq SecretBase_RedCave1_EventScript_1A34EB
+ erasebox 0, 0, 15, 10
+ msgbox SecretBase_RedCave1_Text_1A2AE2, MSGBOX_DEFAULT
+ goto SecretBase_RedCave1_EventScript_1A350A
+ end
+
+SecretBase_RedCave1_EventScript_1A34E2:: @ 81A34E2
+ msgbox SecretBase_RedCave1_Text_1A2BA4, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A34EB:: @ 81A34EB
+ setvar VAR_RESULT, 0
+ special sub_80BCE4C
+ erasebox 0, 0, 15, 10
+ msgbox SecretBase_RedCave1_Text_1A2AFB, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A3501:: @ 81A3501
+ msgbox SecretBase_RedCave1_Text_1A2B69, MSGBOX_NPC
+ end
+
+SecretBase_RedCave1_EventScript_1A350A:: @ 81A350A
+ special sub_80BCE1C
+ setvar VAR_0x8004, 1
+ setvar VAR_0x8005, 0
+ special StartSpecialBattle
+ waitstate
+ special ScrSpecial_HealPlayerParty
+ release
+ end
diff --git a/data/scripts/secret_power_tm.inc b/data/scripts/secret_power_tm.inc
index 22f998d14..5042bd211 100644
--- a/data/scripts/secret_power_tm.inc
+++ b/data/scripts/secret_power_tm.inc
@@ -4,15 +4,15 @@ Route111_EventScript_1A3858:: @ 81A3858
msgbox Route111_Text_1A3520, MSGBOX_YESNO
compare VAR_RESULT, YES
goto_if_eq Route111_EventScript_1A3877
- msgbox Route111_Text_1A37B5, 4
+ msgbox Route111_Text_1A37B5, MSGBOX_DEFAULT
release
end
Route111_EventScript_1A3877:: @ 81A3877
- giveitem_std ITEM_TM43_SECRET_POWER
+ giveitem ITEM_TM43_SECRET_POWER
compare VAR_RESULT, 0
goto_if_eq Route111_EventScript_1A38D9
- msgbox Route111_Text_1A35C5, 4
+ msgbox Route111_Text_1A35C5, MSGBOX_DEFAULT
closemessage
setflag FLAG_RECEIVED_SECRET_POWER
clearflag FLAG_HIDE_TM_SALESMAN_SLATEPORT
@@ -37,7 +37,7 @@ Route111_EventScript_1A38CE:: @ 81A38CE
return
Route111_EventScript_1A38D9:: @ 81A38D9
- msgbox Route111_Text_1A37F6, 4
+ msgbox Route111_Text_1A37F6, MSGBOX_DEFAULT
release
end
@@ -53,7 +53,7 @@ Route111_Movement_1A38E3:: @ 81A38E3
walk_left
walk_down
walk_down
- end_movement
+ step_end
Route111_Movement_1A38EF:: @ 81A38EF
walk_left
@@ -67,4 +67,4 @@ Route111_Movement_1A38EF:: @ 81A38EF
walk_left
walk_down
walk_down
- end_movement
+ step_end
diff --git a/data/scripts/set_gym_trainers.inc b/data/scripts/set_gym_trainers.inc
new file mode 100644
index 000000000..3248c2d82
--- /dev/null
+++ b/data/scripts/set_gym_trainers.inc
@@ -0,0 +1,74 @@
+Common_EventScript_SetGymTrainers:: @ 81A01C0
+ switch VAR_0x8008
+ case 1, RusboroCity_Gym_SetGymTrainers
+ case 2, DewfordTown_Gym_SetGymTrainers
+ case 3, MauvilleCity_Gym_SetGymTrainers
+ case 4, LavaridgeTown_Gym_SetGymTrainers
+ case 5, PetalburgCity_Gym_SetGymTrainers
+ case 6, FortreeCity_Gym_SetGymTrainers
+ case 7, MossdeepCity_Gym_SetGymTrainers
+ case 8, SootopolisCity_Gym_SetGymTrainers
+ end
+
+RusboroCity_Gym_SetGymTrainers:: @ 81A021E
+ settrainerflag TRAINER_JOSH
+ settrainerflag TRAINER_TOMMY
+ return
+
+DewfordTown_Gym_SetGymTrainers:: @ 81A0225
+ settrainerflag TRAINER_HIDEKI
+ settrainerflag TRAINER_TESSA
+ settrainerflag TRAINER_LAURA
+ return
+
+MauvilleCity_Gym_SetGymTrainers:: @ 81A022F
+ settrainerflag TRAINER_KIRK
+ settrainerflag TRAINER_SHAWN
+ settrainerflag TRAINER_BEN
+ settrainerflag TRAINER_VIVIAN
+ return
+
+LavaridgeTown_Gym_SetGymTrainers:: @ 81A023C
+ settrainerflag TRAINER_COLE
+ settrainerflag TRAINER_AXLE
+ settrainerflag TRAINER_ANDY
+ settrainerflag TRAINER_ZANE
+ settrainerflag TRAINER_SADIE
+ return
+
+PetalburgCity_Gym_SetGymTrainers:: @ 81A024C
+ settrainerflag TRAINER_RANDALL
+ settrainerflag TRAINER_PARKER
+ settrainerflag TRAINER_GEORGE
+ settrainerflag TRAINER_BERKE
+ settrainerflag TRAINER_MARY
+ settrainerflag TRAINER_LORI
+ settrainerflag TRAINER_JODY
+ return
+
+FortreeCity_Gym_SetGymTrainers:: @ 81A0262
+ settrainerflag TRAINER_JARED
+ settrainerflag TRAINER_TERRELL
+ settrainerflag TRAINER_KYLEE
+ settrainerflag TRAINER_WILL
+ return
+
+MossdeepCity_Gym_SetGymTrainers:: @ 81A026F
+ settrainerflag TRAINER_PRESTON
+ settrainerflag TRAINER_VIRGIL
+ settrainerflag TRAINER_FRITZ
+ settrainerflag TRAINER_HANNAH
+ settrainerflag TRAINER_SAMANTHA
+ settrainerflag TRAINER_MAURA
+ return
+
+SootopolisCity_Gym_SetGymTrainers:: @ 81A0282
+ settrainerflag TRAINER_ANDREA
+ settrainerflag TRAINER_CRISSY
+ settrainerflag TRAINER_BRIANNA_2
+ settrainerflag TRAINER_CONNIE
+ settrainerflag TRAINER_BRIDGET
+ settrainerflag TRAINER_OLIVIA
+ settrainerflag TRAINER_TIFFANY
+ settrainerflag TRAINER_MARISSA
+ return
diff --git a/data/scripts/shared_secret_base.inc b/data/scripts/shared_secret_base.inc
new file mode 100644
index 000000000..e3b87f1ea
--- /dev/null
+++ b/data/scripts/shared_secret_base.inc
@@ -0,0 +1,190 @@
+SecretBase_MapScripts:: @ 815F337
+ map_script MAP_SCRIPT_ON_WARP_INTO_MAP_TABLE, SecretBase_OnWarp
+ map_script MAP_SCRIPT_ON_TRANSITION, SecretBase_OnTransition
+ map_script MAP_SCRIPT_ON_FRAME_TABLE, SecretBase_OnFrame
+ map_script MAP_SCRIPT_ON_RESUME, SecretBase_OnResume
+ .byte 0
+
+SecretBase_OnResume:: @ 815F34C
+ setstepcallback 6
+ end
+
+SecretBase_OnTransition:: @ 815F34F
+ call SecretBase_EventScript_SetDecorationFlags
+ special SetSecretBaseOwnerGfxId
+ end
+
+SecretBase_OnWarp:: @ 815F358
+ map_script_2 VAR_SECRET_BASE_INITIALIZED, 0, SecretBase_EventScript_InitDecorations
+ .2byte 0
+
+SecretBase_OnFrame:: @ 815F362
+ map_script_2 VAR_INIT_SECRET_BASE, 0, SecretBase_EventScript_FirstEntrance
+ .2byte 0
+
+SecretBase_EventScript_PC:: @ 815F36C
+ lockall
+ playse SE_PC_LOGON
+ message SecretBase_Text_BootUpPC
+ dofieldeffect FLDEFF_SECRET_BASE_PC_TURN_ON
+ waitstate
+ waitmessage
+ waitbuttonpress
+ playse SE_SELECT
+ goto SecretBase_EventScript_PCShowMainMenu
+ end
+
+SecretBase_EventScript_PCShowMainMenu:
+ message SecretBase_Text_WhatWouldYouLikeToDo
+ waitmessage
+ goto_if_set FLAG_SECRET_BASE_REGISTRY_ENABLED, SecretBase_EventScript_PCMainMenuWithRegister
+ goto SecretBase_EventScript_PCMainMenuWithoutRegister
+ end
+
+SecretBase_EventScript_PCCancel:: @ 815F399
+ lockall
+ goto SecretBase_EventScript_PCShowMainMenu
+ end
+
+SecretBase_EventScript_PCMainMenuWithRegister:
+ multichoice 0, 0, 6, 0
+ switch VAR_RESULT
+ case 0, SecretBase_EventScript_PCDecorationMenu
+ case 1, SecretBase_EventScript_PCPackUp
+ case 2, SecretBase_EventScript_PCRegistryMenu
+ case 3, SecretBase_EventScript_PCTurnOff
+ case 127, SecretBase_EventScript_PCTurnOff
+ end
+
+SecretBase_EventScript_PCMainMenuWithoutRegister:
+ multichoice 0, 0, 5, 0
+ switch VAR_RESULT
+ case 0, SecretBase_EventScript_PCDecorationMenu
+ case 1, SecretBase_EventScript_PCPackUp
+ case 2, SecretBase_EventScript_PCTurnOff
+ case 127, SecretBase_EventScript_PCTurnOff
+ end
+
+SecretBase_EventScript_PCPackUp:
+ msgbox SecretBase_Text_AllDecorationsWillBeReturned, MSGBOX_YESNO
+ compare VAR_RESULT, NO
+ goto_if_eq SecretBase_EventScript_PCShowMainMenu
+ closemessage
+ special MoveOutOfSecretBase
+ releaseall
+ end
+
+SecretBase_EventScript_PCDecorationMenu:
+ special SecretBasePC_Decoration
+ end
+
+SecretBase_EventScript_PCRegistryMenu:
+ special SecretBasePC_Registry
+ end
+
+SecretBase_EventScript_RecordMixingPC:: @ 815F43A
+ lockall
+ message SecretBase_Text_BootUpPC
+ playse SE_PC_LOGON
+ dofieldeffect FLDEFF_SECRET_BASE_PC_TURN_ON
+ waitstate
+ waitmessage
+ waitbuttonpress
+ playse SE_SELECT
+ goto SecretBase_EventScript_PCRegisterMenu
+ end
+
+SecretBase_EventScript_PCRegisterMenu:
+ message SecretBase_Text_WhatWouldYouLikeToDo
+ waitmessage
+ multichoice 0, 0, 7, 0
+ switch VAR_RESULT
+ case 0, SecretBase_EventScript_PCRegister
+ case 1, SecretBase_EventScript_PCRegistryMenu
+ case 2, SecretBase_EventScript_PCRegistryInfo
+ case 3, SecretBase_EventScript_PCTurnOff
+ case 127, SecretBase_EventScript_PCTurnOff
+ end
+
+SecretBase_EventScript_ShowRegisterMenu:: @ 815F49A
+ lockall
+ goto SecretBase_EventScript_PCRegisterMenu
+ end
+
+SecretBase_EventScript_PCRegister:
+ special GetCurSecretBaseRegistrationValidity
+ compare VAR_RESULT, 1
+ goto_if_eq SecretBase_EventScript_AlreadyRegistered
+ compare VAR_RESULT, 2
+ goto_if_eq SecretBase_EventScript_CantRegisterTooManyBases
+ special BufferSecretBaseOwnerName
+ msgbox SecretBase_Text_WantToRegisterSecretBase, MSGBOX_YESNO
+ compare VAR_RESULT, NO
+ goto_if_eq SecretBase_EventScript_PCRegisterMenu
+ msgbox SecretBase_Text_RegistrationCompleted, MSGBOX_SIGN
+ special ToggleCurSecretBaseRegistry
+ special DoSecretBasePCTurnOffEffect
+ releaseall
+ end
+
+SecretBase_EventScript_AlreadyRegistered:
+ msgbox SecretBase_Text_AlreadyRegisteredDelete, MSGBOX_YESNO
+ compare VAR_RESULT, NO
+ goto_if_eq SecretBase_EventScript_PCRegisterMenu
+ msgbox SecretBase_Text_DataUnregistered, MSGBOX_SIGN
+ special ToggleCurSecretBaseRegistry
+ special DoSecretBasePCTurnOffEffect
+ releaseall
+ end
+
+SecretBase_EventScript_CantRegisterTooManyBases:
+ msgbox SecretBase_Text_TooManyBasesDeleteSome, MSGBOX_SIGN
+ special DoSecretBasePCTurnOffEffect
+ closemessage
+ releaseall
+ end
+
+SecretBase_EventScript_PCRegistryInfo:
+ message SecretBase_Text_RegistryInfo
+ waitmessage
+ goto SecretBase_EventScript_PCRegisterMenu
+ end
+
+SecretBase_EventScript_PCTurnOff:
+ special DoSecretBasePCTurnOffEffect
+ closemessage
+ releaseall
+ end
+
+SecretBase_EventScript_SandOrnament:: @ 815F523
+ dofieldeffect FLDEFF_SAND_PILLAR
+ waitstate
+ end
+
+SecretBase_EventScript_ShieldOrToyTV:: @ 815F528
+ special GetShieldToyTVDecorationInfo
+ compare VAR_RESULT, 0
+ goto_if_eq SecretBase_EventScript_BattleTowerShield
+ compare VAR_RESULT, 1
+ goto_if_eq SecretBase_EventScript_ToyTV
+ compare VAR_RESULT, 2
+ goto_if_eq SecretBase_EventScript_SeedotTV
+ compare VAR_RESULT, 3
+ goto_if_eq SecretBase_EventScript_SkittyTV
+ end
+
+SecretBase_EventScript_BattleTowerShield:
+ msgbox SecretBase_Text_BattleTowerShield, MSGBOX_SIGN
+ end
+
+SecretBase_EventScript_ToyTV:
+ msgbox SecretBase_Text_ToyTV, MSGBOX_SIGN
+ end
+
+SecretBase_EventScript_SeedotTV:
+ msgbox SecretBase_Text_SeedotTV, MSGBOX_SIGN
+ end
+
+SecretBase_EventScript_SkittyTV:
+ msgbox SecretBase_Text_SkittyTV, MSGBOX_SIGN
+ end
diff --git a/data/scripts/static_pokemon.inc b/data/scripts/static_pokemon.inc
new file mode 100644
index 000000000..c881d9518
--- /dev/null
+++ b/data/scripts/static_pokemon.inc
@@ -0,0 +1,177 @@
+Hideout_B1F_EventScript_Electrode1:: @ 81A04FD
+ lock
+ faceplayer
+ setwildbattle SPECIES_ELECTRODE, 30, ITEM_NONE
+ waitse
+ playmoncry SPECIES_ELECTRODE, 2
+ delay 40
+ waitmoncry
+ setflag FLAG_HIDE_ELECTRODE_1_HIDEOUT
+ setflag FLAG_SYS_CTRL_OBJ_DELETE
+ dowildbattle
+ clearflag FLAG_SYS_CTRL_OBJ_DELETE
+ release
+ end
+
+Hideout_B1F_EventScript_Electrode2:: @ 81A051B
+ lock
+ faceplayer
+ setwildbattle SPECIES_ELECTRODE, 30, ITEM_NONE
+ waitse
+ playmoncry SPECIES_ELECTRODE, 2
+ delay 40
+ waitmoncry
+ setflag FLAG_HIDE_ELECTRODE_2_HIDEOUT
+ setflag FLAG_SYS_CTRL_OBJ_DELETE
+ dowildbattle
+ clearflag FLAG_SYS_CTRL_OBJ_DELETE
+ release
+ end
+
+Route120_EventScript_Kecleon1:: @ 81A0539
+ lock
+ faceplayer
+ setvar VAR_0x8004, 1
+ goto EventScript_Kecleon
+ end
+
+Route120_EventScript_Kecleon2:: @ 81A0546
+ lock
+ faceplayer
+ setvar VAR_0x8004, 2
+ goto EventScript_Kecleon
+ end
+
+Route120_EventScript_Kecleon3:: @ 81A0553
+ lock
+ faceplayer
+ setvar VAR_0x8004, 3
+ goto EventScript_Kecleon
+ end
+
+Route120_EventScript_Kecleon4:: @ 81A0560
+ lock
+ faceplayer
+ setvar VAR_0x8004, 4
+ goto EventScript_Kecleon
+ end
+
+Route120_EventScript_Kecleon5:: @ 81A056D
+ lock
+ faceplayer
+ setvar VAR_0x8004, 5
+ goto EventScript_Kecleon
+ end
+
+Route119_EventScript_Kecleon1:: @ 81A057A
+ lock
+ faceplayer
+ setvar VAR_0x8004, 6
+ goto EventScript_Kecleon
+ end
+
+Route119_EventScript_Kecleon2:: @ 81A0587
+ lock
+ faceplayer
+ setvar VAR_0x8004, 7
+ goto EventScript_Kecleon
+ end
+
+EventScript_Kecleon:: @ 81A0594
+ checkitem ITEM_DEVON_SCOPE, 1
+ compare VAR_RESULT, 1
+ goto_if_eq EventScript_AskUseDevonScope
+ msgbox Text_SomethingUnseeable, MSGBOX_DEFAULT
+ release
+ end
+
+EventScript_AskUseDevonScope:: @ 81A05AE
+ msgbox Text_WantToUseDevonScope, MSGBOX_YESNO
+ compare VAR_RESULT, YES
+ goto_if_eq EventScript_BattleKecleon
+ release
+ end
+
+EventScript_BattleKecleon:: @ 81A05C3
+ msgbox Text_UseDevonScopeMonAttacked, MSGBOX_DEFAULT
+ closemessage
+ applymovement VAR_LAST_TALKED, Common_Movement_FacePlayer
+ waitmovement 0
+ applymovement VAR_LAST_TALKED, Movement_KecleonAppears
+ waitmovement 0
+ waitse
+ playmoncry SPECIES_KECLEON, 2
+ delay 40
+ waitmoncry
+ setwildbattle SPECIES_KECLEON, 30, ITEM_NONE
+ compare VAR_0x8004, 1
+ call_if_eq Route120_EventScript_HideKecleon1
+ compare VAR_0x8004, 2
+ call_if_eq Route120_EventScript_HideKecleon2
+ compare VAR_0x8004, 3
+ call_if_eq Route120_EventScript_HideKecleon3
+ compare VAR_0x8004, 4
+ call_if_eq Route120_EventScript_HideKecleon4
+ compare VAR_0x8004, 5
+ call_if_eq Route120_EventScript_HideKecleon5
+ compare VAR_0x8004, 6
+ call_if_eq Route119_EventScript_HideKecleon1
+ compare VAR_0x8004, 7
+ call_if_eq Route119_EventScript_HideKecleon2
+ setflag FLAG_SYS_CTRL_OBJ_DELETE
+ dowildbattle
+ clearflag FLAG_SYS_CTRL_OBJ_DELETE
+ release
+ end
+
+Route120_EventScript_HideKecleon1:: @ 81A0646
+ setflag FLAG_HIDE_KECLEON_ROUTE120_3
+ return
+
+Route120_EventScript_HideKecleon2:: @ 81A064A
+ setflag FLAG_HIDE_KECLEON_ROUTE120_4
+ return
+
+Route120_EventScript_HideKecleon3:: @ 81A064E
+ setflag FLAG_HIDE_KECLEON_ROUTE120_5
+ return
+
+Route120_EventScript_HideKecleon4:: @ 81A0652
+ setflag FLAG_HIDE_KECLEON_ROUTE120_6
+ return
+
+Route120_EventScript_HideKecleon5:: @ 81A0656
+ setflag FLAG_HIDE_KECLEON_ROUTE120_7
+ return
+
+Route119_EventScript_HideKecleon1:: @ 81A065A
+ setflag FLAG_HIDE_KECLEON_ROUTE119_1
+ return
+
+Route119_EventScript_HideKecleon2:: @ 81A065E
+ setflag FLAG_HIDE_KECLEON_ROUTE119_2
+ return
+
+Movement_KecleonAppears:: @ 81A0662
+ set_visible
+ delay_4
+ set_invisible
+ delay_4
+ set_visible
+ delay_4
+ set_invisible
+ delay_4
+ set_visible
+ delay_8
+ set_invisible
+ delay_8
+ set_visible
+ delay_8
+ set_invisible
+ delay_8
+ set_visible
+ delay_16
+ set_invisible
+ delay_16
+ set_visible
+ step_end
diff --git a/data/scripts/std_msgbox.inc b/data/scripts/std_msgbox.inc
new file mode 100644
index 000000000..912f88fa1
--- /dev/null
+++ b/data/scripts/std_msgbox.inc
@@ -0,0 +1,36 @@
+Std_MsgboxNPC:
+ lock
+ faceplayer
+ message 0x0
+ waitmessage
+ waitbuttonpress
+ release
+ return
+
+Std_MsgboxSign:
+ lockall
+ message 0x0
+ waitmessage
+ waitbuttonpress
+ releaseall
+ return
+
+Std_MsgboxDefault:
+ message 0x0
+ waitmessage
+ waitbuttonpress
+ return
+
+Std_MsgboxYesNo:
+ message 0x0
+ waitmessage
+ yesnobox 20, 8
+ return
+
+EventScript_UnusedReturn: @ 819F805
+ return
+
+Common_EventScript_SaveGame:: @ 819F806
+ special SaveGame
+ waitstate
+ return
diff --git a/data/scripts/surf.inc b/data/scripts/surf.inc
new file mode 100644
index 000000000..49b7a1162
--- /dev/null
+++ b/data/scripts/surf.inc
@@ -0,0 +1,16 @@
+EventScript_UseSurf:: @ 81A0117
+ checkpartymove MOVE_SURF
+ compare VAR_RESULT, PARTY_SIZE
+ goto_if_eq EventScript_EndUseSurf
+ bufferpartymonnick 0, VAR_RESULT
+ setfieldeffectargument 0, VAR_RESULT
+ lockall
+ msgbox gText_WantToUseSurf, MSGBOX_YESNO
+ compare VAR_RESULT, NO
+ goto_if_eq EventScript_ReleaseUseSurf
+ msgbox gText_PlayerUsedSurf, MSGBOX_DEFAULT
+ dofieldeffect FLDEFF_USE_SURF
+EventScript_ReleaseUseSurf: @ 81A014C
+ releaseall
+EventScript_EndUseSurf: @ 81A014D
+ end
diff --git a/data/scripts/trainer_battle.inc b/data/scripts/trainer_battle.inc
new file mode 100644
index 000000000..4615435d1
--- /dev/null
+++ b/data/scripts/trainer_battle.inc
@@ -0,0 +1,136 @@
+EventScript_StartTrainerBattle:: @ 819F80B
+ lock
+ special PlayTrainerEncounterMusic
+ special EndTrainerApproach
+ waitstate
+ goto EventScript_DoTrainerBattle
+
+EventScript_TryDoNormalTrainerBattle:: @ 819F818
+ lock
+ faceplayer
+ applymovement VAR_LAST_TALKED, Movement_RevealTrainer
+ waitmovement 0
+ specialvar VAR_RESULT, GetTrainerFlag
+ compare VAR_RESULT, 0
+ goto_if_ne EventScript_NoNormalTrainerBattle
+ special PlayTrainerEncounterMusic
+ special SetUpTrainerMovement
+ goto EventScript_DoTrainerBattle
+
+EventScript_NoNormalTrainerBattle:
+ gotopostbattlescript
+
+EventScript_TryDoDoubleTrainerBattle:: @ 819F840
+ lock
+ faceplayer
+ call EventScript_RevealTrainer
+ specialvar VAR_RESULT, GetTrainerFlag
+ compare VAR_RESULT, 0
+ goto_if_ne EventScript_NoDoubleTrainerBattle
+ special HasEnoughMonsForDoubleBattle
+ compare VAR_RESULT, PLAYER_HAS_TWO_USABLE_MONS
+ goto_if_ne EventScript_NotEnoughMonsForDoubleBattle
+ special PlayTrainerEncounterMusic
+ special SetUpTrainerMovement
+ goto EventScript_DoTrainerBattle
+
+EventScript_NotEnoughMonsForDoubleBattle:
+ special ScrSpecial_ShowTrainerNonBattlingSpeech
+ waitmessage
+ waitbuttonpress
+ release
+ end
+
+EventScript_NoDoubleTrainerBattle:
+ gotopostbattlescript
+
+EventScript_DoNoIntroTrainerBattle:: @ 819F878
+ applymovement VAR_LAST_TALKED, Movement_RevealTrainer
+ waitmovement 0
+ special PlayTrainerEncounterMusic
+ trainerbattlebegin
+ gotopostbattlescript
+
+EventScript_TryDoRematchBattle:: @ 819F887
+ call EventScript_RevealTrainer
+ specialvar VAR_RESULT, IsTrainerReadyForRematch
+ compare VAR_RESULT, FALSE
+ goto_if_eq EventScript_NoRematchTrainerBattle
+ special PlayTrainerEncounterMusic
+ special SetUpTrainerMovement
+ special ShowTrainerIntroSpeech
+ waitmessage
+ waitbuttonpress
+ special BattleSetup_StartRematchBattle
+ waitstate
+ releaseall
+ end
+
+EventScript_NoRematchTrainerBattle:
+ gotopostbattlescript
+
+EventScript_TryDoDoubleRematchBattle:: @ 819F8AE
+ specialvar VAR_RESULT, IsTrainerReadyForRematch
+ compare VAR_RESULT, FALSE
+ goto_if_eq EventScript_NoDoubleRematchTrainerBattle
+ special HasEnoughMonsForDoubleBattle
+ compare VAR_RESULT, PLAYER_HAS_TWO_USABLE_MONS
+ goto_if_ne EventScript_NotEnoughMonsForDoubleRematchBattle
+ special PlayTrainerEncounterMusic
+ special SetUpTrainerMovement
+ special ShowTrainerIntroSpeech
+ waitmessage
+ waitbuttonpress
+ special BattleSetup_StartRematchBattle
+ waitstate
+ releaseall
+ end
+
+EventScript_NoDoubleRematchTrainerBattle:
+ gotopostbattlescript
+
+EventScript_NotEnoughMonsForDoubleRematchBattle:
+ special ScrSpecial_ShowTrainerNonBattlingSpeech
+ waitmessage
+ waitbuttonpress
+ release
+ end
+
+EventScript_RevealTrainer:
+ applymovement VAR_LAST_TALKED, Movement_RevealTrainer
+ waitmovement 0
+ return
+
+Movement_RevealTrainer::
+ reveal_trainer
+ step_end
+
+EventScript_DoTrainerBattle:
+ special ShowTrainerIntroSpeech
+ waitmessage
+ waitbuttonpress
+ trainerbattlebegin
+ specialvar VAR_RESULT, ScrSpecial_GetTrainerBattleMode
+ compare VAR_RESULT, TRAINER_BATTLE_SINGLE
+ goto_if_eq EventScript_EndTrainerBattle
+ compare VAR_RESULT, TRAINER_BATTLE_CONTINUE_SCRIPT
+ goto_if_eq EventScript_GoToBeatenScript
+ compare VAR_RESULT, TRAINER_BATTLE_CONTINUE_SCRIPT_NO_MUSIC
+ goto_if_eq EventScript_GoToBeatenScript
+ compare VAR_RESULT, TRAINER_BATTLE_CONTINUE_SCRIPT_DOUBLE
+ goto_if_eq EventScript_GoToBeatenScript
+ compare VAR_RESULT, TRAINER_BATTLE_CONTINUE_SCRIPT_DOUBLE_NO_MUSIC
+ goto_if_eq EventScript_GoToBeatenScript
+EventScript_EndTrainerBattle:
+ releaseall
+ end
+
+EventScript_GoToBeatenScript:
+ gotobeatenscript
+
+Std_MsgboxAutoclose::
+ message 0x0
+ waitmessage
+ waitbuttonpress
+ release
+ return
diff --git a/data/scripts/tv.inc b/data/scripts/tv.inc
index 486e5d68c..9c22f6595 100644
--- a/data/scripts/tv.inc
+++ b/data/scripts/tv.inc
@@ -30,21 +30,21 @@ EventScript_1A6EBB:
EventScript_1A6EF1:
special GetMomOrDadStringForTVMessage
- msgbox UnknownString_81A0E68, 4
+ msgbox UnknownString_81A0E68, MSGBOX_DEFAULT
special TurnOffTVScreen
releaseall
end
EventScript_1A6F01:
- msgbox UnknownString_817288C, 4
+ msgbox UnknownString_817288C, MSGBOX_DEFAULT
releaseall
end
EventScript_1A6F0B:
.ifdef SAPPHIRE
- msgbox UnknownString_8172D30, 4
+ msgbox UnknownString_8172D30, MSGBOX_DEFAULT
.else
- msgbox UnknownString_8172C50, 4
+ msgbox UnknownString_8172C50, MSGBOX_DEFAULT
.endif
special InitRoamer
clearflag FLAG_SYS_TV_LATI
@@ -70,7 +70,7 @@ EventScript_1A6F37:
EventScript_1A6F3F:
special GetMomOrDadStringForTVMessage
- msgbox UnknownString_81A0E68, 4
+ msgbox UnknownString_81A0E68, MSGBOX_DEFAULT
goto EventScript_1A6F37
end