diff options
Diffstat (limited to 'data/scripts')
47 files changed, 1854 insertions, 2620 deletions
diff --git a/data/scripts/abnormal_weather.inc b/data/scripts/abnormal_weather.inc index 9af24c45d..c5b03a970 100644 --- a/data/scripts/abnormal_weather.inc +++ b/data/scripts/abnormal_weather.inc @@ -1,161 +1,161 @@ AbnormalWeather_EventScript_PlaceTilesRoute114North:: - setmetatile 7, 3, METATILE_Fallarbor_RedCaveEntrance_Top, 1 - setmetatile 7, 4, METATILE_Fallarbor_RedCaveEntrance_Bottom, 0 + setmetatile 7, 3, METATILE_Fallarbor_RedCaveEntrance_Top, TRUE + setmetatile 7, 4, METATILE_Fallarbor_RedCaveEntrance_Bottom, FALSE return AbnormalWeather_EventScript_PlaceTilesRoute114South:: - setmetatile 6, 45, METATILE_Fallarbor_BrownCaveEntrance_Top, 1 - setmetatile 6, 46, METATILE_Fallarbor_BrownCaveEntrance_Bottom, 0 + setmetatile 6, 45, METATILE_Fallarbor_BrownCaveEntrance_Top, TRUE + setmetatile 6, 46, METATILE_Fallarbor_BrownCaveEntrance_Bottom, FALSE return AbnormalWeather_EventScript_PlaceTilesRoute115West:: - setmetatile 21, 5, METATILE_Fallarbor_BrownCaveEntrance_Top, 1 - setmetatile 21, 6, METATILE_Fallarbor_BrownCaveEntrance_Bottom, 0 + setmetatile 21, 5, METATILE_Fallarbor_BrownCaveEntrance_Top, TRUE + setmetatile 21, 6, METATILE_Fallarbor_BrownCaveEntrance_Bottom, FALSE return AbnormalWeather_EventScript_PlaceTilesRoute115East:: - setmetatile 36, 9, METATILE_Fallarbor_BrownCaveEntrance_Top, 1 - setmetatile 36, 10, METATILE_Fallarbor_BrownCaveEntrance_Bottom, 0 + setmetatile 36, 9, METATILE_Fallarbor_BrownCaveEntrance_Top, TRUE + setmetatile 36, 10, METATILE_Fallarbor_BrownCaveEntrance_Bottom, FALSE return AbnormalWeather_EventScript_PlaceTilesRoute116North:: - setmetatile 59, 12, METATILE_General_CaveEntrance_Top, 1 - setmetatile 59, 13, METATILE_General_CaveEntrance_Bottom, 0 + setmetatile 59, 12, METATILE_General_CaveEntrance_Top, TRUE + setmetatile 59, 13, METATILE_General_CaveEntrance_Bottom, FALSE return AbnormalWeather_EventScript_PlaceTilesRoute116South:: - setmetatile 79, 5, METATILE_General_CaveEntrance_Top, 1 - setmetatile 79, 6, METATILE_General_CaveEntrance_Bottom, 0 + setmetatile 79, 5, METATILE_General_CaveEntrance_Top, TRUE + setmetatile 79, 6, METATILE_General_CaveEntrance_Bottom, FALSE return AbnormalWeather_EventScript_PlaceTilesRoute118East:: - setmetatile 42, 5, METATILE_General_CaveEntrance_Top, 1 - setmetatile 42, 6, METATILE_General_CaveEntrance_Bottom, 0 + setmetatile 42, 5, METATILE_General_CaveEntrance_Top, TRUE + setmetatile 42, 6, METATILE_General_CaveEntrance_Bottom, FALSE return AbnormalWeather_EventScript_PlaceTilesRoute118West:: - setmetatile 9, 5, METATILE_General_CaveEntrance_Top, 1 - setmetatile 9, 6, METATILE_General_CaveEntrance_Bottom, 0 + setmetatile 9, 5, METATILE_General_CaveEntrance_Top, TRUE + setmetatile 9, 6, METATILE_General_CaveEntrance_Bottom, FALSE return AbnormalWeather_EventScript_PlaceTilesRoute105North:: - setmetatile 10, 28, METATILE_General_RoughWater, 0 - setmetatile 11, 28, METATILE_General_RoughWater, 0 - setmetatile 9, 29, METATILE_General_RoughWater, 0 - setmetatile 10, 29, METATILE_General_RoughDeepWater, 0 - setmetatile 11, 29, METATILE_General_RoughDeepWater, 0 - setmetatile 12, 29, METATILE_General_RoughWater, 0 - setmetatile 9, 30, METATILE_General_RoughWater, 0 - setmetatile 10, 30, METATILE_General_RoughDeepWater, 0 - setmetatile 11, 30, METATILE_General_RoughDeepWater, 0 - setmetatile 12, 30, METATILE_General_RoughWater, 0 - setmetatile 10, 31, METATILE_General_RoughWater, 0 - setmetatile 11, 31, METATILE_General_RoughWater, 0 + setmetatile 10, 28, METATILE_General_RoughWater, FALSE + setmetatile 11, 28, METATILE_General_RoughWater, FALSE + setmetatile 9, 29, METATILE_General_RoughWater, FALSE + setmetatile 10, 29, METATILE_General_RoughDeepWater, FALSE + setmetatile 11, 29, METATILE_General_RoughDeepWater, FALSE + setmetatile 12, 29, METATILE_General_RoughWater, FALSE + setmetatile 9, 30, METATILE_General_RoughWater, FALSE + setmetatile 10, 30, METATILE_General_RoughDeepWater, FALSE + setmetatile 11, 30, METATILE_General_RoughDeepWater, FALSE + setmetatile 12, 30, METATILE_General_RoughWater, FALSE + setmetatile 10, 31, METATILE_General_RoughWater, FALSE + setmetatile 11, 31, METATILE_General_RoughWater, FALSE return AbnormalWeather_EventScript_PlaceTilesRoute105South:: - setmetatile 20, 53, METATILE_General_RoughWater, 0 - setmetatile 21, 53, METATILE_General_RoughWater, 0 - setmetatile 19, 54, METATILE_General_RoughWater, 0 - setmetatile 20, 54, METATILE_General_RoughDeepWater, 0 - setmetatile 21, 54, METATILE_General_RoughDeepWater, 0 - setmetatile 22, 54, METATILE_General_RoughWater, 0 - setmetatile 19, 55, METATILE_General_RoughWater, 0 - setmetatile 20, 55, METATILE_General_RoughDeepWater, 0 - setmetatile 21, 55, METATILE_General_RoughDeepWater, 0 - setmetatile 22, 55, METATILE_General_RoughWater, 0 - setmetatile 20, 56, METATILE_General_RoughWater, 0 - setmetatile 21, 56, METATILE_General_RoughWater, 0 + setmetatile 20, 53, METATILE_General_RoughWater, FALSE + setmetatile 21, 53, METATILE_General_RoughWater, FALSE + setmetatile 19, 54, METATILE_General_RoughWater, FALSE + setmetatile 20, 54, METATILE_General_RoughDeepWater, FALSE + setmetatile 21, 54, METATILE_General_RoughDeepWater, FALSE + setmetatile 22, 54, METATILE_General_RoughWater, FALSE + setmetatile 19, 55, METATILE_General_RoughWater, FALSE + setmetatile 20, 55, METATILE_General_RoughDeepWater, FALSE + setmetatile 21, 55, METATILE_General_RoughDeepWater, FALSE + setmetatile 22, 55, METATILE_General_RoughWater, FALSE + setmetatile 20, 56, METATILE_General_RoughWater, FALSE + setmetatile 21, 56, METATILE_General_RoughWater, FALSE return AbnormalWeather_EventScript_PlaceTilesRoute125West:: - setmetatile 8, 16, METATILE_General_RoughWater, 0 - setmetatile 9, 16, METATILE_General_RoughWater, 0 - setmetatile 7, 17, METATILE_General_RoughWater, 0 - setmetatile 8, 17, METATILE_General_RoughDeepWater, 0 - setmetatile 9, 17, METATILE_General_RoughDeepWater, 0 - setmetatile 10, 17, METATILE_General_RoughWater, 0 - setmetatile 7, 18, METATILE_General_RoughWater, 0 - setmetatile 8, 18, METATILE_General_RoughDeepWater, 0 - setmetatile 9, 18, METATILE_General_RoughDeepWater, 0 - setmetatile 10, 18, METATILE_General_RoughWater, 0 - setmetatile 8, 19, METATILE_General_RoughWater, 0 - setmetatile 9, 19, METATILE_General_RoughWater, 0 + setmetatile 8, 16, METATILE_General_RoughWater, FALSE + setmetatile 9, 16, METATILE_General_RoughWater, FALSE + setmetatile 7, 17, METATILE_General_RoughWater, FALSE + setmetatile 8, 17, METATILE_General_RoughDeepWater, FALSE + setmetatile 9, 17, METATILE_General_RoughDeepWater, FALSE + setmetatile 10, 17, METATILE_General_RoughWater, FALSE + setmetatile 7, 18, METATILE_General_RoughWater, FALSE + setmetatile 8, 18, METATILE_General_RoughDeepWater, FALSE + setmetatile 9, 18, METATILE_General_RoughDeepWater, FALSE + setmetatile 10, 18, METATILE_General_RoughWater, FALSE + setmetatile 8, 19, METATILE_General_RoughWater, FALSE + setmetatile 9, 19, METATILE_General_RoughWater, FALSE return AbnormalWeather_EventScript_PlaceTilesRoute125East:: - setmetatile 53, 18, METATILE_General_RoughWater, 0 - setmetatile 54, 18, METATILE_General_RoughWater, 0 - setmetatile 52, 19, METATILE_General_RoughWater, 0 - setmetatile 53, 19, METATILE_General_RoughDeepWater, 0 - setmetatile 54, 19, METATILE_General_RoughDeepWater, 0 - setmetatile 55, 19, METATILE_General_RoughWater, 0 - setmetatile 52, 20, METATILE_General_RoughWater, 0 - setmetatile 53, 20, METATILE_General_RoughDeepWater, 0 - setmetatile 54, 20, METATILE_General_RoughDeepWater, 0 - setmetatile 55, 20, METATILE_General_RoughWater, 0 - setmetatile 53, 21, METATILE_General_RoughWater, 0 - setmetatile 54, 21, METATILE_General_RoughWater, 0 + setmetatile 53, 18, METATILE_General_RoughWater, FALSE + setmetatile 54, 18, METATILE_General_RoughWater, FALSE + setmetatile 52, 19, METATILE_General_RoughWater, FALSE + setmetatile 53, 19, METATILE_General_RoughDeepWater, FALSE + setmetatile 54, 19, METATILE_General_RoughDeepWater, FALSE + setmetatile 55, 19, METATILE_General_RoughWater, FALSE + setmetatile 52, 20, METATILE_General_RoughWater, FALSE + setmetatile 53, 20, METATILE_General_RoughDeepWater, FALSE + setmetatile 54, 20, METATILE_General_RoughDeepWater, FALSE + setmetatile 55, 20, METATILE_General_RoughWater, FALSE + setmetatile 53, 21, METATILE_General_RoughWater, FALSE + setmetatile 54, 21, METATILE_General_RoughWater, FALSE return AbnormalWeather_EventScript_PlaceTilesRoute127North:: - setmetatile 57, 9, METATILE_General_RoughWater, 0 - setmetatile 58, 9, METATILE_General_RoughWater, 0 - setmetatile 56, 10, METATILE_General_RoughWater, 0 - setmetatile 57, 10, METATILE_General_RoughDeepWater, 0 - setmetatile 58, 10, METATILE_General_RoughDeepWater, 0 - setmetatile 59, 10, METATILE_General_RoughWater, 0 - setmetatile 56, 11, METATILE_General_RoughWater, 0 - setmetatile 57, 11, METATILE_General_RoughDeepWater, 0 - setmetatile 58, 11, METATILE_General_RoughDeepWater, 0 - setmetatile 59, 11, METATILE_General_RoughWater, 0 - setmetatile 57, 12, METATILE_General_RoughWater, 0 - setmetatile 58, 12, METATILE_General_RoughWater, 0 + setmetatile 57, 9, METATILE_General_RoughWater, FALSE + setmetatile 58, 9, METATILE_General_RoughWater, FALSE + setmetatile 56, 10, METATILE_General_RoughWater, FALSE + setmetatile 57, 10, METATILE_General_RoughDeepWater, FALSE + setmetatile 58, 10, METATILE_General_RoughDeepWater, FALSE + setmetatile 59, 10, METATILE_General_RoughWater, FALSE + setmetatile 56, 11, METATILE_General_RoughWater, FALSE + setmetatile 57, 11, METATILE_General_RoughDeepWater, FALSE + setmetatile 58, 11, METATILE_General_RoughDeepWater, FALSE + setmetatile 59, 11, METATILE_General_RoughWater, FALSE + setmetatile 57, 12, METATILE_General_RoughWater, FALSE + setmetatile 58, 12, METATILE_General_RoughWater, FALSE return AbnormalWeather_EventScript_PlaceTilesRoute127South:: - setmetatile 61, 30, METATILE_General_RoughWater, 0 - setmetatile 62, 30, METATILE_General_RoughWater, 0 - setmetatile 60, 31, METATILE_General_RoughWater, 0 - setmetatile 61, 31, METATILE_General_RoughDeepWater, 0 - setmetatile 62, 31, METATILE_General_RoughDeepWater, 0 - setmetatile 63, 31, METATILE_General_RoughWater, 0 - setmetatile 60, 32, METATILE_General_RoughWater, 0 - setmetatile 61, 32, METATILE_General_RoughDeepWater, 0 - setmetatile 62, 32, METATILE_General_RoughDeepWater, 0 - setmetatile 63, 32, METATILE_General_RoughWater, 0 - setmetatile 61, 33, METATILE_General_RoughWater, 0 - setmetatile 62, 33, METATILE_General_RoughWater, 0 + setmetatile 61, 30, METATILE_General_RoughWater, FALSE + setmetatile 62, 30, METATILE_General_RoughWater, FALSE + setmetatile 60, 31, METATILE_General_RoughWater, FALSE + setmetatile 61, 31, METATILE_General_RoughDeepWater, FALSE + setmetatile 62, 31, METATILE_General_RoughDeepWater, FALSE + setmetatile 63, 31, METATILE_General_RoughWater, FALSE + setmetatile 60, 32, METATILE_General_RoughWater, FALSE + setmetatile 61, 32, METATILE_General_RoughDeepWater, FALSE + setmetatile 62, 32, METATILE_General_RoughDeepWater, FALSE + setmetatile 63, 32, METATILE_General_RoughWater, FALSE + setmetatile 61, 33, METATILE_General_RoughWater, FALSE + setmetatile 62, 33, METATILE_General_RoughWater, FALSE return AbnormalWeather_EventScript_PlaceTilesRoute129West:: - setmetatile 16, 14, METATILE_General_RoughWater, 0 - setmetatile 17, 14, METATILE_General_RoughWater, 0 - setmetatile 15, 15, METATILE_General_RoughWater, 0 - setmetatile 16, 15, METATILE_General_RoughDeepWater, 0 - setmetatile 17, 15, METATILE_General_RoughDeepWater, 0 - setmetatile 18, 15, METATILE_General_RoughWater, 0 - setmetatile 15, 16, METATILE_General_RoughWater, 0 - setmetatile 16, 16, METATILE_General_RoughDeepWater, 0 - setmetatile 17, 16, METATILE_General_RoughDeepWater, 0 - setmetatile 18, 16, METATILE_General_RoughWater, 0 - setmetatile 16, 17, METATILE_General_RoughWater, 0 - setmetatile 17, 17, METATILE_General_RoughWater, 0 + setmetatile 16, 14, METATILE_General_RoughWater, FALSE + setmetatile 17, 14, METATILE_General_RoughWater, FALSE + setmetatile 15, 15, METATILE_General_RoughWater, FALSE + setmetatile 16, 15, METATILE_General_RoughDeepWater, FALSE + setmetatile 17, 15, METATILE_General_RoughDeepWater, FALSE + setmetatile 18, 15, METATILE_General_RoughWater, FALSE + setmetatile 15, 16, METATILE_General_RoughWater, FALSE + setmetatile 16, 16, METATILE_General_RoughDeepWater, FALSE + setmetatile 17, 16, METATILE_General_RoughDeepWater, FALSE + setmetatile 18, 16, METATILE_General_RoughWater, FALSE + setmetatile 16, 17, METATILE_General_RoughWater, FALSE + setmetatile 17, 17, METATILE_General_RoughWater, FALSE return AbnormalWeather_EventScript_PlaceTilesRoute129East:: - setmetatile 42, 19, METATILE_General_RoughWater, 0 - setmetatile 43, 19, METATILE_General_RoughWater, 0 - setmetatile 41, 20, METATILE_General_RoughWater, 0 - setmetatile 42, 20, METATILE_General_RoughDeepWater, 0 - setmetatile 43, 20, METATILE_General_RoughDeepWater, 0 - setmetatile 44, 20, METATILE_General_RoughWater, 0 - setmetatile 41, 21, METATILE_General_RoughWater, 0 - setmetatile 42, 21, METATILE_General_RoughDeepWater, 0 - setmetatile 43, 21, METATILE_General_RoughDeepWater, 0 - setmetatile 44, 21, METATILE_General_RoughWater, 0 - setmetatile 42, 22, METATILE_General_RoughWater, 0 - setmetatile 43, 22, METATILE_General_RoughWater, 0 + setmetatile 42, 19, METATILE_General_RoughWater, FALSE + setmetatile 43, 19, METATILE_General_RoughWater, FALSE + setmetatile 41, 20, METATILE_General_RoughWater, FALSE + setmetatile 42, 20, METATILE_General_RoughDeepWater, FALSE + setmetatile 43, 20, METATILE_General_RoughDeepWater, FALSE + setmetatile 44, 20, METATILE_General_RoughWater, FALSE + setmetatile 41, 21, METATILE_General_RoughWater, FALSE + setmetatile 42, 21, METATILE_General_RoughDeepWater, FALSE + setmetatile 43, 21, METATILE_General_RoughDeepWater, FALSE + setmetatile 44, 21, METATILE_General_RoughWater, FALSE + setmetatile 42, 22, METATILE_General_RoughWater, FALSE + setmetatile 43, 22, METATILE_General_RoughWater, FALSE return AbnormalWeather_EventScript_HideMapNamePopup:: @@ -172,8 +172,7 @@ AbnormalWeather_StartGroudonWeather:: AbnormalWeather_EventScript_EndEventAndCleanup_1:: lockall - compare VAR_ABNORMAL_WEATHER_LOCATION, MARINE_CAVE_LOCATIONS_START - goto_if_ge AbnormalWeather_EventScript_ShowRainEndedMessage + goto_if_ge VAR_ABNORMAL_WEATHER_LOCATION, MARINE_CAVE_LOCATIONS_START, AbnormalWeather_EventScript_ShowRainEndedMessage goto AbnormalWeather_EventScript_ShowSunEndedMessage end @@ -222,163 +221,163 @@ AbnormalWeather_EventScript_CleanupMapTiles:: return AbnormalWeather_EventScript_CleanupRoute114North:: - setmetatile 7, 3, METATILE_Fallarbor_RedRockWall, 1 - setmetatile 7, 4, METATILE_Fallarbor_RedRockWall, 1 + setmetatile 7, 3, METATILE_Fallarbor_RedRockWall, TRUE + setmetatile 7, 4, METATILE_Fallarbor_RedRockWall, TRUE return AbnormalWeather_EventScript_CleanupRoute114South:: - setmetatile 6, 45, METATILE_Fallarbor_BrownRockWall, 1 - setmetatile 6, 46, METATILE_Fallarbor_BrownRockWall, 1 + setmetatile 6, 45, METATILE_Fallarbor_BrownRockWall, TRUE + setmetatile 6, 46, METATILE_Fallarbor_BrownRockWall, TRUE return AbnormalWeather_EventScript_CleanupRoute115West:: - setmetatile 21, 5, METATILE_Fallarbor_BrownRockWall, 1 - setmetatile 21, 6, METATILE_Fallarbor_BrownRockWall, 1 + setmetatile 21, 5, METATILE_Fallarbor_BrownRockWall, TRUE + setmetatile 21, 6, METATILE_Fallarbor_BrownRockWall, TRUE return AbnormalWeather_EventScript_CleanupRoute115East:: - setmetatile 36, 9, METATILE_Fallarbor_BrownRockWall, 1 - setmetatile 36, 10, METATILE_Fallarbor_BrownRockWall, 1 + setmetatile 36, 9, METATILE_Fallarbor_BrownRockWall, TRUE + setmetatile 36, 10, METATILE_Fallarbor_BrownRockWall, TRUE return AbnormalWeather_EventScript_CleanupRoute116North:: - setmetatile 59, 12, METATILE_General_RockWall_RockBase, 1 - setmetatile 59, 13, METATILE_General_RockWall_RockBase, 1 + setmetatile 59, 12, METATILE_General_RockWall_RockBase, TRUE + setmetatile 59, 13, METATILE_General_RockWall_RockBase, TRUE return AbnormalWeather_EventScript_CleanupRoute116South:: - setmetatile 79, 5, METATILE_General_RockWall_RockBase, 1 - setmetatile 79, 6, METATILE_General_RockWall_RockBase, 1 + setmetatile 79, 5, METATILE_General_RockWall_RockBase, TRUE + setmetatile 79, 6, METATILE_General_RockWall_RockBase, TRUE return AbnormalWeather_EventScript_CleanupRoute118East:: - setmetatile 42, 5, METATILE_General_RockWall_RockBase, 1 - setmetatile 42, 6, METATILE_General_RockWall_GrassBase, 1 + setmetatile 42, 5, METATILE_General_RockWall_RockBase, TRUE + setmetatile 42, 6, METATILE_General_RockWall_GrassBase, TRUE return AbnormalWeather_EventScript_CleanupRoute118West:: - setmetatile 9, 5, METATILE_General_RockWall_RockBase, 1 - setmetatile 9, 6, METATILE_General_RockWall_GrassBase, 1 + setmetatile 9, 5, METATILE_General_RockWall_RockBase, TRUE + setmetatile 9, 6, METATILE_General_RockWall_GrassBase, TRUE return AbnormalWeather_EventScript_CleanupRoute105North:: - setmetatile 10, 28, METATILE_General_CalmWater, 0 - setmetatile 11, 28, METATILE_General_CalmWater, 0 - setmetatile 9, 29, METATILE_General_CalmWater, 0 - setmetatile 10, 29, METATILE_General_CalmWater, 0 - setmetatile 11, 29, METATILE_General_CalmWater, 0 - setmetatile 12, 29, METATILE_General_CalmWater, 0 - setmetatile 9, 30, METATILE_General_CalmWater, 0 - setmetatile 10, 30, METATILE_General_CalmWater, 0 - setmetatile 11, 30, METATILE_General_CalmWater, 0 - setmetatile 12, 30, METATILE_General_CalmWater, 0 - setmetatile 10, 31, METATILE_General_CalmWater, 0 - setmetatile 11, 31, METATILE_General_CalmWater, 0 + setmetatile 10, 28, METATILE_General_CalmWater, FALSE + setmetatile 11, 28, METATILE_General_CalmWater, FALSE + setmetatile 9, 29, METATILE_General_CalmWater, FALSE + setmetatile 10, 29, METATILE_General_CalmWater, FALSE + setmetatile 11, 29, METATILE_General_CalmWater, FALSE + setmetatile 12, 29, METATILE_General_CalmWater, FALSE + setmetatile 9, 30, METATILE_General_CalmWater, FALSE + setmetatile 10, 30, METATILE_General_CalmWater, FALSE + setmetatile 11, 30, METATILE_General_CalmWater, FALSE + setmetatile 12, 30, METATILE_General_CalmWater, FALSE + setmetatile 10, 31, METATILE_General_CalmWater, FALSE + setmetatile 11, 31, METATILE_General_CalmWater, FALSE return AbnormalWeather_EventScript_CleanupRoute105South:: - setmetatile 20, 53, METATILE_General_CalmWater, 0 - setmetatile 21, 53, METATILE_General_CalmWater, 0 - setmetatile 19, 54, METATILE_General_CalmWater, 0 - setmetatile 20, 54, METATILE_General_CalmWater, 0 - setmetatile 21, 54, METATILE_General_CalmWater, 0 - setmetatile 22, 54, METATILE_General_CalmWater, 0 - setmetatile 19, 55, METATILE_General_CalmWater, 0 - setmetatile 20, 55, METATILE_General_CalmWater, 0 - setmetatile 21, 55, METATILE_General_CalmWater, 0 - setmetatile 22, 55, METATILE_General_CalmWater, 0 - setmetatile 20, 56, METATILE_General_CalmWater, 0 - setmetatile 21, 56, METATILE_General_CalmWater, 0 + setmetatile 20, 53, METATILE_General_CalmWater, FALSE + setmetatile 21, 53, METATILE_General_CalmWater, FALSE + setmetatile 19, 54, METATILE_General_CalmWater, FALSE + setmetatile 20, 54, METATILE_General_CalmWater, FALSE + setmetatile 21, 54, METATILE_General_CalmWater, FALSE + setmetatile 22, 54, METATILE_General_CalmWater, FALSE + setmetatile 19, 55, METATILE_General_CalmWater, FALSE + setmetatile 20, 55, METATILE_General_CalmWater, FALSE + setmetatile 21, 55, METATILE_General_CalmWater, FALSE + setmetatile 22, 55, METATILE_General_CalmWater, FALSE + setmetatile 20, 56, METATILE_General_CalmWater, FALSE + setmetatile 21, 56, METATILE_General_CalmWater, FALSE return AbnormalWeather_EventScript_CleanupRoute125West:: - setmetatile 8, 16, METATILE_General_CalmWater, 0 - setmetatile 9, 16, METATILE_General_CalmWater, 0 - setmetatile 7, 17, METATILE_General_CalmWater, 0 - setmetatile 8, 17, METATILE_General_CalmWater, 0 - setmetatile 9, 17, METATILE_General_CalmWater, 0 - setmetatile 10, 17, METATILE_General_CalmWater, 0 - setmetatile 7, 18, METATILE_General_CalmWater, 0 - setmetatile 8, 18, METATILE_General_CalmWater, 0 - setmetatile 9, 18, METATILE_General_CalmWater, 0 - setmetatile 10, 18, METATILE_General_CalmWater, 0 - setmetatile 8, 19, METATILE_General_CalmWater, 0 - setmetatile 9, 19, METATILE_General_CalmWater, 0 + setmetatile 8, 16, METATILE_General_CalmWater, FALSE + setmetatile 9, 16, METATILE_General_CalmWater, FALSE + setmetatile 7, 17, METATILE_General_CalmWater, FALSE + setmetatile 8, 17, METATILE_General_CalmWater, FALSE + setmetatile 9, 17, METATILE_General_CalmWater, FALSE + setmetatile 10, 17, METATILE_General_CalmWater, FALSE + setmetatile 7, 18, METATILE_General_CalmWater, FALSE + setmetatile 8, 18, METATILE_General_CalmWater, FALSE + setmetatile 9, 18, METATILE_General_CalmWater, FALSE + setmetatile 10, 18, METATILE_General_CalmWater, FALSE + setmetatile 8, 19, METATILE_General_CalmWater, FALSE + setmetatile 9, 19, METATILE_General_CalmWater, FALSE return AbnormalWeather_EventScript_CleanupRoute125East:: - setmetatile 53, 18, METATILE_General_CalmWater, 0 - setmetatile 54, 18, METATILE_General_CalmWater, 0 - setmetatile 52, 19, METATILE_General_CalmWater, 0 - setmetatile 53, 19, METATILE_General_CalmWater, 0 - setmetatile 54, 19, METATILE_General_CalmWater, 0 - setmetatile 55, 19, METATILE_General_CalmWater, 0 - setmetatile 52, 20, METATILE_General_CalmWater, 0 - setmetatile 53, 20, METATILE_General_CalmWater, 0 - setmetatile 54, 20, METATILE_General_CalmWater, 0 - setmetatile 55, 20, METATILE_General_CalmWater, 0 - setmetatile 53, 21, METATILE_General_CalmWater, 0 - setmetatile 54, 21, METATILE_General_CalmWater, 0 + setmetatile 53, 18, METATILE_General_CalmWater, FALSE + setmetatile 54, 18, METATILE_General_CalmWater, FALSE + setmetatile 52, 19, METATILE_General_CalmWater, FALSE + setmetatile 53, 19, METATILE_General_CalmWater, FALSE + setmetatile 54, 19, METATILE_General_CalmWater, FALSE + setmetatile 55, 19, METATILE_General_CalmWater, FALSE + setmetatile 52, 20, METATILE_General_CalmWater, FALSE + setmetatile 53, 20, METATILE_General_CalmWater, FALSE + setmetatile 54, 20, METATILE_General_CalmWater, FALSE + setmetatile 55, 20, METATILE_General_CalmWater, FALSE + setmetatile 53, 21, METATILE_General_CalmWater, FALSE + setmetatile 54, 21, METATILE_General_CalmWater, FALSE return AbnormalWeather_EventScript_CleanupRoute127North:: - setmetatile 57, 9, METATILE_General_CalmWater, 0 - setmetatile 58, 9, METATILE_General_CalmWater, 0 - setmetatile 56, 10, METATILE_General_CalmWater, 0 - setmetatile 57, 10, METATILE_General_CalmWater, 0 - setmetatile 58, 10, METATILE_General_CalmWater, 0 - setmetatile 59, 10, METATILE_General_CalmWater, 0 - setmetatile 56, 11, METATILE_General_CalmWater, 0 - setmetatile 57, 11, METATILE_General_CalmWater, 0 - setmetatile 58, 11, METATILE_General_CalmWater, 0 - setmetatile 59, 11, METATILE_General_CalmWater, 0 - setmetatile 57, 12, METATILE_General_CalmWater, 0 - setmetatile 58, 12, METATILE_General_CalmWater, 0 + setmetatile 57, 9, METATILE_General_CalmWater, FALSE + setmetatile 58, 9, METATILE_General_CalmWater, FALSE + setmetatile 56, 10, METATILE_General_CalmWater, FALSE + setmetatile 57, 10, METATILE_General_CalmWater, FALSE + setmetatile 58, 10, METATILE_General_CalmWater, FALSE + setmetatile 59, 10, METATILE_General_CalmWater, FALSE + setmetatile 56, 11, METATILE_General_CalmWater, FALSE + setmetatile 57, 11, METATILE_General_CalmWater, FALSE + setmetatile 58, 11, METATILE_General_CalmWater, FALSE + setmetatile 59, 11, METATILE_General_CalmWater, FALSE + setmetatile 57, 12, METATILE_General_CalmWater, FALSE + setmetatile 58, 12, METATILE_General_CalmWater, FALSE return AbnormalWeather_EventScript_CleanupRoute127South:: - setmetatile 61, 30, METATILE_General_CalmWater, 0 - setmetatile 62, 30, METATILE_General_CalmWater, 0 - setmetatile 60, 31, METATILE_General_CalmWater, 0 - setmetatile 61, 31, METATILE_General_CalmWater, 0 - setmetatile 62, 31, METATILE_General_CalmWater, 0 - setmetatile 63, 31, METATILE_General_CalmWater, 0 - setmetatile 60, 32, METATILE_General_CalmWater, 0 - setmetatile 61, 32, METATILE_General_CalmWater, 0 - setmetatile 62, 32, METATILE_General_CalmWater, 0 - setmetatile 63, 32, METATILE_General_CalmWater, 0 - setmetatile 61, 33, METATILE_General_CalmWater, 0 - setmetatile 62, 33, METATILE_General_CalmWater, 0 + setmetatile 61, 30, METATILE_General_CalmWater, FALSE + setmetatile 62, 30, METATILE_General_CalmWater, FALSE + setmetatile 60, 31, METATILE_General_CalmWater, FALSE + setmetatile 61, 31, METATILE_General_CalmWater, FALSE + setmetatile 62, 31, METATILE_General_CalmWater, FALSE + setmetatile 63, 31, METATILE_General_CalmWater, FALSE + setmetatile 60, 32, METATILE_General_CalmWater, FALSE + setmetatile 61, 32, METATILE_General_CalmWater, FALSE + setmetatile 62, 32, METATILE_General_CalmWater, FALSE + setmetatile 63, 32, METATILE_General_CalmWater, FALSE + setmetatile 61, 33, METATILE_General_CalmWater, FALSE + setmetatile 62, 33, METATILE_General_CalmWater, FALSE return AbnormalWeather_EventScript_CleanupRoute129West:: - setmetatile 16, 14, METATILE_General_CalmWater, 0 - setmetatile 17, 14, METATILE_General_CalmWater, 0 - setmetatile 15, 15, METATILE_General_CalmWater, 0 - setmetatile 16, 15, METATILE_General_CalmWater, 0 - setmetatile 17, 15, METATILE_General_CalmWater, 0 - setmetatile 18, 15, METATILE_General_CalmWater, 0 - setmetatile 15, 16, METATILE_General_CalmWater, 0 - setmetatile 16, 16, METATILE_General_CalmWater, 0 - setmetatile 17, 16, METATILE_General_CalmWater, 0 - setmetatile 18, 16, METATILE_General_CalmWater, 0 - setmetatile 16, 17, METATILE_General_CalmWater, 0 - setmetatile 17, 17, METATILE_General_CalmWater, 0 + setmetatile 16, 14, METATILE_General_CalmWater, FALSE + setmetatile 17, 14, METATILE_General_CalmWater, FALSE + setmetatile 15, 15, METATILE_General_CalmWater, FALSE + setmetatile 16, 15, METATILE_General_CalmWater, FALSE + setmetatile 17, 15, METATILE_General_CalmWater, FALSE + setmetatile 18, 15, METATILE_General_CalmWater, FALSE + setmetatile 15, 16, METATILE_General_CalmWater, FALSE + setmetatile 16, 16, METATILE_General_CalmWater, FALSE + setmetatile 17, 16, METATILE_General_CalmWater, FALSE + setmetatile 18, 16, METATILE_General_CalmWater, FALSE + setmetatile 16, 17, METATILE_General_CalmWater, FALSE + setmetatile 17, 17, METATILE_General_CalmWater, FALSE return AbnormalWeather_EventScript_CleanupRoute129East:: - setmetatile 42, 19, METATILE_General_CalmWater, 0 - setmetatile 43, 19, METATILE_General_CalmWater, 0 - setmetatile 41, 20, METATILE_General_CalmWater, 0 - setmetatile 42, 20, METATILE_General_CalmWater, 0 - setmetatile 43, 20, METATILE_General_CalmWater, 0 - setmetatile 44, 20, METATILE_General_CalmWater, 0 - setmetatile 41, 21, METATILE_General_CalmWater, 0 - setmetatile 42, 21, METATILE_General_CalmWater, 0 - setmetatile 43, 21, METATILE_General_CalmWater, 0 - setmetatile 44, 21, METATILE_General_CalmWater, 0 - setmetatile 42, 22, METATILE_General_CalmWater, 0 - setmetatile 43, 22, METATILE_General_CalmWater, 0 + setmetatile 42, 19, METATILE_General_CalmWater, FALSE + setmetatile 43, 19, METATILE_General_CalmWater, FALSE + setmetatile 41, 20, METATILE_General_CalmWater, FALSE + setmetatile 42, 20, METATILE_General_CalmWater, FALSE + setmetatile 43, 20, METATILE_General_CalmWater, FALSE + setmetatile 44, 20, METATILE_General_CalmWater, FALSE + setmetatile 41, 21, METATILE_General_CalmWater, FALSE + setmetatile 42, 21, METATILE_General_CalmWater, FALSE + setmetatile 43, 21, METATILE_General_CalmWater, FALSE + setmetatile 44, 21, METATILE_General_CalmWater, FALSE + setmetatile 42, 22, METATILE_General_CalmWater, FALSE + setmetatile 43, 22, METATILE_General_CalmWater, FALSE return AbnormalWeather_Underwater_SetupEscapeWarp:: @@ -394,33 +393,33 @@ AbnormalWeather_Underwater_SetupEscapeWarp:: return AbnormalWeather_Underwater_SetupEscapeWarpRoute105North:: - setescapewarp MAP_ROUTE105, 255, 11, 29 + setescapewarp MAP_ROUTE105, 11, 29 return AbnormalWeather_Underwater_SetupEscapeWarpRoute105South:: - setescapewarp MAP_ROUTE105, 255, 21, 54 + setescapewarp MAP_ROUTE105, 21, 54 return AbnormalWeather_Underwater_SetupEscapeWarpRoute125West:: - setescapewarp MAP_ROUTE125, 255, 9, 17 + setescapewarp MAP_ROUTE125, 9, 17 return AbnormalWeather_Underwater_SetupEscapeWarpRoute125East:: - setescapewarp MAP_ROUTE125, 255, 54, 19 + setescapewarp MAP_ROUTE125, 54, 19 return AbnormalWeather_Underwater_SetupEscapeWarpRoute127North:: - setescapewarp MAP_ROUTE127, 255, 58, 10 + setescapewarp MAP_ROUTE127, 58, 10 return AbnormalWeather_Underwater_SetupEscapeWarpRoute127South:: - setescapewarp MAP_ROUTE127, 255, 62, 31 + setescapewarp MAP_ROUTE127, 62, 31 return AbnormalWeather_Underwater_SetupEscapeWarpRoute129West:: - setescapewarp MAP_ROUTE129, 255, 17, 15 + setescapewarp MAP_ROUTE129, 17, 15 return AbnormalWeather_Underwater_SetupEscapeWarpRoute129East:: - setescapewarp MAP_ROUTE129, 255, 43, 20 + setescapewarp MAP_ROUTE129, 43, 20 return diff --git a/data/scripts/apprentice.inc b/data/scripts/apprentice.inc index 2a6772a5d..6b3a99e72 100644 --- a/data/scripts/apprentice.inc +++ b/data/scripts/apprentice.inc @@ -4,40 +4,32 @@ BattleFrontier_BattleTowerLobby_EventScript_Apprentice:: lock faceplayer apprentice_gavelvlmode - compare VAR_RESULT, FALSE - goto_if_eq Apprentice_EventScript_FirstMeeting + goto_if_eq VAR_RESULT, FALSE, Apprentice_EventScript_FirstMeeting apprentice_shouldcheckgone - compare VAR_0x8004, FALSE @ Always TRUE here - goto_if_eq Apprentice_EventScript_AskQuestion + goto_if_eq VAR_0x8004, FALSE, Apprentice_EventScript_AskQuestion @ VAR_0x8004 always TRUE here goto_if_set FLAG_DAILY_APPRENTICE_LEAVES, Apprentice_EventScript_Gone Apprentice_EventScript_AskQuestion: apprentice_getquestion - compare VAR_RESULT, APPRENTICE_QUESTION_WHICH_MON - goto_if_eq Apprentice_EventScript_UseWhichMon - compare VAR_RESULT, APPRENTICE_QUESTION_WHAT_ITEM - goto_if_eq Apprentice_EventScript_UseWhatHeldItem - compare VAR_RESULT, APPRENTICE_QUESTION_WHICH_MOVE - goto_if_eq Apprentice_EventScript_UseWhichMove - compare VAR_RESULT, APPRENTICE_QUESTION_WHICH_FIRST - goto_if_eq Apprentice_EventScript_PutWhichMonFirst - compare VAR_RESULT, APPRENTICE_QUESTION_WIN_SPEECH - goto_if_eq Apprentice_EventScript_PickWinSpeech + goto_if_eq VAR_RESULT, APPRENTICE_QUESTION_WHICH_MON, Apprentice_EventScript_UseWhichMon + goto_if_eq VAR_RESULT, APPRENTICE_QUESTION_WHAT_ITEM, Apprentice_EventScript_UseWhatHeldItem + goto_if_eq VAR_RESULT, APPRENTICE_QUESTION_WHICH_MOVE, Apprentice_EventScript_UseWhichMove + goto_if_eq VAR_RESULT, APPRENTICE_QUESTION_WHICH_FIRST, Apprentice_EventScript_PutWhichMonFirst + goto_if_eq VAR_RESULT, APPRENTICE_QUESTION_WIN_SPEECH, Apprentice_EventScript_PickWinSpeech release releaseall end Apprentice_EventScript_FirstMeeting: - apprentice_buff 0, APPRENTICE_BUFF_NAME + apprentice_buff STR_VAR_1, APPRENTICE_BUFF_NAME apprentice_msg FALSE, APPRENTICE_MSG_PLEASE_TEACH Apprentice_EventScript_WhichLvlMode: apprentice_menu APPRENTICE_ASK_YES_NO - compare VAR_RESULT, 1 - goto_if_eq Apprentice_EventScript_RejectTeach + goto_if_eq VAR_RESULT, 1, Apprentice_EventScript_RejectTeach apprentice_msg FALSE, APPRENTICE_MSG_WHICH_LVL_MODE apprentice_menu APPRENTICE_ASK_WHICH_LEVEL apprentice_setlvlmode VAR_RESULT apprentice_shufflespecies - apprentice_buff 0, APPRENTICE_BUFF_LEVEL + apprentice_buff STR_VAR_1, APPRENTICE_BUFF_LEVEL apprentice_msg TRUE, APPRENTICE_MSG_THANKS_LVL_MODE call Apprentice_EventScript_SetHideFlags release @@ -54,22 +46,19 @@ Apprentice_EventScript_RejectTeach: Apprentice_EventScript_UseWhichMon: apprentice_initquestion APPRENTICE_QUESTION_WHICH_MON - apprentice_buff 0, APPRENTICE_BUFF_SPECIES1 - apprentice_buff 1, APPRENTICE_BUFF_SPECIES2 + apprentice_buff STR_VAR_1, APPRENTICE_BUFF_SPECIES1 + apprentice_buff STR_VAR_2, APPRENTICE_BUFF_SPECIES2 apprentice_msg FALSE, APPRENTICE_MSG_WHICH_MON apprentice_menu APPRENTICE_ASK_2SPECIES copyvar VAR_0x8005, VAR_RESULT - compare VAR_0x8005, 0 - call_if_eq Apprentice_EventScript_ChoseFirstMon - compare VAR_0x8005, 1 - call_if_eq Apprentice_EventScript_ChoseSecondMon + call_if_eq VAR_0x8005, 0, Apprentice_EventScript_ChoseFirstMon + call_if_eq VAR_0x8005, 1, Apprentice_EventScript_ChoseSecondMon apprentice_getnumpartymons apprentice_setpartymon VAR_RESULT apprentice_answeredquestion apprentice_getnumpartymons - compare VAR_RESULT, MULTI_PARTY_SIZE - call_if_eq Apprentice_EventScript_LastMonSelected - apprentice_buff 0, VAR_0x8007 + call_if_eq VAR_RESULT, MULTI_PARTY_SIZE, Apprentice_EventScript_LastMonSelected + apprentice_buff STR_VAR_1, VAR_0x8007 apprentice_freequestion apprentice_msg TRUE, APPRENTICE_MSG_THANKS_MON call Apprentice_EventScript_SetHideFlags @@ -94,19 +83,17 @@ Apprentice_EventScript_LastMonSelected: Apprentice_EventScript_UseWhatHeldItem: apprentice_initquestion APPRENTICE_QUESTION_WHAT_ITEM - apprentice_buff 0, APPRENTICE_BUFF_SPECIES3 + apprentice_buff STR_VAR_1, APPRENTICE_BUFF_SPECIES3 apprentice_msg TRUE, APPRENTICE_MSG_WHAT_HELD_ITEM apprentice_freequestion Apprentice_EventScript_ChooseHoldItem: fadescreen FADE_TO_BLACK setvar VAR_RESULT, 0 apprentice_openbag - compare VAR_RESULT, FALSE - goto_if_eq Apprentice_EventScript_ConfirmHoldNothing + goto_if_eq VAR_RESULT, FALSE, Apprentice_EventScript_ConfirmHoldNothing apprentice_trysetitem - compare VAR_RESULT, FALSE - goto_if_eq Apprentice_EventScript_AlreadySuggestedItem - apprentice_buff 0, APPRENTICE_BUFF_ITEM + goto_if_eq VAR_RESULT, FALSE, Apprentice_EventScript_AlreadySuggestedItem + apprentice_buff STR_VAR_1, APPRENTICE_BUFF_ITEM apprentice_msg TRUE, APPRENTICE_MSG_THANKS_HELD_ITEM apprentice_answeredquestion call Apprentice_EventScript_SetHideFlags @@ -119,12 +106,11 @@ Apprentice_EventScript_ChooseHoldItem: Apprentice_EventScript_ConfirmHoldNothing: apprentice_initquestion APPRENTICE_QUESTION_WHAT_ITEM - apprentice_buff 0, APPRENTICE_BUFF_SPECIES3 + apprentice_buff STR_VAR_1, APPRENTICE_BUFF_SPECIES3 apprentice_msg FALSE, APPRENTICE_MSG_HOLD_NOTHING apprentice_menu APPRENTICE_ASK_GIVE apprentice_freequestion - compare VAR_RESULT, 0 - goto_if_eq Apprentice_EventScript_ChooseHoldItem + goto_if_eq VAR_RESULT, 0, Apprentice_EventScript_ChooseHoldItem Apprentice_EventScript_HoldNothing: apprentice_msg TRUE, APPRENTICE_MSG_THANKS_NO_HELD_ITEM apprentice_answeredquestion @@ -140,31 +126,28 @@ Apprentice_EventScript_HoldNothing: @ different item if theyve already told the Apprentice to use it for another mon Apprentice_EventScript_AlreadySuggestedItem: apprentice_initquestion APPRENTICE_QUESTION_WHAT_ITEM - apprentice_buff 0, APPRENTICE_BUFF_ITEM - apprentice_buff 1, APPRENTICE_BUFF_SPECIES3 + apprentice_buff STR_VAR_1, APPRENTICE_BUFF_ITEM + apprentice_buff STR_VAR_2, APPRENTICE_BUFF_SPECIES3 apprentice_msg FALSE, APPRENTICE_MSG_ITEM_ALREADY_SUGGESTED apprentice_menu APPRENTICE_ASK_GIVE apprentice_freequestion - compare VAR_RESULT, 0 - goto_if_eq Apprentice_EventScript_ChooseHoldItem + goto_if_eq VAR_RESULT, 0, Apprentice_EventScript_ChooseHoldItem goto Apprentice_EventScript_HoldNothing end Apprentice_EventScript_UseWhichMove: apprentice_initquestion APPRENTICE_QUESTION_WHICH_MOVE - apprentice_buff 0, APPRENTICE_BUFF_SPECIES3 - apprentice_buff 1, APPRENTICE_BUFF_MOVE1 - apprentice_buff 2, APPRENTICE_BUFF_MOVE2 + apprentice_buff STR_VAR_1, APPRENTICE_BUFF_SPECIES3 + apprentice_buff STR_VAR_2, APPRENTICE_BUFF_MOVE1 + apprentice_buff STR_VAR_3, APPRENTICE_BUFF_MOVE2 apprentice_msg FALSE, APPRENTICE_MSG_WHICH_MOVE apprentice_menu APPRENTICE_ASK_MOVES copyvar VAR_0x8005, VAR_RESULT - compare VAR_0x8005, 0 - call_if_eq Apprentice_EventScript_ChoseMove1 - compare VAR_0x8005, 1 - call_if_eq Apprentice_EventScript_ChoseMove2 + call_if_eq VAR_0x8005, 0, Apprentice_EventScript_ChoseMove1 + call_if_eq VAR_0x8005, 1, Apprentice_EventScript_ChoseMove2 apprentice_setmove apprentice_answeredquestion - apprentice_buff 0, VAR_0x8007 + apprentice_buff STR_VAR_1, VAR_0x8007 apprentice_freequestion apprentice_msg TRUE, APPRENTICE_MSG_THANKS_MOVE call Apprentice_EventScript_SetHideFlags @@ -188,7 +171,7 @@ Apprentice_EventScript_PutWhichMonFirst: apprentice_menu APPRENTICE_ASK_3SPECIES apprentice_setleadmon VAR_RESULT apprentice_answeredquestion - apprentice_buff 0, APPRENTICE_BUFF_LEAD_MON_SPECIES + apprentice_buff STR_VAR_1, APPRENTICE_BUFF_LEAD_MON_SPECIES apprentice_msg TRUE, APPRENTICE_MSG_THANKS_MON_FIRST call Apprentice_EventScript_SetHideFlags release @@ -207,7 +190,7 @@ Apprentice_EventScript_PickWinSpeech: lock faceplayer apprentice_save - apprentice_buff 0, APPRENTICE_BUFF_WIN_SPEECH + apprentice_buff STR_VAR_1, APPRENTICE_BUFF_WIN_SPEECH apprentice_msg TRUE, APPRENTICE_MSG_THANKS_WIN_SPEECH apprentice_reset call Apprentice_EventScript_SetHideFlags @@ -225,16 +208,14 @@ Apprentice_EventScript_SetHideFlags: Apprentice_EventScript_LeaveNorth: apprentice_shouldleave - compare VAR_0x8004, FALSE @ Always TRUE here - goto_if_eq Apprentice_EventScript_DontMove + goto_if_eq VAR_0x8004, FALSE, Apprentice_EventScript_DontMove @ VAR_0x8004 always TRUE here applymovement LOCALID_APPRENTICE, Apprentice_Movement_LeaveNorth waitmovement 0 end Apprentice_EventScript_Leave: apprentice_shouldleave - compare VAR_0x8004, FALSE @ Always TRUE here - goto_if_eq Apprentice_EventScript_DontMove + goto_if_eq VAR_0x8004, FALSE, Apprentice_EventScript_DontMove @ VAR_0x8004 always TRUE here applymovement LOCALID_APPRENTICE, Apprentice_Movement_Leave waitmovement 0 end diff --git a/data/scripts/battle_pike.inc b/data/scripts/battle_pike.inc index 3260bcfd8..8ca7f5b1a 100644 --- a/data/scripts/battle_pike.inc +++ b/data/scripts/battle_pike.inc @@ -50,14 +50,10 @@ BattleFrontier_BattlePikeRoomNormal_EventScript_InitRoomObjects:: setvar VAR_OBJ_GFX_ID_1, OBJ_EVENT_GFX_LINK_RECEPTIONIST setvar VAR_OBJ_GFX_ID_0, OBJ_EVENT_GFX_LINK_RECEPTIONIST pike_getroomtype - compare VAR_RESULT, PIKE_ROOM_STATUS - goto_if_eq BattleFrontier_BattlePikeRoomNormal_EventScript_InitTwoObjectRoom - compare VAR_RESULT, PIKE_ROOM_HARD_BATTLE - goto_if_eq BattleFrontier_BattlePikeRoomNormal_EventScript_InitTwoObjectRoom - compare VAR_RESULT, PIKE_ROOM_DOUBLE_BATTLE - goto_if_eq BattleFrontier_BattlePikeRoomNormal_EventScript_InitTwoObjectRoom - compare VAR_RESULT, PIKE_ROOM_BRAIN - goto_if_eq BattleFrontier_BattlePikeRoomNormal_EventScript_InitBrainRoomObjects + goto_if_eq VAR_RESULT, PIKE_ROOM_STATUS, BattleFrontier_BattlePikeRoomNormal_EventScript_InitTwoObjectRoom + goto_if_eq VAR_RESULT, PIKE_ROOM_HARD_BATTLE, BattleFrontier_BattlePikeRoomNormal_EventScript_InitTwoObjectRoom + goto_if_eq VAR_RESULT, PIKE_ROOM_DOUBLE_BATTLE, BattleFrontier_BattlePikeRoomNormal_EventScript_InitTwoObjectRoom + goto_if_eq VAR_RESULT, PIKE_ROOM_BRAIN, BattleFrontier_BattlePikeRoomNormal_EventScript_InitBrainRoomObjects hideobjectat LOCALID_OBJ_1, MAP_BATTLE_FRONTIER_BATTLE_PIKE_ROOM_NORMAL setvar VAR_TEMP_4, 1 turnobject OBJ_EVENT_ID_PLAYER, DIR_NORTH @@ -114,7 +110,7 @@ BattleFrontier_BattlePikeThreePathRoom_EventScript_WarpNPCRoom:: applymovement OBJ_EVENT_ID_PLAYER, BattleFrontier_BattlePikeRoom_Movement_HidePlayer waitmovement 0 call BattleFrontier_BattlePike_EventScript_CloseCurtain - warpsilent MAP_BATTLE_FRONTIER_BATTLE_PIKE_ROOM_NORMAL, 255, 4, 7 + warpsilent MAP_BATTLE_FRONTIER_BATTLE_PIKE_ROOM_NORMAL, 4, 7 waitstate end @@ -122,7 +118,7 @@ BattleFrontier_BattlePikeThreePathRoom_EventScript_WarpWildMonRoom:: applymovement OBJ_EVENT_ID_PLAYER, BattleFrontier_BattlePikeRoom_Movement_HidePlayer waitmovement 0 call BattleFrontier_BattlePike_EventScript_CloseCurtain - warpsilent MAP_BATTLE_FRONTIER_BATTLE_PIKE_ROOM_WILD_MONS, 255, 4, 19 + warpsilent MAP_BATTLE_FRONTIER_BATTLE_PIKE_ROOM_WILD_MONS, 4, 19 waitstate end @@ -154,10 +150,8 @@ BattleFrontier_BattlePikeRoomNormal_EventScript_NoTurningBack:: BattleFrontier_BattlePikeRoomNormal_EventScript_Exit:: pike_ispartyfullhealth - compare VAR_RESULT, TRUE - call_if_eq BattleFrontier_BattlePikeRoom_EventScript_DisableHealing - compare VAR_RESULT, TRUE - call_if_ne BattleFrontier_BattlePikeRoom_EventScript_EnableHealing + call_if_eq VAR_RESULT, TRUE, BattleFrontier_BattlePikeRoom_EventScript_DisableHealing + call_if_ne VAR_RESULT, TRUE, BattleFrontier_BattlePikeRoom_EventScript_EnableHealing pike_get PIKE_DATA_WIN_STREAK addvar VAR_RESULT, 1 pike_set PIKE_DATA_WIN_STREAK, VAR_RESULT @@ -165,10 +159,8 @@ BattleFrontier_BattlePikeRoomNormal_EventScript_Exit:: addvar VAR_RESULT, 1 frontier_set FRONTIER_DATA_BATTLE_NUM, VAR_RESULT pike_isfinalroom - compare VAR_RESULT, TRUE - call_if_eq BattleFrontier_BattlePikeRoom_EventScript_WarpToFinalRoom - compare VAR_RESULT, FALSE - call_if_eq BattleFrontier_BattlePikeRoom_EventScript_WarpToThreePathRoom + call_if_eq VAR_RESULT, TRUE, BattleFrontier_BattlePikeRoom_EventScript_WarpToFinalRoom + call_if_eq VAR_RESULT, FALSE, BattleFrontier_BattlePikeRoom_EventScript_WarpToThreePathRoom waitstate end @@ -184,23 +176,21 @@ BattleFrontier_BattlePikeRoom_EventScript_WarpToFinalRoom:: applymovement OBJ_EVENT_ID_PLAYER, BattleFrontier_BattlePikeRoom_Movement_HidePlayer waitmovement 0 call BattleFrontier_BattlePike_EventScript_CloseCurtain - warpsilent MAP_BATTLE_FRONTIER_BATTLE_PIKE_ROOM_FINAL, 255, 2, 7 + warpsilent MAP_BATTLE_FRONTIER_BATTLE_PIKE_ROOM_FINAL, 2, 7 return BattleFrontier_BattlePikeRoom_EventScript_WarpToThreePathRoom:: applymovement OBJ_EVENT_ID_PLAYER, BattleFrontier_BattlePikeRoom_Movement_HidePlayer waitmovement 0 call BattleFrontier_BattlePike_EventScript_CloseCurtain - warpsilent MAP_BATTLE_FRONTIER_BATTLE_PIKE_THREE_PATH_ROOM, 255, 6, 10 + warpsilent MAP_BATTLE_FRONTIER_BATTLE_PIKE_THREE_PATH_ROOM, 6, 10 return BattleFrontier_BattlePikeRoomWildMons_EventScript_Exit:: pike_exitwildmonroom pike_ispartyfullhealth - compare VAR_RESULT, TRUE - call_if_eq BattleFrontier_BattlePikeRoom_EventScript_DisableHealing - compare VAR_RESULT, TRUE - call_if_ne BattleFrontier_BattlePikeRoom_EventScript_EnableHealing + call_if_eq VAR_RESULT, TRUE, BattleFrontier_BattlePikeRoom_EventScript_DisableHealing + call_if_ne VAR_RESULT, TRUE, BattleFrontier_BattlePikeRoom_EventScript_EnableHealing pike_get PIKE_DATA_WIN_STREAK addvar VAR_RESULT, 1 pike_set PIKE_DATA_WIN_STREAK, VAR_RESULT @@ -208,10 +198,8 @@ BattleFrontier_BattlePikeRoomWildMons_EventScript_Exit:: addvar VAR_RESULT, 1 frontier_set FRONTIER_DATA_BATTLE_NUM, VAR_RESULT pike_isfinalroom - compare VAR_RESULT, TRUE - call_if_eq BattleFrontier_BattlePikeRoom_EventScript_WarpToFinalRoom - compare VAR_RESULT, FALSE - call_if_eq BattleFrontier_BattlePikeRoom_EventScript_WarpToThreePathRoom + call_if_eq VAR_RESULT, TRUE, BattleFrontier_BattlePikeRoom_EventScript_WarpToFinalRoom + call_if_eq VAR_RESULT, FALSE, BattleFrontier_BattlePikeRoom_EventScript_WarpToThreePathRoom waitstate end @@ -230,17 +218,15 @@ BattleFrontier_BattlePikeRoomWildMons_EventScript_NoTurningBack:: BattleFrontier_BattlePike_EventScript_Retire:: frontier_set FRONTIER_DATA_CHALLENGE_STATUS CHALLENGE_STATUS_LOST - warp MAP_BATTLE_FRONTIER_BATTLE_PIKE_LOBBY, 255, 5, 6 + warp MAP_BATTLE_FRONTIER_BATTLE_PIKE_LOBBY, 5, 6 waitstate end BattleFrontier_BattlePikeRoom_OnResume: setorcopyvar VAR_0x8006, VAR_RESULT @ Save VAR_RESULT from being overwritten frontier_get FRONTIER_DATA_CHALLENGE_STATUS - compare VAR_RESULT, CHALLENGE_STATUS_PAUSED - goto_if_eq BattleFrontier_BattlePikeThreePathRoom_EventScript_EndOnResume - compare VAR_RESULT, CHALLENGE_STATUS_SAVING - goto_if_eq BattleFrontier_BattlePikeThreePathRoom_EventScript_EndOnResume + goto_if_eq VAR_RESULT, CHALLENGE_STATUS_PAUSED, BattleFrontier_BattlePikeThreePathRoom_EventScript_EndOnResume + goto_if_eq VAR_RESULT, CHALLENGE_STATUS_SAVING, BattleFrontier_BattlePikeThreePathRoom_EventScript_EndOnResume call BattleFrontier_BattlePikeRoom_EventScript_ResetSketchedMoves BattleFrontier_BattlePikeThreePathRoom_EventScript_EndOnResume:: setorcopyvar VAR_RESULT, VAR_0x8006 diff --git a/data/scripts/berry_blender.inc b/data/scripts/berry_blender.inc index 1d833f470..f860ef066 100644 --- a/data/scripts/berry_blender.inc +++ b/data/scripts/berry_blender.inc @@ -249,8 +249,7 @@ BerryBlender_EventScript_BerryBlender1:: applymovement LOCALID_EXPERT_M, BerryBlender_Movement_BlendLeaderWalkInPlace waitmovement 0 msgbox BerryBlender_Text_WantToMakePokeblocks, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq BerryBlender_EventScript_TryUseBerryBlender1 + goto_if_eq VAR_RESULT, YES, BerryBlender_EventScript_TryUseBerryBlender1 goto BerryBlender_EventScript_DeclineBlender1 end @@ -280,8 +279,7 @@ BerryBlender_EventScript_Blender1GiveSpareBerry: BerryBlender_EventScript_UseBerryBlender1: msgbox BerryBlender_Text_KnowHowToMakePokeblocks, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq BerryBlender_EventScript_StartBlender1 + goto_if_eq VAR_RESULT, YES, BerryBlender_EventScript_StartBlender1 goto BerryBlender_EventScript_ExplainBlending1 end @@ -296,15 +294,12 @@ BerryBlender_EventScript_ExplainBlending1: end BerryBlender_EventScript_TryUseBerryBlender1: - checkitem ITEM_POKEBLOCK_CASE, 1 - compare VAR_RESULT, FALSE - goto_if_eq BerryBlender_EventScript_Blender1NoCase + checkitem ITEM_POKEBLOCK_CASE + goto_if_eq VAR_RESULT, FALSE, BerryBlender_EventScript_Blender1NoCase specialvar VAR_RESULT, GetFirstFreePokeblockSlot - compare VAR_RESULT, 65535 - goto_if_eq BerryBlender_EventScript_Blender1CaseFull + goto_if_eq VAR_RESULT, 65535, BerryBlender_EventScript_Blender1CaseFull specialvar VAR_RESULT, PlayerHasBerries - compare VAR_RESULT, FALSE - goto_if_eq BerryBlender_EventScript_Blender1NoBerries + goto_if_eq VAR_RESULT, FALSE, BerryBlender_EventScript_Blender1NoBerries msgbox BerryBlender_Text_Excellent, MSGBOX_DEFAULT goto BerryBlender_EventScript_UseBerryBlender1 end @@ -334,8 +329,7 @@ BerryBlender_EventScript_BerryBlender2:: applymovement LOCALID_MAN, BerryBlender_Movement_BlendLeaderWalkInPlace waitmovement 0 msgbox BerryBlender_Text_WantToBlendPokeblocksWithUs, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq BerryBlender_EventScript_TryUseBerryBlender2 + goto_if_eq VAR_RESULT, YES, BerryBlender_EventScript_TryUseBerryBlender2 goto BerryBlender_EventScript_DeclineBlender2 end @@ -351,8 +345,7 @@ BerryBlender_EventScript_Blender2NoBerries: BerryBlender_EventScript_UseBerryBlender2: msgbox BerryBlender_Text_KnowHowToMakePokeblocks2, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq BerryBlender_EventScript_StartBlender2 + goto_if_eq VAR_RESULT, YES, BerryBlender_EventScript_StartBlender2 goto BerryBlender_EventScript_ExplainBlending2 end @@ -368,17 +361,13 @@ BerryBlender_EventScript_ExplainBlending2: BerryBlender_EventScript_TryUseBerryBlender2: specialvar VAR_RESULT, PlayerHasBerries - compare VAR_RESULT, FALSE - goto_if_eq BerryBlender_EventScript_Blender2NoBerries - checkitem ITEM_POKEBLOCK_CASE, 1 - compare VAR_RESULT, FALSE - goto_if_eq BerryBlender_EventScript_Blender2NoCase + goto_if_eq VAR_RESULT, FALSE, BerryBlender_EventScript_Blender2NoBerries + checkitem ITEM_POKEBLOCK_CASE + goto_if_eq VAR_RESULT, FALSE, BerryBlender_EventScript_Blender2NoCase msgbox BerryBlender_Text_Okay, MSGBOX_DEFAULT specialvar VAR_RESULT, GetFirstFreePokeblockSlot - compare VAR_RESULT, 65535 - goto_if_ne BerryBlender_EventScript_UseBerryBlender2 - compare VAR_RESULT, 65535 - goto_if_eq BerryBlender_EventScript_Blender2CaseFull + goto_if_ne VAR_RESULT, 65535, BerryBlender_EventScript_UseBerryBlender2 + goto_if_eq VAR_RESULT, 65535, BerryBlender_EventScript_Blender2CaseFull end BerryBlender_EventScript_Blender2CaseFull: @@ -400,8 +389,7 @@ BerryBlender_EventScript_BerryBlender3:: applymovement VAR_0x8008, BerryBlender_Movement_BlendLeaderWalkInPlace waitmovement 0 msgbox BerryBlender_Text_LookGoodAtBlendingJoinUs, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq BerryBlender_EventScript_TryUseBlender3 + goto_if_eq VAR_RESULT, YES, BerryBlender_EventScript_TryUseBlender3 goto BerryBlender_EventScript_DeclineBlender3 end @@ -417,8 +405,7 @@ BerryBlender_EventScript_Blender3NoBerries: BerryBlender_EventScript_UseBerryBlender3: msgbox BerryBlender_Text_KnowHowToMakePokeblocks3, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq BerryBlender_EventScript_StartBlender3 + goto_if_eq VAR_RESULT, YES, BerryBlender_EventScript_StartBlender3 goto BerryBlender_EventScript_ExplainBlending3 end @@ -434,17 +421,13 @@ BerryBlender_EventScript_ExplainBlending3: BerryBlender_EventScript_TryUseBlender3: specialvar VAR_RESULT, PlayerHasBerries - compare VAR_RESULT, FALSE - goto_if_eq BerryBlender_EventScript_Blender3NoBerries - checkitem ITEM_POKEBLOCK_CASE, 1 - compare VAR_RESULT, FALSE - goto_if_eq BerryBlender_EventScript_Blender3NoCase + goto_if_eq VAR_RESULT, FALSE, BerryBlender_EventScript_Blender3NoBerries + checkitem ITEM_POKEBLOCK_CASE + goto_if_eq VAR_RESULT, FALSE, BerryBlender_EventScript_Blender3NoCase msgbox BerryBlender_Text_OhDear, MSGBOX_DEFAULT specialvar VAR_RESULT, GetFirstFreePokeblockSlot - compare VAR_RESULT, 65535 - goto_if_ne BerryBlender_EventScript_UseBerryBlender3 - compare VAR_RESULT, 65535 - goto_if_eq BerryBlender_EventScript_Blender3CaseFull + goto_if_ne VAR_RESULT, 65535, BerryBlender_EventScript_UseBerryBlender3 + goto_if_eq VAR_RESULT, 65535, BerryBlender_EventScript_Blender3CaseFull end BerryBlender_EventScript_Blender3CaseFull: @@ -461,8 +444,7 @@ BerryBlender_EventScript_BlendMasterPresent: lockall setvar NUM_OPPONENTS, 1 msgbox BerryBlender_Text_SeeMyMasteryInAction, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq BerryBlender_EventScript_TryBlendWithBlendMaster + goto_if_eq VAR_RESULT, YES, BerryBlender_EventScript_TryBlendWithBlendMaster msgbox BerryBlender_Text_TooBusyNowIsee, MSGBOX_DEFAULT releaseall end @@ -473,23 +455,18 @@ BerryBlender_EventScript_BlendMasterNoBerries: end BerryBlender_EventScript_TryBlendWithBlendMaster: - checkitem ITEM_POKEBLOCK_CASE, 1 - compare VAR_RESULT, FALSE - goto_if_eq BerryBlender_EventScript_BlendMasterNoCase + checkitem ITEM_POKEBLOCK_CASE + goto_if_eq VAR_RESULT, FALSE, BerryBlender_EventScript_BlendMasterNoCase specialvar VAR_RESULT, PlayerHasBerries - compare VAR_RESULT, FALSE - goto_if_eq BerryBlender_EventScript_BlendMasterNoBerries + goto_if_eq VAR_RESULT, FALSE, BerryBlender_EventScript_BlendMasterNoBerries specialvar VAR_RESULT, GetFirstFreePokeblockSlot - compare VAR_RESULT, 65535 - goto_if_ne BerryBlender_EventScript_BlendWithBlendMaster - compare VAR_RESULT, 65535 - goto_if_eq BerryBlender_EventScript_BlendMasterCaseFull + goto_if_ne VAR_RESULT, 65535, BerryBlender_EventScript_BlendWithBlendMaster + goto_if_eq VAR_RESULT, 65535, BerryBlender_EventScript_BlendMasterCaseFull end BerryBlender_EventScript_BlendWithBlendMaster: msgbox BerryBlender_Text_BlendMasterKnowHowToMakePokeblocks, MSGBOX_YESNO - compare VAR_RESULT, NO - call_if_eq BerryBlender_EventScript_BlendMasterExplainBlending + call_if_eq VAR_RESULT, NO, BerryBlender_EventScript_BlendMasterExplainBlending msgbox BerryBlender_Text_BlendMasterLetsBerryBlender, MSGBOX_DEFAULT goto BerryBlender_EventScript_DoBerryBlending end @@ -530,10 +507,8 @@ BerryBlender_EventScript_ExpertMCheckGiveBerry: faceplayer msgbox BerryBlender_Text_LoveMakingPokeblocks, MSGBOX_DEFAULT specialvar VAR_RESULT, PlayerHasBerries - compare VAR_RESULT, TRUE - goto_if_eq BerryBlender_EventScript_ExpertMPlayerHasBerries - compare VAR_RESULT, FALSE - goto_if_eq BerryBlender_EventScript_ExpertMNoBerries + goto_if_eq VAR_RESULT, TRUE, BerryBlender_EventScript_ExpertMPlayerHasBerries + goto_if_eq VAR_RESULT, FALSE, BerryBlender_EventScript_ExpertMNoBerries end BerryBlender_EventScript_ExpertMPlayerHasBerries: @@ -542,12 +517,10 @@ BerryBlender_EventScript_ExpertMPlayerHasBerries: end BerryBlender_EventScript_ExpertMNoBerries: - checkitem ITEM_POKEBLOCK_CASE, 1 - compare VAR_RESULT, FALSE - goto_if_eq BerryBlender_EventScript_ExpertMNoSpareBerries + checkitem ITEM_POKEBLOCK_CASE + goto_if_eq VAR_RESULT, FALSE, BerryBlender_EventScript_ExpertMNoSpareBerries specialvar VAR_RESULT, GetFirstFreePokeblockSlot - compare VAR_RESULT, 65535 - goto_if_eq BerryBlender_EventScript_ExpertMNoSpareBerries + goto_if_eq VAR_RESULT, 65535, BerryBlender_EventScript_ExpertMNoSpareBerries dotimebasedevents goto_if_set FLAG_DAILY_CONTEST_LOBBY_RECEIVED_BERRY, BerryBlender_EventScript_ExpertMNoSpareBerries goto BerryBlender_EventScript_ExpertMGiveBerry @@ -573,24 +546,18 @@ BerryBlender_Movement_BlendLeaderWalkInPlace: BerryBlender_EventScript_BerryBlenderLink:: lockall specialvar VAR_RESULT, PlayerHasBerries - compare VAR_RESULT, FALSE - goto_if_eq BerryBlender_EventScript_LinkBlenderNoBerries - checkitem ITEM_POKEBLOCK_CASE, 1 - compare VAR_RESULT, FALSE - goto_if_eq BerryBlender_EventScript_LinkBlenderNoCase + goto_if_eq VAR_RESULT, FALSE, BerryBlender_EventScript_LinkBlenderNoBerries + checkitem ITEM_POKEBLOCK_CASE + goto_if_eq VAR_RESULT, FALSE, BerryBlender_EventScript_LinkBlenderNoCase specialvar VAR_RESULT, GetFirstFreePokeblockSlot - compare VAR_RESULT, 65535 - goto_if_ne BerryBlender_EventScript_LinkBlenderSaveGame - compare VAR_RESULT, 65535 - goto_if_eq BerryBlender_EventScript_LinkBlenderCaseFull + goto_if_ne VAR_RESULT, 65535, BerryBlender_EventScript_LinkBlenderSaveGame + goto_if_eq VAR_RESULT, 65535, BerryBlender_EventScript_LinkBlenderCaseFull end BerryBlender_EventScript_LinkBlenderSaveGame: msgbox BerryBlender_Text_SaveGameBeforeBerryBlenderLink, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq BerryBlender_EventScript_TryDoLinkBlender - compare VAR_RESULT, NO - goto_if_eq BerryBlender_EventScript_CancelLinkBlender + goto_if_eq VAR_RESULT, YES, BerryBlender_EventScript_TryDoLinkBlender + goto_if_eq VAR_RESULT, NO, BerryBlender_EventScript_CancelLinkBlender end BerryBlender_EventScript_LinkBlenderNoBerries: @@ -600,25 +567,18 @@ BerryBlender_EventScript_LinkBlenderNoBerries: BerryBlender_EventScript_TryDoLinkBlender: call Common_EventScript_SaveGame - compare VAR_RESULT, FALSE - goto_if_eq BerryBlender_EventScript_CancelLinkBlender + goto_if_eq VAR_RESULT, FALSE, BerryBlender_EventScript_CancelLinkBlender specialvar VAR_RESULT, IsWirelessAdapterConnected - compare VAR_RESULT, TRUE - goto_if_eq BerryBlender_EventScript_StartDecideLinkLeader + goto_if_eq VAR_RESULT, TRUE, BerryBlender_EventScript_StartDecideLinkLeader message BerryBlender_Text_SearchingForFriends waitmessage special TryBerryBlenderLinkup waitstate - compare VAR_RESULT, LINKUP_SUCCESS - goto_if_eq BerryBlender_EventScript_SpawnLinkPartners - compare VAR_RESULT, LINKUP_SOMEONE_NOT_READY - goto_if_eq BerryBlender_EventScript_CloseLinkNotReady - compare VAR_RESULT, LINKUP_DIFF_SELECTIONS - goto_if_eq BerryBlender_EventScript_CloseLinkDifferentSelections - compare VAR_RESULT, LINKUP_FAILED - goto_if_eq BerryBlender_EventScript_CloseLink - compare VAR_RESULT, LINKUP_CONNECTION_ERROR - goto_if_eq BerryBlender_EventScript_LinkError + goto_if_eq VAR_RESULT, LINKUP_SUCCESS, BerryBlender_EventScript_SpawnLinkPartners + goto_if_eq VAR_RESULT, LINKUP_SOMEONE_NOT_READY, BerryBlender_EventScript_CloseLinkNotReady + goto_if_eq VAR_RESULT, LINKUP_DIFF_SELECTIONS, BerryBlender_EventScript_CloseLinkDifferentSelections + goto_if_eq VAR_RESULT, LINKUP_FAILED, BerryBlender_EventScript_CloseLink + goto_if_eq VAR_RESULT, LINKUP_CONNECTION_ERROR, BerryBlender_EventScript_LinkError end BerryBlender_EventScript_TwoPlayerLink: @@ -721,23 +681,17 @@ BerryBlender_EventScript_DecideLinkLeader: BerryBlender_EventScript_TryLeadGroup: call BerryBlender_EventScript_TryBecomeLinkLeader - compare VAR_RESULT, LINKUP_SUCCESS - goto_if_eq BerryBlender_EventScript_LinkLeaderDecided - compare VAR_RESULT, LINKUP_FAILED - goto_if_eq BerryBlender_EventScript_DecideLinkLeader - compare VAR_RESULT, LINKUP_RETRY_ROLE_ASSIGN - goto_if_eq BerryBlender_EventScript_TryLeadGroup + goto_if_eq VAR_RESULT, LINKUP_SUCCESS, BerryBlender_EventScript_LinkLeaderDecided + goto_if_eq VAR_RESULT, LINKUP_FAILED, BerryBlender_EventScript_DecideLinkLeader + goto_if_eq VAR_RESULT, LINKUP_RETRY_ROLE_ASSIGN, BerryBlender_EventScript_TryLeadGroup release end BerryBlender_EventScript_TryJoinGroup: call BerryBlender_EventScript_TryJoinLinkGroup - compare VAR_RESULT, LINKUP_SUCCESS - goto_if_eq BerryBlender_EventScript_LinkLeaderDecided - compare VAR_RESULT, LINKUP_FAILED - goto_if_eq BerryBlender_EventScript_DecideLinkLeader - compare VAR_RESULT, LINKUP_RETRY_ROLE_ASSIGN - goto_if_eq BerryBlender_EventScript_TryJoinGroup + goto_if_eq VAR_RESULT, LINKUP_SUCCESS, BerryBlender_EventScript_LinkLeaderDecided + goto_if_eq VAR_RESULT, LINKUP_FAILED, BerryBlender_EventScript_DecideLinkLeader + goto_if_eq VAR_RESULT, LINKUP_RETRY_ROLE_ASSIGN, BerryBlender_EventScript_TryJoinGroup release end diff --git a/data/scripts/berry_tree.inc b/data/scripts/berry_tree.inc index e415d0c65..8ad300df5 100644 --- a/data/scripts/berry_tree.inc +++ b/data/scripts/berry_tree.inc @@ -22,8 +22,7 @@ BerryTree_EventScript_CheckSoil:: lock faceplayer specialvar VAR_RESULT, PlayerHasBerries - compare VAR_RESULT, TRUE - goto_if_eq BerryTree_EventScript_WantToPlant + goto_if_eq VAR_RESULT, TRUE, BerryTree_EventScript_WantToPlant message BerryTree_Text_ItsSoftLoamySoil waitmessage waitbuttonpress @@ -32,10 +31,8 @@ BerryTree_EventScript_CheckSoil:: BerryTree_EventScript_WantToPlant:: msgbox BerryTree_Text_WantToPlant, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq BerryTree_EventScript_ChooseBerryToPlant - compare VAR_RESULT, NO - goto_if_eq BerryTree_EventScript_CancelPlanting + goto_if_eq VAR_RESULT, YES, BerryTree_EventScript_ChooseBerryToPlant + goto_if_eq VAR_RESULT, NO, BerryTree_EventScript_CancelPlanting end BerryTree_EventScript_ChooseBerryToPlant:: @@ -43,8 +40,7 @@ BerryTree_EventScript_ChooseBerryToPlant:: closemessage special Bag_ChooseBerry waitstate - compare VAR_ITEM_ID, 0 - goto_if_eq BerryTree_EventScript_CancelPlanting + goto_if_eq VAR_ITEM_ID, 0, BerryTree_EventScript_CancelPlanting removeitem VAR_ITEM_ID call BerryTree_EventScript_PlantBerry @@ -88,37 +84,32 @@ BerryTree_EventScript_CheckBerryStage4:: @ VAR_0x8005 here is the number of times watered @ Buffered by ObjectEventInteractionGetBerryTreeData BerryTree_EventScript_GetCareAdverb:: - compare VAR_0x8005, 0 - goto_if_eq BerryTree_EventScript_SetAdverbPoor - compare VAR_0x8005, 4 - goto_if_eq BerryTree_EventScript_SetAdverbGreat - bufferstring 1, BerryTree_Text_CareAdverbGood + goto_if_eq VAR_0x8005, 0, BerryTree_EventScript_SetAdverbPoor + goto_if_eq VAR_0x8005, 4, BerryTree_EventScript_SetAdverbGreat + bufferstring STR_VAR_2, BerryTree_Text_CareAdverbGood return BerryTree_EventScript_SetAdverbGreat:: - bufferstring 1, BerryTree_Text_CareAdverbGreat + bufferstring STR_VAR_2, BerryTree_Text_CareAdverbGreat return BerryTree_EventScript_SetAdverbPoor:: - bufferstring 1, BerryTree_Text_CareAdverbPoor + bufferstring STR_VAR_2, BerryTree_Text_CareAdverbPoor return @ VAR_0x8006 here is the number of berries BerryTree_EventScript_CheckBerryFullyGrown:: - buffernumberstring 1, VAR_0x8006 + buffernumberstring STR_VAR_2, VAR_0x8006 lock faceplayer special ObjectEventInteractionGetBerryCountString msgbox BerryTree_Text_WantToPick, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq BerryTree_EventScript_PickBerry - compare VAR_RESULT, NO - goto_if_eq BerryTree_EventScript_CancelPickingBerry + goto_if_eq VAR_RESULT, YES, BerryTree_EventScript_PickBerry + goto_if_eq VAR_RESULT, NO, BerryTree_EventScript_CancelPickingBerry BerryTree_EventScript_PickBerry:: special ObjectEventInteractionPickBerryTree - compare VAR_0x8004, 0 - goto_if_eq BerryTree_EventScript_BerryPocketFull + goto_if_eq VAR_0x8004, 0, BerryTree_EventScript_BerryPocketFull special IncrementDailyPickedBerries special ObjectEventInteractionRemoveBerryTree message BerryTree_Text_PickedTheBerry @@ -154,15 +145,12 @@ BerryTree_EventScript_ItemUsePlantBerry:: end BerryTree_EventScript_WantToWater:: - checkitem ITEM_WAILMER_PAIL, 1 - compare VAR_RESULT, 0 - goto_if_eq BerryTree_EventScript_DontWater + checkitem ITEM_WAILMER_PAIL + goto_if_eq VAR_RESULT, FALSE, BerryTree_EventScript_DontWater special ObjectEventInteractionGetBerryName msgbox BerryTree_Text_WantToWater, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq BerryTree_EventScript_WaterBerry - compare VAR_RESULT, NO - goto_if_eq BerryTree_EventScript_DontWater + goto_if_eq VAR_RESULT, YES, BerryTree_EventScript_WaterBerry + goto_if_eq VAR_RESULT, NO, BerryTree_EventScript_DontWater BerryTree_EventScript_DontWater:: releaseall diff --git a/data/scripts/cable_club.inc b/data/scripts/cable_club.inc index d6ea1a707..0ab93c403 100644 --- a/data/scripts/cable_club.inc +++ b/data/scripts/cable_club.inc @@ -4,11 +4,9 @@ CableClub_OnTransition: CableClub_EventScript_HideOrShowMysteryGiftMan:: specialvar VAR_RESULT, ShouldDistributeEonTicket - compare VAR_RESULT, TRUE - goto_if_eq CableClub_EventScript_ShowMysteryGiftMan + goto_if_eq VAR_RESULT, TRUE, CableClub_EventScript_ShowMysteryGiftMan specialvar VAR_RESULT, ValidateSavedWonderCard - compare VAR_RESULT, FALSE - goto_if_eq CableClub_EventScript_HideMysteryGiftMan + goto_if_eq VAR_RESULT, FALSE, CableClub_EventScript_HideMysteryGiftMan goto CableClub_EventScript_ShowMysteryGiftMan end @@ -22,24 +20,20 @@ CableClub_EventScript_HideMysteryGiftMan:: CableClub_EventScript_MysteryGiftMan:: specialvar VAR_RESULT, ShouldDistributeEonTicket - compare VAR_RESULT, TRUE - goto_if_eq CableClub_EventScript_DistributeEonTicket - goto CableClub_EventScript_AlreadyGotEonTicket + goto_if_eq VAR_RESULT, TRUE, CableClub_EventScript_DistributeEonTicket + goto CableClub_EventScript_TryWonderCardScript end -CableClub_EventScript_AlreadyGotEonTicket:: - gotoram - -@ Unused? +CableClub_EventScript_TryWonderCardScript:: + trywondercardscript CableClub_EventScript_MysteryGiftThankYou:: msgbox gText_ThankYouForAccessingMysteryGift, MSGBOX_NPC end CableClub_EventScript_DistributeEonTicket:: - checkitem ITEM_EON_TICKET, 1 - compare VAR_RESULT, TRUE - goto_if_eq CableClub_EventScript_AlreadyGotEonTicket - goto_if_set FLAG_ENABLE_SHIP_SOUTHERN_ISLAND, CableClub_EventScript_AlreadyGotEonTicket + checkitem ITEM_EON_TICKET + goto_if_eq VAR_RESULT, TRUE, CableClub_EventScript_TryWonderCardScript + goto_if_set FLAG_ENABLE_SHIP_SOUTHERN_ISLAND, CableClub_EventScript_TryWonderCardScript msgbox MysteryGift_Text_TheresATicketForYou, MSGBOX_DEFAULT giveitem ITEM_EON_TICKET setflag FLAG_ENABLE_SHIP_SOUTHERN_ISLAND @@ -66,29 +60,20 @@ CableClub_OnWarp: .2byte 0 CableClub_EventScript_CheckTurnAttendant:: - compare VAR_0x8007, 0 - goto_if_eq CableClub_EventScript_DontTurnAttendant + goto_if_eq VAR_0x8007, 0, CableClub_EventScript_DontTurnAttendant turnobject VAR_0x8007, DIR_WEST CableClub_EventScript_DontTurnAttendant:: end CableClub_OnLoad: - compare VAR_CABLE_CLUB_STATE, USING_SINGLE_BATTLE - goto_if_eq CableClub_EventScript_OnLoadFromColosseum - compare VAR_CABLE_CLUB_STATE, USING_DOUBLE_BATTLE - goto_if_eq CableClub_EventScript_OnLoadFromColosseum - compare VAR_CABLE_CLUB_STATE, USING_MULTI_BATTLE - goto_if_eq CableClub_EventScript_OnLoadFromColosseum - compare VAR_CABLE_CLUB_STATE, USING_TRADE_CENTER - goto_if_eq CableClub_EventScript_OnLoadFromTradeCenter - compare VAR_CABLE_CLUB_STATE, USING_RECORD_CORNER - goto_if_eq CableClub_EventScript_OnLoadFromRecordCorner - compare VAR_CABLE_CLUB_STATE, USING_UNION_ROOM - goto_if_eq CableClub_EventScript_OnLoadFromUnionRoom - compare VAR_CABLE_CLUB_STATE, USING_BERRY_CRUSH - goto_if_eq CableClub_EventScript_OnLoadFromBerryCrush - compare VAR_CABLE_CLUB_STATE, USING_MINIGAME - goto_if_eq CableClub_EventScript_OnLoadFromGameCorner + goto_if_eq VAR_CABLE_CLUB_STATE, USING_SINGLE_BATTLE, CableClub_EventScript_OnLoadFromColosseum + goto_if_eq VAR_CABLE_CLUB_STATE, USING_DOUBLE_BATTLE, CableClub_EventScript_OnLoadFromColosseum + goto_if_eq VAR_CABLE_CLUB_STATE, USING_MULTI_BATTLE, CableClub_EventScript_OnLoadFromColosseum + goto_if_eq VAR_CABLE_CLUB_STATE, USING_TRADE_CENTER, CableClub_EventScript_OnLoadFromTradeCenter + goto_if_eq VAR_CABLE_CLUB_STATE, USING_RECORD_CORNER, CableClub_EventScript_OnLoadFromRecordCorner + goto_if_eq VAR_CABLE_CLUB_STATE, USING_UNION_ROOM, CableClub_EventScript_OnLoadFromUnionRoom + goto_if_eq VAR_CABLE_CLUB_STATE, USING_BERRY_CRUSH, CableClub_EventScript_OnLoadFromBerryCrush + goto_if_eq VAR_CABLE_CLUB_STATE, USING_MINIGAME, CableClub_EventScript_OnLoadFromGameCorner end CableClub_EventScript_OnLoadFromColosseum:: @@ -150,8 +135,7 @@ CableClub_EventScript_ExitMinigameRoom:: CableClub_EventScript_CloseLinkAndExitLinkRoom:: special CloseLink setvar VAR_CABLE_CLUB_STATE, 0 - compare VAR_0x8007, 0 - goto_if_eq CableClub_EventScript_PlayerExitLinkRoom + goto_if_eq VAR_0x8007, 0, CableClub_EventScript_PlayerExitLinkRoom applymovement VAR_0x8007, Movement_AttendantFaceLeft waitmovement 0 applymovement OBJ_EVENT_ID_PLAYER, Movement_PlayerExitLinkRoom @@ -173,8 +157,7 @@ CableClub_EventScript_ExitTradeCenter:: CableClub_EventScript_PlayerExitTradeCenter:: special CloseLink setvar VAR_CABLE_CLUB_STATE, 0 - compare VAR_0x8007, 0 - goto_if_eq CableClub_EventScript_PlayerExitLinkRoom + goto_if_eq VAR_0x8007, 0, CableClub_EventScript_PlayerExitLinkRoom applymovement OBJ_EVENT_ID_PLAYER, Movement_PlayerFaceAttendantRight waitmovement 0 applymovement VAR_0x8007, Movement_AttendantFaceLeft @@ -197,8 +180,7 @@ CableClub_EventScript_PlayerExitRecordCorner:: setvar VAR_CABLE_CLUB_STATE, 0 applymovement OBJ_EVENT_ID_PLAYER, Movement_PlayerExitLinkRoom waitmovement 0 - compare VAR_0x8007, 0 - goto_if_eq CableClub_EventScript_ExitRecordCornerRet + goto_if_eq VAR_0x8007, 0, CableClub_EventScript_ExitRecordCornerRet applymovement VAR_0x8007, Movement_AttendantFaceDown waitmovement 0 CableClub_EventScript_ExitRecordCornerRet:: @@ -216,8 +198,7 @@ CableClub_EventScript_ExitUnionRoom:: CableClub_EventScript_PlayerExitUnionRoom:: setvar VAR_CABLE_CLUB_STATE, 0 - compare VAR_0x8007, 0 - goto_if_eq CableClub_EventScript_PlayerExitLinkRoom + goto_if_eq VAR_0x8007, 0, CableClub_EventScript_PlayerExitLinkRoom applymovement OBJ_EVENT_ID_PLAYER, Movement_PlayerFaceAttendantRight waitmovement 0 applymovement VAR_0x8007, Movement_AttendantFaceLeft @@ -325,8 +306,7 @@ CableClub_EventScript_SingleBattleMode:: CableClub_EventScript_DoubleBattleMode:: special HasEnoughMonsForDoubleBattle - compare VAR_RESULT, PLAYER_HAS_TWO_USABLE_MONS - goto_if_ne CableClub_EventScript_NeedTwoMonsForDoubleBattle + goto_if_ne VAR_RESULT, PLAYER_HAS_TWO_USABLE_MONS, CableClub_EventScript_NeedTwoMonsForDoubleBattle setvar VAR_0x8004, USING_DOUBLE_BATTLE goto CableClub_EventScript_TryEnterColosseum end @@ -343,24 +323,17 @@ CableClub_EventScript_MultiBattleMode:: CableClub_EventScript_TryEnterColosseum:: call Common_EventScript_SaveGame - compare VAR_RESULT, 0 - goto_if_eq CableClub_EventScript_AbortLink + goto_if_eq VAR_RESULT, 0, CableClub_EventScript_AbortLink message gText_PleaseWaitForLink waitmessage special TryBattleLinkup waitstate - compare VAR_RESULT, LINKUP_SUCCESS - goto_if_eq CableClub_EventScript_EnterColosseum - compare VAR_RESULT, LINKUP_SOMEONE_NOT_READY - goto_if_eq CableClub_EventScript_AbortLinkSomeoneNotReady - compare VAR_RESULT, LINKUP_DIFF_SELECTIONS - goto_if_eq CableClub_EventScript_AbortLinkDifferentSelections - compare VAR_RESULT, LINKUP_WRONG_NUM_PLAYERS - goto_if_eq CableClub_EventScript_AbortLinkIncorrectNumberOfBattlers - compare VAR_RESULT, LINKUP_FAILED - goto_if_eq CableClub_EventScript_AbortLink - compare VAR_RESULT, LINKUP_CONNECTION_ERROR - goto_if_eq CableClub_EventScript_AbortLinkConnectionError + goto_if_eq VAR_RESULT, LINKUP_SUCCESS, CableClub_EventScript_EnterColosseum + goto_if_eq VAR_RESULT, LINKUP_SOMEONE_NOT_READY, CableClub_EventScript_AbortLinkSomeoneNotReady + goto_if_eq VAR_RESULT, LINKUP_DIFF_SELECTIONS, CableClub_EventScript_AbortLinkDifferentSelections + goto_if_eq VAR_RESULT, LINKUP_WRONG_NUM_PLAYERS, CableClub_EventScript_AbortLinkIncorrectNumberOfBattlers + goto_if_eq VAR_RESULT, LINKUP_FAILED, CableClub_EventScript_AbortLink + goto_if_eq VAR_RESULT, LINKUP_CONNECTION_ERROR, CableClub_EventScript_AbortLinkConnectionError end CableClub_EventScript_EnterColosseum:: @@ -387,10 +360,9 @@ CableClub_EventScript_EnterColosseum:: closedoor 9, 1 waitdooranim release - compare VAR_0x8004, USING_MULTI_BATTLE - goto_if_eq CableClub_EventScript_WarpTo4PColosseum + goto_if_eq VAR_0x8004, USING_MULTI_BATTLE, CableClub_EventScript_WarpTo4PColosseum special SetCableClubWarp - warp MAP_BATTLE_COLOSSEUM_2P, 255, 6, 8 + warp MAP_BATTLE_COLOSSEUM_2P, 6, 8 special DoCableClubWarp waitstate end @@ -403,7 +375,7 @@ CableClub_EventScript_PlayerApproachLinkRoomRight:: CableClub_EventScript_WarpTo4PColosseum:: special SetCableClubWarp - warp MAP_BATTLE_COLOSSEUM_4P, 255, 5, 8 + warp MAP_BATTLE_COLOSSEUM_4P, 5, 8 special DoCableClubWarp waitstate end @@ -443,31 +415,21 @@ CableClub_EventScript_ConfirmNumberAndRestart:: CableClub_EventScript_TradeCenter:: copyvar VAR_0x8007, VAR_LAST_TALKED call CableClub_EventScript_CheckPartyTradeRequirements - compare VAR_RESULT, 0 - goto_if_eq CableClub_EventScript_AbortLink + goto_if_eq VAR_RESULT, 0, CableClub_EventScript_AbortLink call Common_EventScript_SaveGame - compare VAR_RESULT, 0 - goto_if_eq CableClub_EventScript_AbortLink + goto_if_eq VAR_RESULT, 0, CableClub_EventScript_AbortLink message gText_PleaseWaitForLink waitmessage special TryTradeLinkup waitstate - compare VAR_RESULT, LINKUP_SUCCESS - goto_if_eq CableClub_EventScript_EnterTradeCenter - compare VAR_RESULT, LINKUP_SOMEONE_NOT_READY - goto_if_eq CableClub_EventScript_AbortLinkSomeoneNotReady - compare VAR_RESULT, LINKUP_DIFF_SELECTIONS - goto_if_eq CableClub_EventScript_AbortLinkDifferentSelections - compare VAR_RESULT, LINKUP_WRONG_NUM_PLAYERS - goto_if_eq CableClub_EventScript_AbortLinkIncorrectNumberOfParticipants - compare VAR_RESULT, LINKUP_FAILED - goto_if_eq CableClub_EventScript_AbortLink - compare VAR_RESULT, LINKUP_CONNECTION_ERROR - goto_if_eq CableClub_EventScript_AbortLinkConnectionError - compare VAR_RESULT, LINKUP_PLAYER_NOT_READY - goto_if_eq CableClub_EventScript_AbortLinkPlayerNotReady - compare VAR_RESULT, LINKUP_PARTNER_NOT_READY - goto_if_eq CableClub_EventScript_AbortLinkOtherTrainerNotReady + goto_if_eq VAR_RESULT, LINKUP_SUCCESS, CableClub_EventScript_EnterTradeCenter + goto_if_eq VAR_RESULT, LINKUP_SOMEONE_NOT_READY, CableClub_EventScript_AbortLinkSomeoneNotReady + goto_if_eq VAR_RESULT, LINKUP_DIFF_SELECTIONS, CableClub_EventScript_AbortLinkDifferentSelections + goto_if_eq VAR_RESULT, LINKUP_WRONG_NUM_PLAYERS, CableClub_EventScript_AbortLinkIncorrectNumberOfParticipants + goto_if_eq VAR_RESULT, LINKUP_FAILED, CableClub_EventScript_AbortLink + goto_if_eq VAR_RESULT, LINKUP_CONNECTION_ERROR, CableClub_EventScript_AbortLinkConnectionError + goto_if_eq VAR_RESULT, LINKUP_PLAYER_NOT_READY, CableClub_EventScript_AbortLinkPlayerNotReady + goto_if_eq VAR_RESULT, LINKUP_PARTNER_NOT_READY, CableClub_EventScript_AbortLinkOtherTrainerNotReady end CableClub_EventScript_EnterTradeCenter:: @@ -493,18 +455,16 @@ CableClub_EventScript_EnterTradeCenter:: waitdooranim release special SetCableClubWarp - setwarp MAP_TRADE_CENTER, 255, 5, 8 + setwarp MAP_TRADE_CENTER, 5, 8 special DoCableClubWarp waitstate end CableClub_EventScript_CheckPartyTradeRequirements:: specialvar VAR_RESULT, CalculatePlayerPartyCount - compare VAR_RESULT, 2 - goto_if_lt CableClub_EventScript_NeedTwoMonsToTrade + goto_if_lt VAR_RESULT, 2, CableClub_EventScript_NeedTwoMonsToTrade specialvar VAR_RESULT, DoesPartyHaveEnigmaBerry - compare VAR_RESULT, TRUE - goto_if_eq CableClub_EventScript_CantTradeEnigmaBerry + goto_if_eq VAR_RESULT, TRUE, CableClub_EventScript_CantTradeEnigmaBerry setvar VAR_RESULT, 1 return @@ -521,28 +481,20 @@ CableClub_EventScript_CantTradeEnigmaBerry:: CableClub_EventScript_RecordCorner:: copyvar VAR_0x8007, VAR_LAST_TALKED call Common_EventScript_SaveGame - compare VAR_RESULT, 0 - goto_if_eq CableClub_EventScript_AbortLink + goto_if_eq VAR_RESULT, 0, CableClub_EventScript_AbortLink message gText_PleaseWaitForLink waitmessage special TryRecordMixLinkup waitstate special ValidateMixingGameLanguage waitstate - compare VAR_RESULT, LINKUP_FOREIGN_GAME - goto_if_eq CableClub_EventScript_AbortLinkForeignGame - compare VAR_RESULT, LINKUP_SUCCESS - goto_if_eq CableClub_EventScript_EnterRecordCorner - compare VAR_RESULT, LINKUP_SOMEONE_NOT_READY - goto_if_eq CableClub_EventScript_AbortLinkSomeoneNotReady - compare VAR_RESULT, LINKUP_DIFF_SELECTIONS - goto_if_eq CableClub_EventScript_AbortLinkDifferentSelections - compare VAR_RESULT, LINKUP_WRONG_NUM_PLAYERS - goto_if_eq CableClub_EventScript_AbortLinkIncorrectNumberOfParticipants - compare VAR_RESULT, LINKUP_FAILED - goto_if_eq CableClub_EventScript_AbortLink - compare VAR_RESULT, LINKUP_CONNECTION_ERROR - goto_if_eq CableClub_EventScript_AbortLinkConnectionError + goto_if_eq VAR_RESULT, LINKUP_FOREIGN_GAME, CableClub_EventScript_AbortLinkForeignGame + goto_if_eq VAR_RESULT, LINKUP_SUCCESS, CableClub_EventScript_EnterRecordCorner + goto_if_eq VAR_RESULT, LINKUP_SOMEONE_NOT_READY, CableClub_EventScript_AbortLinkSomeoneNotReady + goto_if_eq VAR_RESULT, LINKUP_DIFF_SELECTIONS, CableClub_EventScript_AbortLinkDifferentSelections + goto_if_eq VAR_RESULT, LINKUP_WRONG_NUM_PLAYERS, CableClub_EventScript_AbortLinkIncorrectNumberOfParticipants + goto_if_eq VAR_RESULT, LINKUP_FAILED, CableClub_EventScript_AbortLink + goto_if_eq VAR_RESULT, LINKUP_CONNECTION_ERROR, CableClub_EventScript_AbortLinkConnectionError end CableClub_EventScript_EnterRecordCorner:: @@ -568,7 +520,7 @@ CableClub_EventScript_EnterRecordCorner:: waitdooranim release special SetCableClubWarp - setwarp MAP_RECORD_CORNER, 255, 8, 9 + setwarp MAP_RECORD_CORNER, 8, 9 special DoCableClubWarp waitstate end @@ -726,8 +678,7 @@ EventScript_BattleColosseum_4P_PlayerSpot0:: fadescreen FADE_TO_BLACK special ChooseHalfPartyForBattle waitstate - compare VAR_RESULT, 0 - goto_if_eq EventScript_BattleColosseum_4P_CancelSpotTrigger + goto_if_eq VAR_RESULT, 0, EventScript_BattleColosseum_4P_CancelSpotTrigger setvar VAR_0x8005, 0 special ColosseumPlayerSpotTriggered waitstate @@ -737,8 +688,7 @@ EventScript_BattleColosseum_4P_PlayerSpot1:: fadescreen FADE_TO_BLACK special ChooseHalfPartyForBattle waitstate - compare VAR_RESULT, 0 - goto_if_eq EventScript_BattleColosseum_4P_CancelSpotTrigger + goto_if_eq VAR_RESULT, 0, EventScript_BattleColosseum_4P_CancelSpotTrigger setvar VAR_0x8005, 1 special ColosseumPlayerSpotTriggered waitstate @@ -748,8 +698,7 @@ EventScript_BattleColosseum_4P_PlayerSpot2:: fadescreen FADE_TO_BLACK special ChooseHalfPartyForBattle waitstate - compare VAR_RESULT, 0 - goto_if_eq EventScript_BattleColosseum_4P_CancelSpotTrigger + goto_if_eq VAR_RESULT, 0, EventScript_BattleColosseum_4P_CancelSpotTrigger setvar VAR_0x8005, 2 special ColosseumPlayerSpotTriggered waitstate @@ -759,8 +708,7 @@ EventScript_BattleColosseum_4P_PlayerSpot3:: fadescreen FADE_TO_BLACK special ChooseHalfPartyForBattle waitstate - compare VAR_RESULT, 0 - goto_if_eq EventScript_BattleColosseum_4P_CancelSpotTrigger + goto_if_eq VAR_RESULT, 0, EventScript_BattleColosseum_4P_CancelSpotTrigger setvar VAR_0x8005, 3 special ColosseumPlayerSpotTriggered waitstate @@ -800,36 +748,32 @@ EventScript_RecordCenter_Spot0:: setvar VAR_0x8005, 0 special RecordMixingPlayerSpotTriggered waitstate - compare VAR_TEMP_1, ITEM_NONE - goto_if_ne RecordCorner_EventScript_ReceivedGiftItem + goto_if_ne VAR_TEMP_1, ITEM_NONE, RecordCorner_EventScript_ReceivedGiftItem end EventScript_RecordCenter_Spot1:: setvar VAR_0x8005, 1 special RecordMixingPlayerSpotTriggered waitstate - compare VAR_TEMP_1, ITEM_NONE - goto_if_ne RecordCorner_EventScript_ReceivedGiftItem + goto_if_ne VAR_TEMP_1, ITEM_NONE, RecordCorner_EventScript_ReceivedGiftItem end EventScript_RecordCenter_Spot2:: setvar VAR_0x8005, 2 special RecordMixingPlayerSpotTriggered waitstate - compare VAR_TEMP_1, ITEM_NONE - goto_if_ne RecordCorner_EventScript_ReceivedGiftItem + goto_if_ne VAR_TEMP_1, ITEM_NONE, RecordCorner_EventScript_ReceivedGiftItem end EventScript_RecordCenter_Spot3:: setvar VAR_0x8005, 3 special RecordMixingPlayerSpotTriggered waitstate - compare VAR_TEMP_1, ITEM_NONE - goto_if_ne RecordCorner_EventScript_ReceivedGiftItem + goto_if_ne VAR_TEMP_1, ITEM_NONE, RecordCorner_EventScript_ReceivedGiftItem end RecordCorner_EventScript_ReceivedGiftItem:: - bufferitemname 1, VAR_TEMP_1 + bufferitemname STR_VAR_2, VAR_TEMP_1 message RecordCorner_Text_PlayerSentOverOneX waitmessage waitbuttonpress @@ -870,8 +814,7 @@ TradeCenter_EventScript_Attendant:: end RecordCorner_EventScript_Attendant:: - compare VAR_TEMP_0, 0 - goto_if_ne RecordCorner_EventScript_AlreadyMixed + goto_if_ne VAR_TEMP_0, 0, RecordCorner_EventScript_AlreadyMixed special Script_FacePlayer message RecordCorner_Text_TakeSeatAndWait waitmessage @@ -891,8 +834,7 @@ RecordCorner_EventScript_AlreadyMixed:: EventScript_ConfirmLeaveCableClubRoom:: msgbox Text_TerminateLinkConfirmation, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq EventScript_TerminateLink + goto_if_eq VAR_RESULT, YES, EventScript_TerminateLink erasebox 0, 0, 29, 19 releaseall end @@ -915,12 +857,10 @@ CableClub_EventScript_UnionRoomAttendant:: setvar VAR_FRONTIER_FACILITY, FACILITY_UNION_ROOM goto_if_unset FLAG_SYS_POKEDEX_GET, CableClub_EventScript_WirelessClubAdjustements specialvar VAR_RESULT, IsBadEggInParty - compare VAR_RESULT, TRUE - goto_if_eq CableClub_EventScript_AbortLinkPlayerHasBadEgg + goto_if_eq VAR_RESULT, TRUE, CableClub_EventScript_AbortLinkPlayerHasBadEgg copyvar VAR_0x8007, VAR_LAST_TALKED specialvar VAR_RESULT, IsWirelessAdapterConnected - compare VAR_RESULT, FALSE - goto_if_eq CableClub_EventScript_UnionRoomAdapterNotConnected + goto_if_eq VAR_RESULT, FALSE, CableClub_EventScript_UnionRoomAdapterNotConnected message CableClub_Text_WelcomeUnionRoomEnter waitmessage goto CableClub_EventScript_UnionRoomSelect @@ -943,11 +883,9 @@ CableClub_EventScript_UnionRoomInfo:: CableClub_EventScript_EnterUnionRoom:: call CableClub_EventScript_CheckPartyUnionRoomRequirements - compare VAR_RESULT, 0 - goto_if_eq CableClub_EventScript_AbortLink + goto_if_eq VAR_RESULT, 0, CableClub_EventScript_AbortLink call Common_EventScript_SaveGame - compare VAR_RESULT, 0 - goto_if_eq CableClub_EventScript_AbortLink + goto_if_eq VAR_RESULT, 0, CableClub_EventScript_AbortLink msgbox CableClub_Text_EnjoyUnionRoom, MSGBOX_DEFAULT closemessage special HealPlayerParty @@ -970,7 +908,7 @@ CableClub_EventScript_EnterUnionRoom:: waitdooranim special Script_ResetUnionRoomTrade special SetCableClubWarp - warpteleport2 MAP_UNION_ROOM, 255, 7, 11 + warpspinenter MAP_UNION_ROOM, 7, 11 waitstate special RunUnionRoom waitstate @@ -978,11 +916,9 @@ CableClub_EventScript_EnterUnionRoom:: CableClub_EventScript_CheckPartyUnionRoomRequirements:: specialvar VAR_RESULT, CountPartyNonEggMons - compare VAR_RESULT, 2 - goto_if_lt CableClub_EventScript_NeedTwoMonsForUnionRoom + goto_if_lt VAR_RESULT, 2, CableClub_EventScript_NeedTwoMonsForUnionRoom specialvar VAR_RESULT, DoesPartyHaveEnigmaBerry - compare VAR_RESULT, TRUE - goto_if_eq CableClub_EventScript_NoEnigmaBerryInUnionRoom + goto_if_eq VAR_RESULT, TRUE, CableClub_EventScript_NoEnigmaBerryInUnionRoom setvar VAR_RESULT, 1 return @@ -1006,8 +942,7 @@ CableClub_EventScript_WirelessClubAttendant:: faceplayer goto_if_unset FLAG_SYS_POKEDEX_GET, CableClub_EventScript_WirelessClubAdjustements msgbox CableClub_Text_AskAboutLinking, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq CableClub_EventScript_DontAskAboutLinking + goto_if_eq VAR_RESULT, NO, CableClub_EventScript_DontAskAboutLinking msgbox CableClub_Text_ExplainWirelessClub, MSGBOX_DEFAULT release return @@ -1023,11 +958,9 @@ CableClub_EventScript_DirectCornerAttendant:: setvar VAR_FRONTIER_FACILITY, FACILITY_MULTI_OR_EREADER @ Set preemptively for multi battles, ignored otherwise goto_if_unset FLAG_SYS_POKEDEX_GET, CableClub_EventScript_WirelessClubAdjustements specialvar VAR_RESULT, IsBadEggInParty - compare VAR_RESULT, TRUE - goto_if_eq CableClub_EventScript_AbortLinkPlayerHasBadEgg + goto_if_eq VAR_RESULT, TRUE, CableClub_EventScript_AbortLinkPlayerHasBadEgg specialvar VAR_RESULT, IsWirelessAdapterConnected - compare VAR_RESULT, FALSE - goto_if_eq CableClub_EventScript_WelcomeToCableClub + goto_if_eq VAR_RESULT, FALSE, CableClub_EventScript_WelcomeToCableClub message CableClub_Text_WelcomeWhichDirectCornerRoom waitmessage delay 28 @@ -1035,9 +968,8 @@ CableClub_EventScript_DirectCornerAttendant:: end CableClub_EventScript_DirectCornerSelectService:: - checkitem ITEM_POWDER_JAR, 1 - compare VAR_RESULT, FALSE - goto_if_eq CableClub_EventScript_DirectCornerNoBerry + checkitem ITEM_POWDER_JAR + goto_if_eq VAR_RESULT, FALSE, CableClub_EventScript_DirectCornerNoBerry goto_if_set FLAG_VISITED_MAUVILLE_CITY, CableClub_EventScript_DirectCornerSelectAllServices multichoice 0, 0, MULTI_WIRELESS_NO_RECORD, FALSE switch VAR_RESULT @@ -1081,11 +1013,9 @@ CableClub_EventScript_DirectCornerHasRecordMix:: CableClub_EventScript_WirelessTrade:: msgbox CableClub_Text_TradePokemon, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq CableClub_EventScript_AbortLink + goto_if_eq VAR_RESULT, NO, CableClub_EventScript_AbortLink call CableClub_EventScript_CheckPartyTradeRequirements - compare VAR_RESULT, 0 - goto_if_eq CableClub_EventScript_AbortLink + goto_if_eq VAR_RESULT, 0, CableClub_EventScript_AbortLink setvar VAR_0x8004, LINK_GROUP_TRADE goto CableClub_EventScript_SaveAndChooseLinkLeader end @@ -1110,8 +1040,7 @@ CableClub_EventScript_WirelessSingleBattle:: CableClub_EventScript_WirelessDoubleBattle:: special HasEnoughMonsForDoubleBattle - compare VAR_RESULT, PLAYER_HAS_TWO_USABLE_MONS - goto_if_ne CableClub_EventScript_TwoMonsNeededForWirelessDoubleBattle + goto_if_ne VAR_RESULT, PLAYER_HAS_TWO_USABLE_MONS, CableClub_EventScript_TwoMonsNeededForWirelessDoubleBattle setvar VAR_0x8004, LINK_GROUP_DOUBLE_BATTLE goto CableClub_EventScript_SaveAndChooseLinkLeader end @@ -1133,19 +1062,16 @@ CableClub_EventScript_WirelessBattleInfo:: CableClub_EventScript_WirelessRecordMix:: msgbox CableClub_Text_AccessRecordCorner, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq CableClub_EventScript_AbortLink + goto_if_eq VAR_RESULT, NO, CableClub_EventScript_AbortLink setvar VAR_0x8004, LINK_GROUP_RECORD_CORNER goto CableClub_EventScript_SaveAndChooseLinkLeader end CableClub_EventScript_WirelessBerryCrush:: msgbox CableClub_Text_UseBerryCrush, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq CableClub_EventScript_AbortLink + goto_if_eq VAR_RESULT, NO, CableClub_EventScript_AbortLink special HasAtLeastOneBerry - compare VAR_RESULT, FALSE - goto_if_eq CableClub_EventScript_NeedBerryForBerryCrush + goto_if_eq VAR_RESULT, FALSE, CableClub_EventScript_NeedBerryForBerryCrush setvar VAR_0x8004, LINK_GROUP_BERRY_CRUSH goto CableClub_EventScript_SaveAndChooseLinkLeader end @@ -1157,8 +1083,7 @@ CableClub_EventScript_NeedBerryForBerryCrush:: CableClub_EventScript_SaveAndChooseLinkLeader:: call Common_EventScript_SaveGame - compare VAR_RESULT, 0 - goto_if_eq CableClub_EventScript_AbortLink + goto_if_eq VAR_RESULT, 0, CableClub_EventScript_AbortLink switch VAR_0x8004 case LINK_GROUP_TRADE, CableClub_EventScript_ChooseLinkLeaderFrom2 case LINK_GROUP_SINGLE_BATTLE, CableClub_EventScript_ChooseLinkLeaderFrom2 @@ -1181,23 +1106,17 @@ CableClub_EventScript_ChooseLinkLeaderFrom2:: CableClub_EventScript_TryLeadGroup2Players:: call CableClub_EventScript_TryBecomeLinkLeader - compare VAR_RESULT, LINKUP_SUCCESS - goto_if_eq CableClub_EventScript_EnterWirelessLinkRoom - compare VAR_RESULT, LINKUP_FAILED - goto_if_eq CableClub_EventScript_ChooseLinkLeaderFrom2 - compare VAR_RESULT, LINKUP_RETRY_ROLE_ASSIGN - goto_if_eq CableClub_EventScript_TryLeadGroup2Players + goto_if_eq VAR_RESULT, LINKUP_SUCCESS, CableClub_EventScript_EnterWirelessLinkRoom + goto_if_eq VAR_RESULT, LINKUP_FAILED, CableClub_EventScript_ChooseLinkLeaderFrom2 + goto_if_eq VAR_RESULT, LINKUP_RETRY_ROLE_ASSIGN, CableClub_EventScript_TryLeadGroup2Players release return CableClub_EventScript_TryJoinGroup2Players:: call CableClub_EventScript_TryJoinLinkGroup - compare VAR_RESULT, LINKUP_SUCCESS - goto_if_eq CableClub_EventScript_EnterWirelessLinkRoom - compare VAR_RESULT, LINKUP_FAILED - goto_if_eq CableClub_EventScript_ChooseLinkLeaderFrom2 - compare VAR_RESULT, LINKUP_RETRY_ROLE_ASSIGN - goto_if_eq CableClub_EventScript_TryJoinGroup2Players + goto_if_eq VAR_RESULT, LINKUP_SUCCESS, CableClub_EventScript_EnterWirelessLinkRoom + goto_if_eq VAR_RESULT, LINKUP_FAILED, CableClub_EventScript_ChooseLinkLeaderFrom2 + goto_if_eq VAR_RESULT, LINKUP_RETRY_ROLE_ASSIGN, CableClub_EventScript_TryJoinGroup2Players release return @@ -1214,23 +1133,17 @@ CableClub_EventScript_ChooseLinkLeaderFrom4:: CableClub_EventScript_TryLeadGroup4Players:: call CableClub_EventScript_TryBecomeLinkLeader - compare VAR_RESULT, LINKUP_SUCCESS - goto_if_eq CableClub_EventScript_EnterWirelessLinkRoom - compare VAR_RESULT, LINKUP_FAILED - goto_if_eq CableClub_EventScript_ChooseLinkLeaderFrom4 - compare VAR_RESULT, LINKUP_RETRY_ROLE_ASSIGN - goto_if_eq CableClub_EventScript_TryLeadGroup4Players + goto_if_eq VAR_RESULT, LINKUP_SUCCESS, CableClub_EventScript_EnterWirelessLinkRoom + goto_if_eq VAR_RESULT, LINKUP_FAILED, CableClub_EventScript_ChooseLinkLeaderFrom4 + goto_if_eq VAR_RESULT, LINKUP_RETRY_ROLE_ASSIGN, CableClub_EventScript_TryLeadGroup4Players release return CableClub_EventScript_TryJoinGroup4Players:: call CableClub_EventScript_TryJoinLinkGroup - compare VAR_RESULT, LINKUP_SUCCESS - goto_if_eq CableClub_EventScript_EnterWirelessLinkRoom - compare VAR_RESULT, LINKUP_FAILED - goto_if_eq CableClub_EventScript_ChooseLinkLeaderFrom4 - compare VAR_RESULT, LINKUP_RETRY_ROLE_ASSIGN - goto_if_eq CableClub_EventScript_TryJoinGroup4Players + goto_if_eq VAR_RESULT, LINKUP_SUCCESS, CableClub_EventScript_EnterWirelessLinkRoom + goto_if_eq VAR_RESULT, LINKUP_FAILED, CableClub_EventScript_ChooseLinkLeaderFrom4 + goto_if_eq VAR_RESULT, LINKUP_RETRY_ROLE_ASSIGN, CableClub_EventScript_TryJoinGroup4Players release return @@ -1247,23 +1160,17 @@ CableClub_EventScript_ChooseLinkLeader:: CableClub_EventScript_TryLeadGroupXPlayers:: call CableClub_EventScript_TryBecomeLinkLeader - compare VAR_RESULT, LINKUP_SUCCESS - goto_if_eq CableClub_EventScript_EnterWirelessLinkRoom - compare VAR_RESULT, LINKUP_FAILED - goto_if_eq CableClub_EventScript_ChooseLinkLeader - compare VAR_RESULT, LINKUP_RETRY_ROLE_ASSIGN - goto_if_eq CableClub_EventScript_TryLeadGroupXPlayers + goto_if_eq VAR_RESULT, LINKUP_SUCCESS, CableClub_EventScript_EnterWirelessLinkRoom + goto_if_eq VAR_RESULT, LINKUP_FAILED, CableClub_EventScript_ChooseLinkLeader + goto_if_eq VAR_RESULT, LINKUP_RETRY_ROLE_ASSIGN, CableClub_EventScript_TryLeadGroupXPlayers release return CableClub_EventScript_TryJoinGroupXPlayers:: call CableClub_EventScript_TryJoinLinkGroup - compare VAR_RESULT, LINKUP_SUCCESS - goto_if_eq CableClub_EventScript_EnterWirelessLinkRoom - compare VAR_RESULT, LINKUP_FAILED - goto_if_eq CableClub_EventScript_ChooseLinkLeader - compare VAR_RESULT, LINKUP_RETRY_ROLE_ASSIGN - goto_if_eq CableClub_EventScript_TryJoinGroupXPlayers + goto_if_eq VAR_RESULT, LINKUP_SUCCESS, CableClub_EventScript_EnterWirelessLinkRoom + goto_if_eq VAR_RESULT, LINKUP_FAILED, CableClub_EventScript_ChooseLinkLeader + goto_if_eq VAR_RESULT, LINKUP_RETRY_ROLE_ASSIGN, CableClub_EventScript_TryJoinGroupXPlayers release return @@ -1307,8 +1214,7 @@ EventScript_WirelessBoxResults:: lockall goto_if_unset FLAG_SYS_POKEDEX_GET, CableClub_EventScript_NotReadyYet specialvar VAR_RESULT, IsWirelessAdapterConnected - compare VAR_RESULT, FALSE - goto_if_eq CableClub_EventScript_AdapterNotConnected + goto_if_eq VAR_RESULT, FALSE, CableClub_EventScript_AdapterNotConnected fadescreen FADE_TO_BLACK special ShowWirelessCommunicationScreen waitstate @@ -1322,33 +1228,33 @@ CableClub_EventScript_AdapterNotConnected:: end CableClub_EventScript_OpenUnionRoomBarrier:: - setmetatile 5, 2, METATILE_PokemonCenter_Floor_ShadowTop_Alt, 0 - setmetatile 5, 3, METATILE_PokemonCenter_Floor_Plain_Alt, 0 + setmetatile 5, 2, METATILE_PokemonCenter_Floor_ShadowTop_Alt, FALSE + setmetatile 5, 3, METATILE_PokemonCenter_Floor_Plain_Alt, FALSE return CableClub_EventScript_CloseUnionRoomBarrier:: - setmetatile 5, 2, METATILE_PokemonCenter_Floor_ShadowTop, 1 - setmetatile 5, 3, METATILE_PokemonCenter_CounterBarrier, 1 + setmetatile 5, 2, METATILE_PokemonCenter_Floor_ShadowTop, TRUE + setmetatile 5, 3, METATILE_PokemonCenter_CounterBarrier, TRUE return CableClub_EventScript_OpenDirectCornerBarrier:: - setmetatile 9, 2, METATILE_PokemonCenter_Floor_ShadowTop_Alt, 0 - setmetatile 9, 3, METATILE_PokemonCenter_Floor_Plain_Alt, 0 + setmetatile 9, 2, METATILE_PokemonCenter_Floor_ShadowTop_Alt, FALSE + setmetatile 9, 3, METATILE_PokemonCenter_Floor_Plain_Alt, FALSE return CableClub_EventScript_CloseDirectCornerBarrier:: - setmetatile 9, 2, METATILE_PokemonCenter_Floor_ShadowTop, 1 - setmetatile 9, 3, METATILE_PokemonCenter_CounterBarrier, 1 + setmetatile 9, 2, METATILE_PokemonCenter_Floor_ShadowTop, TRUE + setmetatile 9, 3, METATILE_PokemonCenter_CounterBarrier, TRUE return EventScript_OpenMossdeepGameCornerBarrier:: - setmetatile 5, 2, METATILE_MossdeepGameCorner_CounterOpen_Top, 0 - setmetatile 5, 3, METATILE_MossdeepGameCorner_CounterOpen_Bottom, 0 + setmetatile 5, 2, METATILE_MossdeepGameCorner_CounterOpen_Top, FALSE + setmetatile 5, 3, METATILE_MossdeepGameCorner_CounterOpen_Bottom, FALSE return EventScript_CloseMossdeepGameCornerBarrier:: - setmetatile 5, 2, METATILE_MossdeepGameCorner_CounterClosed_Top, 1 - setmetatile 5, 3, METATILE_MossdeepGameCorner_CounterClosed_Bottom, 1 + setmetatile 5, 2, METATILE_MossdeepGameCorner_CounterClosed_Top, TRUE + setmetatile 5, 3, METATILE_MossdeepGameCorner_CounterClosed_Bottom, TRUE return CableClub_OnResume: @@ -1389,8 +1295,7 @@ MossdeepCity_GameCorner_1F_EventScript_OldMan2:: message MossdeepCity_GameCorner_1F_Text_WelcomeCanYouWait waitmessage specialvar VAR_RESULT, IsWirelessAdapterConnected - compare VAR_RESULT, FALSE - goto_if_eq MossdeepCity_GameCorner_1F_EventScript_AdapterNotConnected + goto_if_eq VAR_RESULT, FALSE, MossdeepCity_GameCorner_1F_EventScript_AdapterNotConnected delay 60 message MossdeepCity_GameCorner_1F_Text_PlayWhichGame waitmessage @@ -1405,18 +1310,15 @@ MossdeepCity_GameCorner_1F_EventScript_OldMan2:: MossdeepCity_GameCorner_1F_EventScript_PlayPokemonJump:: setvar VAR_0x8005, 0 special IsPokemonJumpSpeciesInParty - compare VAR_RESULT, FALSE - goto_if_eq MossdeepCity_GameCorner_1F_EventScript_DontHaveRequiredMon + goto_if_eq VAR_RESULT, FALSE, MossdeepCity_GameCorner_1F_EventScript_DontHaveRequiredMon msgbox MossdeepCity_GameCorner_1F_Text_EnterWhichPokemon, MSGBOX_DEFAULT fadescreen FADE_TO_BLACK setvar VAR_0x8005, 0 special ChooseMonForWirelessMinigame waitstate - compare VAR_0x8004, PARTY_SIZE - goto_if_ge MossdeepCity_GameCorner_1F_EventScript_AbortMinigame + goto_if_ge VAR_0x8004, PARTY_SIZE, MossdeepCity_GameCorner_1F_EventScript_AbortMinigame call Common_EventScript_SaveGame - compare VAR_RESULT, 0 - goto_if_eq MossdeepCity_GameCorner_1F_EventScript_AbortMinigame + goto_if_eq VAR_RESULT, 0, MossdeepCity_GameCorner_1F_EventScript_AbortMinigame setvar VAR_0x8004, LINK_GROUP_POKEMON_JUMP goto MossdeepCity_GameCorner_1F_EventScript_ChooseLinkLeader end @@ -1424,18 +1326,15 @@ MossdeepCity_GameCorner_1F_EventScript_PlayPokemonJump:: MossdeepCity_GameCorner_1F_EventScript_PlayDodrioBerryPicking:: setvar VAR_0x8005, 1 special IsDodrioInParty - compare VAR_RESULT, FALSE - goto_if_eq MossdeepCity_GameCorner_1F_EventScript_DontHaveRequiredMon + goto_if_eq VAR_RESULT, FALSE, MossdeepCity_GameCorner_1F_EventScript_DontHaveRequiredMon msgbox MossdeepCity_GameCorner_1F_Text_EnterWhichPokemon, MSGBOX_DEFAULT fadescreen FADE_TO_BLACK setvar VAR_0x8005, 1 special ChooseMonForWirelessMinigame waitstate - compare VAR_0x8004, PARTY_SIZE - goto_if_ge MossdeepCity_GameCorner_1F_EventScript_AbortMinigame + goto_if_ge VAR_0x8004, PARTY_SIZE, MossdeepCity_GameCorner_1F_EventScript_AbortMinigame call Common_EventScript_SaveGame - compare VAR_RESULT, 0 - goto_if_eq MossdeepCity_GameCorner_1F_EventScript_AbortMinigame + goto_if_eq VAR_RESULT, 0, MossdeepCity_GameCorner_1F_EventScript_AbortMinigame setvar VAR_0x8004, LINK_GROUP_BERRY_PICKING goto MossdeepCity_GameCorner_1F_EventScript_ChooseLinkLeader end @@ -1453,23 +1352,17 @@ MossdeepCity_GameCorner_1F_EventScript_ChooseLinkLeader:: MossdeepCity_GameCorner_1F_EventScript_TryBecomeLinkLeader:: call CableClub_EventScript_TryBecomeLinkLeader - compare VAR_RESULT, LINKUP_SUCCESS - goto_if_eq MossdeepCity_GameCorner_1F_EventScript_EnterMinigameRoom - compare VAR_RESULT, LINKUP_FAILED - goto_if_eq MossdeepCity_GameCorner_1F_EventScript_ChooseLinkLeader - compare VAR_RESULT, LINKUP_RETRY_ROLE_ASSIGN - goto_if_eq MossdeepCity_GameCorner_1F_EventScript_TryBecomeLinkLeader + goto_if_eq VAR_RESULT, LINKUP_SUCCESS, MossdeepCity_GameCorner_1F_EventScript_EnterMinigameRoom + goto_if_eq VAR_RESULT, LINKUP_FAILED, MossdeepCity_GameCorner_1F_EventScript_ChooseLinkLeader + goto_if_eq VAR_RESULT, LINKUP_RETRY_ROLE_ASSIGN, MossdeepCity_GameCorner_1F_EventScript_TryBecomeLinkLeader release return MossdeepCity_GameCorner_1F_EventScript_TryJoinLinkGroup:: call CableClub_EventScript_TryJoinLinkGroup - compare VAR_RESULT, LINKUP_SUCCESS - goto_if_eq MossdeepCity_GameCorner_1F_EventScript_EnterMinigameRoom - compare VAR_RESULT, LINKUP_FAILED - goto_if_eq MossdeepCity_GameCorner_1F_EventScript_ChooseLinkLeader - compare VAR_RESULT, LINKUP_RETRY_ROLE_ASSIGN - goto_if_eq MossdeepCity_GameCorner_1F_EventScript_TryJoinLinkGroup + goto_if_eq VAR_RESULT, LINKUP_SUCCESS, MossdeepCity_GameCorner_1F_EventScript_EnterMinigameRoom + goto_if_eq VAR_RESULT, LINKUP_FAILED, MossdeepCity_GameCorner_1F_EventScript_ChooseLinkLeader + goto_if_eq VAR_RESULT, LINKUP_RETRY_ROLE_ASSIGN, MossdeepCity_GameCorner_1F_EventScript_TryJoinLinkGroup release return @@ -1501,12 +1394,9 @@ MossdeepCity_GameCorner_1F_EventScript_AdapterNotConnected:: MossdeepCity_GameCorner_1F_EventScript_DontHaveRequiredMon:: msgbox MossdeepCity_GameCorner_1F_Text_ExplainRequiredMon, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq MossdeepCity_GameCorner_1F_EventScript_AbortMinigame - compare VAR_0x8005, 0 - call_if_eq MossdeepCity_GameCorner_1F_EventScript_ExplainPokemonJumpRequirements - compare VAR_0x8005, 1 - call_if_eq MossdeepCity_GameCorner_1F_EventScript_ExplainDodrioBerryPickingRequirements + goto_if_eq VAR_RESULT, NO, MossdeepCity_GameCorner_1F_EventScript_AbortMinigame + call_if_eq VAR_0x8005, 0, MossdeepCity_GameCorner_1F_EventScript_ExplainPokemonJumpRequirements + call_if_eq VAR_0x8005, 1, MossdeepCity_GameCorner_1F_EventScript_ExplainDodrioBerryPickingRequirements goto MossdeepCity_GameCorner_1F_EventScript_AbortMinigame end diff --git a/data/scripts/contest_hall.inc b/data/scripts/contest_hall.inc index 17364559b..04c62a6de 100644 --- a/data/scripts/contest_hall.inc +++ b/data/scripts/contest_hall.inc @@ -18,8 +18,7 @@ LilycoveCity_ContestLobby_EventScript_SpeakToContestReceptionist:: lock faceplayer - compare VAR_CONTEST_PRIZE_PICKUP, 0 - goto_if_ne LilycoveCity_ContestLobby_EventScript_PickUpPrize + goto_if_ne VAR_CONTEST_PRIZE_PICKUP, 0, LilycoveCity_ContestLobby_EventScript_PickUpPrize call_if_set FLAG_RECEIVED_POKEBLOCK_CASE, LilycoveCity_ContestLobby_EventScript_ReceptionWelcome call_if_unset FLAG_RECEIVED_POKEBLOCK_CASE, LilycoveCity_ContestLobby_EventScript_GivePokeblockCase goto LilycoveCity_ContestLobby_EventScript_AskEnterContest @@ -44,8 +43,7 @@ LilycoveCity_ContestLobby_EventScript_PickUpPrize:: LilycoveCity_ContestLobby_EventScript_GiveLuxuryBallAtCounter:: giveitem ITEM_LUXURY_BALL - compare VAR_RESULT, FALSE - goto_if_eq LilycoveCity_ContestLobby_EventScript_NoRoomForLuxuryBallAtCounter + goto_if_eq VAR_RESULT, FALSE, LilycoveCity_ContestLobby_EventScript_NoRoomForLuxuryBallAtCounter setvar VAR_CONTEST_PRIZE_PICKUP, 0 closemessage release @@ -103,19 +101,13 @@ LilycoveCity_ContestLobby_EventScript_CancelEnterContest:: LilycoveCity_ContestLobby_EventScript_ChooseContestMon:: msgbox LilycoveCity_ContestLobby_Text_EnterWhichPokemon1, MSGBOX_DEFAULT choosecontestmon - compare VAR_0x8004, 255 - goto_if_eq LilycoveCity_ContestLobby_EventScript_CancelEnterContest + goto_if_eq VAR_0x8004, PARTY_NOTHING_CHOSEN, LilycoveCity_ContestLobby_EventScript_CancelEnterContest special TryEnterContestMon - compare VAR_RESULT, CANT_ENTER_CONTEST - goto_if_eq LilycoveCity_ContestLobby_EventScript_CantEnterLowRank - compare VAR_RESULT, CAN_ENTER_CONTEST_EQUAL_RANK - goto_if_eq LilycoveCity_ContestLobby_EventScript_EnterMon - compare VAR_RESULT, CAN_ENTER_CONTEST_HIGH_RANK - goto_if_eq LilycoveCity_ContestLobby_EventScript_ConfirmEntryAlreadyWon - compare VAR_RESULT, CANT_ENTER_CONTEST_EGG - goto_if_eq LilycoveCity_ContestLobby_EventScript_CantEnterEgg - compare VAR_RESULT, CANT_ENTER_CONTEST_FAINTED - goto_if_eq LilycoveCity_ContestLobby_EventScript_CantEnterFainted + goto_if_eq VAR_RESULT, CANT_ENTER_CONTEST, LilycoveCity_ContestLobby_EventScript_CantEnterLowRank + goto_if_eq VAR_RESULT, CAN_ENTER_CONTEST_EQUAL_RANK, LilycoveCity_ContestLobby_EventScript_EnterMon + goto_if_eq VAR_RESULT, CAN_ENTER_CONTEST_HIGH_RANK, LilycoveCity_ContestLobby_EventScript_ConfirmEntryAlreadyWon + goto_if_eq VAR_RESULT, CANT_ENTER_CONTEST_EGG, LilycoveCity_ContestLobby_EventScript_CantEnterEgg + goto_if_eq VAR_RESULT, CANT_ENTER_CONTEST_FAINTED, LilycoveCity_ContestLobby_EventScript_CantEnterFainted end LilycoveCity_ContestLobby_EventScript_ChooseContestRank:: @@ -283,8 +275,8 @@ ContestHall_EventScript_GetCategoryTough:: return ContestHall_EventScript_ContestGettingStarted:: - buffercontesttypestring 1, VAR_0x8008 - bufferstdstring 2, VAR_0x8009 + buffercontestname STR_VAR_2, VAR_0x8008 + bufferstdstring STR_VAR_3, VAR_0x8009 call ContestHall_EventScript_GettingStarted lockall applymovement LOCALID_MC, ContestHall_Movement_MCBackUp @@ -293,8 +285,7 @@ ContestHall_EventScript_ContestGettingStarted:: return ContestHall_EventScript_GettingStarted:: - compare VAR_CONTEST_TYPE, CONTEST_TYPE_LINK - goto_if_eq ContestHall_EventScript_GettingStartedLink + goto_if_eq VAR_CONTEST_TYPE, CONTEST_TYPE_LINK, ContestHall_EventScript_GettingStartedLink lockall msgbox ContestHall_Text_GettingStartedParticipantsAsFollows, MSGBOX_DEFAULT releaseall @@ -302,8 +293,7 @@ ContestHall_EventScript_GettingStarted:: ContestHall_EventScript_GettingStartedLink:: specialvar VAR_RESULT, IsWirelessContest - compare VAR_RESULT, TRUE - goto_if_eq ContestHall_EventScript_GettingStartedWireless + goto_if_eq VAR_RESULT, TRUE, ContestHall_EventScript_GettingStartedWireless messageautoscroll ContestHall_Text_GettingStartedParticipantsAsFollowsLink waitmessage return @@ -326,16 +316,14 @@ ContestHall_EventScript_ShowContestMons:: call ContestHall_EventScript_TryWaitForLink call ContestHall_EventScript_TryWaitForLink addvar VAR_0x8006, 1 - compare VAR_0x8006, CONTESTANT_COUNT - goto_if_ne ContestHall_EventScript_ShowContestMons + goto_if_ne VAR_0x8006, CONTESTANT_COUNT, ContestHall_EventScript_ShowContestMons call ContestHall_EventScript_AudienceVote setvar VAR_TEMP_1, 6 return ContestHall_EventScript_TryWaitForLink:: specialvar VAR_RESULT, IsWirelessContest - compare VAR_RESULT, TRUE - goto_if_eq ContestHall_EventScript_WaitForLink + goto_if_eq VAR_RESULT, TRUE, ContestHall_EventScript_WaitForLink return ContestHall_EventScript_WaitForLink:: @@ -344,14 +332,10 @@ ContestHall_EventScript_WaitForLink:: return ContestHall_EventScript_ContestantWalkToCenter:: - compare VAR_0x8006, 0 - goto_if_eq ContestHall_EventScript_Player1WalkToCenter - compare VAR_0x8006, 1 - goto_if_eq ContestHall_EventScript_Player2WalkToCenter - compare VAR_0x8006, 2 - goto_if_eq ContestHall_EventScript_Player3WalkToCenter - compare VAR_0x8006, 3 - goto_if_eq ContestHall_EventScript_Player4WalkToCenter + goto_if_eq VAR_0x8006, 0, ContestHall_EventScript_Player1WalkToCenter + goto_if_eq VAR_0x8006, 1, ContestHall_EventScript_Player2WalkToCenter + goto_if_eq VAR_0x8006, 2, ContestHall_EventScript_Player3WalkToCenter + goto_if_eq VAR_0x8006, 3, ContestHall_EventScript_Player4WalkToCenter return ContestHall_EventScript_Player1WalkToCenter:: @@ -393,7 +377,7 @@ ContestHall_EventScript_Player4WalkToCenter:: ContestHall_EventScript_ShowContestMonPic:: special BufferContestTrainerAndMonNames addvar VAR_0x8006, 1 - buffernumberstring 1, VAR_0x8006 + buffernumberstring STR_VAR_2, VAR_0x8006 lockall applymovement VAR_0x800B, ContestHall_Movement_ContestantDelay32 waitmovement 0 @@ -413,8 +397,7 @@ ContestHall_EventScript_ShowContestMonPic:: return ContestHall_EventScript_EntryXTrainersMon:: - compare VAR_CONTEST_TYPE, CONTEST_TYPE_LINK - goto_if_eq ContestHall_EventScript_EntryXTrainersMonLink + goto_if_eq VAR_CONTEST_TYPE, CONTEST_TYPE_LINK, ContestHall_EventScript_EntryXTrainersMonLink message ContestHall_Text_EntryXTrainersMon waitmessage return @@ -441,15 +424,13 @@ ContestHall_EventScript_AudienceVote:: return ContestHall_EventScript_AudienceWillVote:: - compare VAR_CONTEST_TYPE, CONTEST_TYPE_LINK - goto_if_eq ContestHall_EventScript_AudienceWillVoteLink + goto_if_eq VAR_CONTEST_TYPE, CONTEST_TYPE_LINK, ContestHall_EventScript_AudienceWillVoteLink msgbox ContestHall_Text_SeenContestantsAudienceWillVote, MSGBOX_DEFAULT return ContestHall_EventScript_AudienceWillVoteLink:: specialvar VAR_RESULT, IsWirelessContest - compare VAR_RESULT, TRUE - goto_if_eq ContestHall_EventScript_AudienceWillVoteWireless + goto_if_eq VAR_RESULT, TRUE, ContestHall_EventScript_AudienceWillVoteWireless messageautoscroll ContestHall_Text_SeenContestantsAudienceWillVote waitmessage return @@ -467,8 +448,7 @@ ContestHall_EventScript_AudienceWillVoteWireless:: return ContestHall_EventScript_VotingUnderWay:: - compare VAR_CONTEST_TYPE, CONTEST_TYPE_LINK - goto_if_eq ContestHall_EventScript_VotingUnderWayLink + goto_if_eq VAR_CONTEST_TYPE, CONTEST_TYPE_LINK, ContestHall_EventScript_VotingUnderWayLink message ContestHall_Text_VotingUnderWay return @@ -510,16 +490,11 @@ ContestHall_EventScript_AudienceReactToContestant:: @ and are set to 9 if they havent displayed a heart yet, and 1 if they have ContestHall_EventScript_AudienceHeartEmotes:: special GetContestMonCondition - compare VAR_CONTEST_TYPE, CONTEST_TYPE_NPC_NORMAL - call_if_eq ContestHall_EventScript_GetNumberOfHeartsNormal - compare VAR_CONTEST_TYPE, CONTEST_TYPE_NPC_SUPER - call_if_eq ContestHall_EventScript_GetNumberOfHeartsSuper - compare VAR_CONTEST_TYPE, CONTEST_TYPE_NPC_HYPER - call_if_eq ContestHall_EventScript_GetNumberOfHeartsHyper - compare VAR_CONTEST_TYPE, CONTEST_TYPE_NPC_MASTER - call_if_eq ContestHall_EventScript_GetNumberOfHeartsMaster - compare VAR_CONTEST_TYPE, CONTEST_TYPE_LINK - call_if_eq ContestHall_EventScript_GetNumberOfHeartsLink + call_if_eq VAR_CONTEST_TYPE, CONTEST_TYPE_NPC_NORMAL, ContestHall_EventScript_GetNumberOfHeartsNormal + call_if_eq VAR_CONTEST_TYPE, CONTEST_TYPE_NPC_SUPER, ContestHall_EventScript_GetNumberOfHeartsSuper + call_if_eq VAR_CONTEST_TYPE, CONTEST_TYPE_NPC_HYPER, ContestHall_EventScript_GetNumberOfHeartsHyper + call_if_eq VAR_CONTEST_TYPE, CONTEST_TYPE_NPC_MASTER, ContestHall_EventScript_GetNumberOfHeartsMaster + call_if_eq VAR_CONTEST_TYPE, CONTEST_TYPE_LINK, ContestHall_EventScript_GetNumberOfHeartsLink setvar VAR_TEMP_1, 9 setvar VAR_TEMP_2, 9 setvar VAR_TEMP_3, 9 @@ -528,8 +503,7 @@ ContestHall_EventScript_AudienceHeartEmotes:: setvar VAR_TEMP_6, 9 setvar VAR_TEMP_7, 9 setvar VAR_TEMP_8, 9 - compare VAR_TEMP_0, 0 - call_if_gt ContestHall_EventScript_DisplayHearts + call_if_gt VAR_TEMP_0, 0, ContestHall_EventScript_DisplayHearts setvar VAR_TEMP_1, 0 setvar VAR_TEMP_2, 0 setvar VAR_TEMP_3, 0 @@ -543,124 +517,75 @@ ContestHall_EventScript_AudienceHeartEmotes:: ContestHall_EventScript_DisplayHearts:: setvar VAR_RESULT, 8 special GenerateContestRand - compare VAR_RESULT, 0 - call_if_eq ContestHall_EventScript_TryDisplayHeartAudienceMember1 - compare VAR_RESULT, 1 - call_if_eq ContestHall_EventScript_TryDisplayHeartAudienceMember2 - compare VAR_RESULT, 2 - call_if_eq ContestHall_EventScript_TryDisplayHeartAudienceMember3 - compare VAR_RESULT, 3 - call_if_eq ContestHall_EventScript_TryDisplayHeartAudienceMember4 - compare VAR_RESULT, 4 - call_if_eq ContestHall_EventScript_TryDisplayHeartAudienceMember5 - compare VAR_RESULT, 5 - call_if_eq ContestHall_EventScript_TryDisplayHeartAudienceMember6 - compare VAR_RESULT, 6 - call_if_eq ContestHall_EventScript_TryDisplayHeartAudienceMember7 - compare VAR_RESULT, 7 - call_if_eq ContestHall_EventScript_TryDisplayHeartAudienceMember8 - compare VAR_TEMP_0, 0 @ Still more hearts to display - goto_if_gt ContestHall_EventScript_DisplayHearts + call_if_eq VAR_RESULT, 0, ContestHall_EventScript_TryDisplayHeartAudienceMember1 + call_if_eq VAR_RESULT, 1, ContestHall_EventScript_TryDisplayHeartAudienceMember2 + call_if_eq VAR_RESULT, 2, ContestHall_EventScript_TryDisplayHeartAudienceMember3 + call_if_eq VAR_RESULT, 3, ContestHall_EventScript_TryDisplayHeartAudienceMember4 + call_if_eq VAR_RESULT, 4, ContestHall_EventScript_TryDisplayHeartAudienceMember5 + call_if_eq VAR_RESULT, 5, ContestHall_EventScript_TryDisplayHeartAudienceMember6 + call_if_eq VAR_RESULT, 6, ContestHall_EventScript_TryDisplayHeartAudienceMember7 + call_if_eq VAR_RESULT, 7, ContestHall_EventScript_TryDisplayHeartAudienceMember8 + goto_if_gt VAR_TEMP_0, 0, ContestHall_EventScript_DisplayHearts @ Still more hearts to display waitmovement 0 return ContestHall_EventScript_GetNumberOfHeartsNormal:: - compare VAR_0x8004, 80 - goto_if_gt ContestHall_EventScript_Set8Hearts - compare VAR_0x8004, 70 - goto_if_gt ContestHall_EventScript_Set7Hearts - compare VAR_0x8004, 60 - goto_if_gt ContestHall_EventScript_Set6Hearts - compare VAR_0x8004, 50 - goto_if_gt ContestHall_EventScript_Set5Hearts - compare VAR_0x8004, 40 - goto_if_gt ContestHall_EventScript_Set4Hearts - compare VAR_0x8004, 30 - goto_if_gt ContestHall_EventScript_Set3Hearts - compare VAR_0x8004, 20 - goto_if_gt ContestHall_EventScript_Set2Hearts - compare VAR_0x8004, 10 - goto_if_gt ContestHall_EventScript_Set1Heart + goto_if_gt VAR_0x8004, 80, ContestHall_EventScript_Set8Hearts + goto_if_gt VAR_0x8004, 70, ContestHall_EventScript_Set7Hearts + goto_if_gt VAR_0x8004, 60, ContestHall_EventScript_Set6Hearts + goto_if_gt VAR_0x8004, 50, ContestHall_EventScript_Set5Hearts + goto_if_gt VAR_0x8004, 40, ContestHall_EventScript_Set4Hearts + goto_if_gt VAR_0x8004, 30, ContestHall_EventScript_Set3Hearts + goto_if_gt VAR_0x8004, 20, ContestHall_EventScript_Set2Hearts + goto_if_gt VAR_0x8004, 10, ContestHall_EventScript_Set1Heart setvar VAR_TEMP_0, 0 return ContestHall_EventScript_GetNumberOfHeartsSuper:: - compare VAR_0x8004, 230 - goto_if_gt ContestHall_EventScript_Set8Hearts - compare VAR_0x8004, 210 - goto_if_gt ContestHall_EventScript_Set7Hearts - compare VAR_0x8004, 190 - goto_if_gt ContestHall_EventScript_Set6Hearts - compare VAR_0x8004, 170 - goto_if_gt ContestHall_EventScript_Set5Hearts - compare VAR_0x8004, 150 - goto_if_gt ContestHall_EventScript_Set4Hearts - compare VAR_0x8004, 130 - goto_if_gt ContestHall_EventScript_Set3Hearts - compare VAR_0x8004, 110 - goto_if_gt ContestHall_EventScript_Set2Hearts - compare VAR_0x8004, 90 - goto_if_gt ContestHall_EventScript_Set1Heart + goto_if_gt VAR_0x8004, 230, ContestHall_EventScript_Set8Hearts + goto_if_gt VAR_0x8004, 210, ContestHall_EventScript_Set7Hearts + goto_if_gt VAR_0x8004, 190, ContestHall_EventScript_Set6Hearts + goto_if_gt VAR_0x8004, 170, ContestHall_EventScript_Set5Hearts + goto_if_gt VAR_0x8004, 150, ContestHall_EventScript_Set4Hearts + goto_if_gt VAR_0x8004, 130, ContestHall_EventScript_Set3Hearts + goto_if_gt VAR_0x8004, 110, ContestHall_EventScript_Set2Hearts + goto_if_gt VAR_0x8004, 90, ContestHall_EventScript_Set1Heart setvar VAR_TEMP_0, 0 return ContestHall_EventScript_GetNumberOfHeartsHyper:: - compare VAR_0x8004, 380 - goto_if_gt ContestHall_EventScript_Set8Hearts - compare VAR_0x8004, 350 - goto_if_gt ContestHall_EventScript_Set7Hearts - compare VAR_0x8004, 320 - goto_if_gt ContestHall_EventScript_Set6Hearts - compare VAR_0x8004, 290 - goto_if_gt ContestHall_EventScript_Set5Hearts - compare VAR_0x8004, 260 - goto_if_gt ContestHall_EventScript_Set4Hearts - compare VAR_0x8004, 230 - goto_if_gt ContestHall_EventScript_Set3Hearts - compare VAR_0x8004, 200 - goto_if_gt ContestHall_EventScript_Set2Hearts - compare VAR_0x8004, 170 - goto_if_gt ContestHall_EventScript_Set1Heart + goto_if_gt VAR_0x8004, 380, ContestHall_EventScript_Set8Hearts + goto_if_gt VAR_0x8004, 350, ContestHall_EventScript_Set7Hearts + goto_if_gt VAR_0x8004, 320, ContestHall_EventScript_Set6Hearts + goto_if_gt VAR_0x8004, 290, ContestHall_EventScript_Set5Hearts + goto_if_gt VAR_0x8004, 260, ContestHall_EventScript_Set4Hearts + goto_if_gt VAR_0x8004, 230, ContestHall_EventScript_Set3Hearts + goto_if_gt VAR_0x8004, 200, ContestHall_EventScript_Set2Hearts + goto_if_gt VAR_0x8004, 170, ContestHall_EventScript_Set1Heart setvar VAR_TEMP_0, 0 return ContestHall_EventScript_GetNumberOfHeartsMaster:: - compare VAR_0x8004, 600 - goto_if_gt ContestHall_EventScript_Set8Hearts - compare VAR_0x8004, 560 - goto_if_gt ContestHall_EventScript_Set7Hearts - compare VAR_0x8004, 520 - goto_if_gt ContestHall_EventScript_Set6Hearts - compare VAR_0x8004, 480 - goto_if_gt ContestHall_EventScript_Set5Hearts - compare VAR_0x8004, 440 - goto_if_gt ContestHall_EventScript_Set4Hearts - compare VAR_0x8004, 400 - goto_if_gt ContestHall_EventScript_Set3Hearts - compare VAR_0x8004, 360 - goto_if_gt ContestHall_EventScript_Set2Hearts - compare VAR_0x8004, 320 - goto_if_gt ContestHall_EventScript_Set1Heart + goto_if_gt VAR_0x8004, 600, ContestHall_EventScript_Set8Hearts + goto_if_gt VAR_0x8004, 560, ContestHall_EventScript_Set7Hearts + goto_if_gt VAR_0x8004, 520, ContestHall_EventScript_Set6Hearts + goto_if_gt VAR_0x8004, 480, ContestHall_EventScript_Set5Hearts + goto_if_gt VAR_0x8004, 440, ContestHall_EventScript_Set4Hearts + goto_if_gt VAR_0x8004, 400, ContestHall_EventScript_Set3Hearts + goto_if_gt VAR_0x8004, 360, ContestHall_EventScript_Set2Hearts + goto_if_gt VAR_0x8004, 320, ContestHall_EventScript_Set1Heart setvar VAR_TEMP_0, 0 return ContestHall_EventScript_GetNumberOfHeartsLink:: - compare VAR_0x8004, 600 - goto_if_gt ContestHall_EventScript_Set8Hearts - compare VAR_0x8004, 550 - goto_if_gt ContestHall_EventScript_Set7Hearts - compare VAR_0x8004, 500 - goto_if_gt ContestHall_EventScript_Set6Hearts - compare VAR_0x8004, 450 - goto_if_gt ContestHall_EventScript_Set5Hearts - compare VAR_0x8004, 400 - goto_if_gt ContestHall_EventScript_Set4Hearts - compare VAR_0x8004, 300 - goto_if_gt ContestHall_EventScript_Set3Hearts - compare VAR_0x8004, 200 - goto_if_gt ContestHall_EventScript_Set2Hearts - compare VAR_0x8004, 100 - goto_if_gt ContestHall_EventScript_Set1Heart + goto_if_gt VAR_0x8004, 600, ContestHall_EventScript_Set8Hearts + goto_if_gt VAR_0x8004, 550, ContestHall_EventScript_Set7Hearts + goto_if_gt VAR_0x8004, 500, ContestHall_EventScript_Set6Hearts + goto_if_gt VAR_0x8004, 450, ContestHall_EventScript_Set5Hearts + goto_if_gt VAR_0x8004, 400, ContestHall_EventScript_Set4Hearts + goto_if_gt VAR_0x8004, 300, ContestHall_EventScript_Set3Hearts + goto_if_gt VAR_0x8004, 200, ContestHall_EventScript_Set2Hearts + goto_if_gt VAR_0x8004, 100, ContestHall_EventScript_Set1Heart setvar VAR_TEMP_0, 0 return @@ -697,8 +622,7 @@ ContestHall_EventScript_Set8Hearts:: return ContestHall_EventScript_TryDisplayHeartAudienceMember1:: - compare VAR_TEMP_1, 1 - goto_if_eq ContestHall_EventScript_AudienceMember1AlreadyEmoted + goto_if_eq VAR_TEMP_1, 1, ContestHall_EventScript_AudienceMember1AlreadyEmoted applymovement LOCALID_AUDIENCE_1, ContestHall_Movement_Heart playse SE_PIN delay 14 @@ -710,8 +634,7 @@ ContestHall_EventScript_AudienceMember1AlreadyEmoted:: return ContestHall_EventScript_TryDisplayHeartAudienceMember2:: - compare VAR_TEMP_2, 1 - goto_if_eq ContestHall_EventScript_AudienceMember2AlreadyEmoted + goto_if_eq VAR_TEMP_2, 1, ContestHall_EventScript_AudienceMember2AlreadyEmoted applymovement LOCALID_AUDIENCE_2, ContestHall_Movement_Heart playse SE_PIN delay 14 @@ -723,8 +646,7 @@ ContestHall_EventScript_AudienceMember2AlreadyEmoted:: return ContestHall_EventScript_TryDisplayHeartAudienceMember3:: - compare VAR_TEMP_3, 1 - goto_if_eq ContestHall_EventScript_AudienceMember3AlreadyEmoted + goto_if_eq VAR_TEMP_3, 1, ContestHall_EventScript_AudienceMember3AlreadyEmoted applymovement LOCALID_AUDIENCE_3, ContestHall_Movement_Heart playse SE_PIN delay 14 @@ -736,8 +658,7 @@ ContestHall_EventScript_AudienceMember3AlreadyEmoted:: return ContestHall_EventScript_TryDisplayHeartAudienceMember4:: - compare VAR_TEMP_4, 1 - goto_if_eq ContestHall_EventScript_Audience4MemberAlreadyEmoted + goto_if_eq VAR_TEMP_4, 1, ContestHall_EventScript_Audience4MemberAlreadyEmoted applymovement LOCALID_AUDIENCE_4, ContestHall_Movement_Heart playse SE_PIN delay 14 @@ -749,8 +670,7 @@ ContestHall_EventScript_Audience4MemberAlreadyEmoted:: return ContestHall_EventScript_TryDisplayHeartAudienceMember5:: - compare VAR_TEMP_5, 1 - goto_if_eq ContestHall_EventScript_AudienceMember5AlreadyEmoted + goto_if_eq VAR_TEMP_5, 1, ContestHall_EventScript_AudienceMember5AlreadyEmoted applymovement LOCALID_AUDIENCE_5, ContestHall_Movement_Heart playse SE_PIN delay 14 @@ -762,8 +682,7 @@ ContestHall_EventScript_AudienceMember5AlreadyEmoted:: return ContestHall_EventScript_TryDisplayHeartAudienceMember6:: - compare VAR_TEMP_6, 1 - goto_if_eq ContestHall_EventScript_AudienceMember6AlreadyEmoted + goto_if_eq VAR_TEMP_6, 1, ContestHall_EventScript_AudienceMember6AlreadyEmoted applymovement LOCALID_AUDIENCE_6, ContestHall_Movement_Heart playse SE_PIN delay 14 @@ -775,8 +694,7 @@ ContestHall_EventScript_AudienceMember6AlreadyEmoted:: return ContestHall_EventScript_TryDisplayHeartAudienceMember7:: - compare VAR_TEMP_7, 1 - goto_if_eq ContestHall_EventScript_AudienceMember7AlreadyEmoted + goto_if_eq VAR_TEMP_7, 1, ContestHall_EventScript_AudienceMember7AlreadyEmoted applymovement LOCALID_AUDIENCE_7, ContestHall_Movement_Heart playse SE_PIN delay 14 @@ -788,8 +706,7 @@ ContestHall_EventScript_AudienceMember7AlreadyEmoted:: return ContestHall_EventScript_TryDisplayHeartAudienceMember8:: - compare VAR_TEMP_8, 1 - goto_if_eq ContestHall_EventScript_AudienceMember8AlreadyEmoted + goto_if_eq VAR_TEMP_8, 1, ContestHall_EventScript_AudienceMember8AlreadyEmoted applymovement LOCALID_ARTIST, ContestHall_Movement_Heart playse SE_PIN delay 14 @@ -870,15 +787,13 @@ ContestHall_EventScript_DoContestAppeals:: return ContestHall_EventScript_LetsAppeal:: - compare VAR_CONTEST_TYPE, CONTEST_TYPE_LINK - goto_if_eq ContestHall_EventScript_LetsAppealLink + goto_if_eq VAR_CONTEST_TYPE, CONTEST_TYPE_LINK, ContestHall_EventScript_LetsAppealLink msgbox ContestHall_Text_VotingCompleteLetsAppeal, MSGBOX_DEFAULT return ContestHall_EventScript_LetsAppealLink:: specialvar VAR_RESULT, IsWirelessContest - compare VAR_RESULT, TRUE - goto_if_eq ContestHall_EventScript_LetsAppealWireless + goto_if_eq VAR_RESULT, TRUE, ContestHall_EventScript_LetsAppealWireless messageautoscroll ContestHall_Text_VotingCompleteLetsAppeal waitmessage return @@ -920,8 +835,7 @@ ContestHall_EventScript_ContestResults:: return ContestHall_EventScript_ThatsItForJudging:: - compare VAR_CONTEST_TYPE, CONTEST_TYPE_LINK - goto_if_eq ContestHall_EventScript_ThatsItForJudgingLink + goto_if_eq VAR_CONTEST_TYPE, CONTEST_TYPE_LINK, ContestHall_EventScript_ThatsItForJudgingLink msgbox ContestHall_Text_ThatsItForJudging, MSGBOX_DEFAULT return @@ -933,8 +847,7 @@ ContestHall_EventScript_ThatsItForJudgingLink:: return ContestHall_EventScript_ThankYouForAppeals:: - compare VAR_CONTEST_TYPE, CONTEST_TYPE_LINK - goto_if_eq ContestHall_EventScript_ThankYouForAppealsLink + goto_if_eq VAR_CONTEST_TYPE, CONTEST_TYPE_LINK, ContestHall_EventScript_ThankYouForAppealsLink msgbox ContestHall_Text_ThankYouForAppeals, MSGBOX_DEFAULT return @@ -946,8 +859,7 @@ ContestHall_EventScript_ThankYouForAppealsLink:: return ContestHall_EventScript_JudgeLooksReady:: - compare VAR_CONTEST_TYPE, CONTEST_TYPE_LINK - goto_if_eq ContestHall_EventScript_JudgeLooksReadyLink + goto_if_eq VAR_CONTEST_TYPE, CONTEST_TYPE_LINK, ContestHall_EventScript_JudgeLooksReadyLink msgbox ContestHall_Text_JudgeLooksReady, MSGBOX_DEFAULT return @@ -959,8 +871,7 @@ ContestHall_EventScript_JudgeLooksReadyLink:: return ContestHall_EventScript_WeWillDeclareWinner:: - compare VAR_CONTEST_TYPE, CONTEST_TYPE_LINK - goto_if_eq ContestHall_EventScript_WeWillDeclareWinnerLink + goto_if_eq VAR_CONTEST_TYPE, CONTEST_TYPE_LINK, ContestHall_EventScript_WeWillDeclareWinnerLink msgbox ContestHall_Text_WeWillNowDeclareWinner, MSGBOX_DEFAULT return @@ -1000,7 +911,7 @@ ContestHall_EventScript_CongratulateWinner:: special BufferContestWinnerTrainerName special BufferContestWinnerMonName addvar VAR_0x8005, 1 - buffernumberstring 1, VAR_0x8005 + buffernumberstring STR_VAR_2, VAR_0x8005 addvar VAR_0x8005, -1 call ContestHall_EventScript_CongratsWinner applymovement VAR_TEMP_3, ContestHall_Movement_WinningPlayerWalkUp @@ -1010,8 +921,7 @@ ContestHall_EventScript_CongratulateWinner:: return ContestHall_EventScript_CongratsWinner:: - compare VAR_CONTEST_TYPE, CONTEST_TYPE_LINK - goto_if_eq ContestHall_EventScript_CongratsWinnerLink + goto_if_eq VAR_CONTEST_TYPE, CONTEST_TYPE_LINK, ContestHall_EventScript_CongratsWinnerLink msgbox ContestHall_Text_CongratsTrainerXandMon, MSGBOX_DEFAULT return @@ -1023,8 +933,7 @@ ContestHall_EventScript_CongratsWinnerLink:: ContestHall_EventScript_AudienceLookAround:: addvar VAR_TEMP_1, 1 lockall - compare VAR_CONTEST_TYPE, CONTEST_TYPE_NPC_NORMAL - call_if_gt ContestHall_EventScript_VObjectAudienceLookAround + call_if_gt VAR_CONTEST_TYPE, CONTEST_TYPE_NPC_NORMAL, ContestHall_EventScript_VObjectAudienceLookAround applymovement LOCALID_AUDIENCE_5, ContestHall_Movement_AudienceMemberLookRight applymovement LOCALID_AUDIENCE_2, ContestHall_Movement_AudienceMemberLookDown applymovement LOCALID_AUDIENCE_3, ContestHall_Movement_AudienceMemberLookRight @@ -1033,8 +942,7 @@ ContestHall_EventScript_AudienceLookAround:: applymovement LOCALID_AUDIENCE_7, ContestHall_Movement_AudienceMemberLookDown applymovement LOCALID_AUDIENCE_1, ContestHall_Movement_AudienceMemberLookUp applymovement LOCALID_AUDIENCE_4, ContestHall_Movement_AudienceMemberLookLeft - compare VAR_TEMP_1, 4 - goto_if_ne ContestHall_EventScript_AudienceLookAround + goto_if_ne VAR_TEMP_1, 4, ContestHall_EventScript_AudienceLookAround delay 30 return @@ -1108,8 +1016,7 @@ ContestHall_EventScript_VObjectAudienceLookAround:: return ContestHall_EventScript_GiveWinnerPrize:: - compare VAR_CONTEST_TYPE, CONTEST_TYPE_LINK - goto_if_eq ContestHall_EventScript_EndLinkContest + goto_if_eq VAR_CONTEST_TYPE, CONTEST_TYPE_LINK, ContestHall_EventScript_EndLinkContest call ContestHall_EventScript_CheckShouldSkipPrize goto_if_set FLAG_TEMP_2, ContestHall_EventScript_SkipPrize lockall @@ -1122,8 +1029,7 @@ ContestHall_EventScript_GiveWinnerPrize:: call ContestHall_EventScript_AudienceLookAround delay 30 special ShouldReadyContestArtist - compare VAR_0x8004, TRUE - goto_if_eq ContestHall_EventScript_SetReadyForContestArtist + goto_if_eq VAR_0x8004, TRUE, ContestHall_EventScript_SetReadyForContestArtist return ContestHall_EventScript_SkipPrize:: @@ -1132,25 +1038,21 @@ ContestHall_EventScript_SkipPrize:: releaseall delay 90 special ShouldReadyContestArtist - compare VAR_0x8004, TRUE - goto_if_eq ContestHall_EventScript_SetReadyForContestArtist + goto_if_eq VAR_0x8004, TRUE, ContestHall_EventScript_SetReadyForContestArtist return ContestHall_EventScript_CheckShouldSkipPrize:: specialvar VAR_RESULT, HasMonWonThisContestBefore - compare VAR_RESULT, TRUE - goto_if_eq ContestHall_EventScript_CheckPlayerWon + goto_if_eq VAR_RESULT, TRUE, ContestHall_EventScript_CheckPlayerWon return ContestHall_EventScript_CheckPlayerWon:: special GetContestWinnerId - compare VAR_0x8005, 3 - goto_if_eq ContestHall_EventScript_CheckRankIsMaster + goto_if_eq VAR_0x8005, 3, ContestHall_EventScript_CheckRankIsMaster return ContestHall_EventScript_CheckRankIsMaster:: - compare VAR_CONTEST_RANK, CONTEST_RANK_MASTER - goto_if_eq ContestHall_EventScript_DontSkipPrize + goto_if_eq VAR_CONTEST_RANK, CONTEST_RANK_MASTER, ContestHall_EventScript_DontSkipPrize setflag FLAG_TEMP_2 return @@ -1171,8 +1073,7 @@ ContestHall_EventScript_EndLinkContest:: special GetContestPlayerId special GetContestWinnerId special ShouldReadyContestArtist - compare VAR_0x8004, TRUE - goto_if_eq ContestHall_EventScript_SetReadyForLinkContestArtist + goto_if_eq VAR_0x8004, TRUE, ContestHall_EventScript_SetReadyForLinkContestArtist closemessage return @@ -1223,21 +1124,17 @@ ContestHall_EventScript_Player4ApproachForPrize:: @ In NPC Contests, the player is always entry 4 (id number 3) ContestHall_EventScript_GivePrizeIfWinner:: special GetContestWinnerId - compare VAR_0x8005, 3 - goto_if_eq ContestHall_EventScript_GiveContestPrizes + goto_if_eq VAR_0x8005, 3, ContestHall_EventScript_GiveContestPrizes lockall msgbox ContestHall_Text_CongratsPleaseCompeteAgain, MSGBOX_DEFAULT releaseall return ContestHall_EventScript_GiveContestPrizes:: - compare VAR_CONTEST_TYPE, CONTEST_TYPE_NPC_SUPER - call_if_eq ContestHall_EventScript_SetSketchFlag + call_if_eq VAR_CONTEST_TYPE, CONTEST_TYPE_NPC_SUPER, ContestHall_EventScript_SetSketchFlag specialvar VAR_RESULT, HasMonWonThisContestBefore - compare VAR_RESULT, FALSE - goto_if_eq ContestHall_EventScript_ReceiveContestRibbon - compare VAR_CONTEST_RANK, CONTEST_RANK_MASTER - goto_if_eq ContestHall_EventScript_GiveLuxuryBall + goto_if_eq VAR_RESULT, FALSE, ContestHall_EventScript_ReceiveContestRibbon + goto_if_eq VAR_CONTEST_RANK, CONTEST_RANK_MASTER, ContestHall_EventScript_GiveLuxuryBall lockall msgbox ContestHall_Text_CongratsPleaseCompeteAgain, MSGBOX_DEFAULT releaseall @@ -1253,8 +1150,7 @@ ContestHall_EventScript_NoRoomForLuxuryBall:: ContestHall_EventScript_GiveLuxuryBall:: giveitem ITEM_LUXURY_BALL - compare VAR_RESULT, FALSE - goto_if_eq ContestHall_EventScript_NoRoomForLuxuryBall + goto_if_eq VAR_RESULT, FALSE, ContestHall_EventScript_NoRoomForLuxuryBall lockall msgbox ContestHall_Text_CongratsPleaseCompeteAgain, MSGBOX_DEFAULT releaseall @@ -1460,8 +1356,7 @@ ContestHall_Movement_Player2ApproachForPrize: @ IsContestWithRSPlayer has no side effect, so this is nop ContestHall_EventScript_CheckIfContestWithRSPlayer:: specialvar VAR_RESULT, IsContestWithRSPlayer - compare VAR_RESULT, TRUE - goto_if_eq ContestHall_EventScript_RetRSPlayer + goto_if_eq VAR_RESULT, TRUE, ContestHall_EventScript_RetRSPlayer return ContestHall_EventScript_RetRSPlayer:: @@ -1469,8 +1364,7 @@ ContestHall_EventScript_RetRSPlayer:: LilycoveCity_ContestLobby_EventScript_DelayIfContestWithRSPlayer:: specialvar VAR_RESULT, IsContestWithRSPlayer - compare VAR_RESULT, TRUE - goto_if_eq LilycoveCity_ContestLobby_EventScript_DelayForRSPlayer + goto_if_eq VAR_RESULT, TRUE, LilycoveCity_ContestLobby_EventScript_DelayForRSPlayer return LilycoveCity_ContestLobby_EventScript_DelayForRSPlayer:: diff --git a/data/scripts/day_care.inc b/data/scripts/day_care.inc index 8d529d5e1..cb053f2c4 100644 --- a/data/scripts/day_care.inc +++ b/data/scripts/day_care.inc @@ -5,23 +5,18 @@ Route117_EventScript_DaycareMan:: faceplayer special GetDaycareMonNicknames specialvar VAR_RESULT, GetDaycareState - compare VAR_RESULT, DAYCARE_EGG_WAITING - goto_if_eq Route117_EventScript_DaycareEggWaiting - compare VAR_RESULT, DAYCARE_ONE_MON - goto_if_eq Route117_EventScript_CheckOnOneMon - compare VAR_RESULT, DAYCARE_TWO_MONS - goto_if_eq Route117_EventScript_CheckOnTwoMons + goto_if_eq VAR_RESULT, DAYCARE_EGG_WAITING, Route117_EventScript_DaycareEggWaiting + goto_if_eq VAR_RESULT, DAYCARE_ONE_MON, Route117_EventScript_CheckOnOneMon + goto_if_eq VAR_RESULT, DAYCARE_TWO_MONS, Route117_EventScript_CheckOnTwoMons msgbox Route117_Text_SeeWifeIfYoudLikeMeToRaiseMon, MSGBOX_DEFAULT release end Route117_EventScript_DaycareEggWaiting:: msgbox Route117_Text_DoYouWantEgg, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq Route117_EventScript_DaycareAcceptEgg + goto_if_eq VAR_RESULT, YES, Route117_EventScript_DaycareAcceptEgg msgbox Route117_Text_IWillKeepDoYouWantIt, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq Route117_EventScript_DaycareAcceptEgg + goto_if_eq VAR_RESULT, YES, Route117_EventScript_DaycareAcceptEgg msgbox Route117_Text_IllKeepIt, MSGBOX_DEFAULT clearflag FLAG_PENDING_DAYCARE_EGG special RejectEggFromDayCare @@ -30,8 +25,7 @@ Route117_EventScript_DaycareEggWaiting:: Route117_EventScript_DaycareAcceptEgg:: specialvar VAR_RESULT, CalculatePlayerPartyCount - compare VAR_RESULT, PARTY_SIZE - goto_if_ne Route117_EventScript_DaycareReceiveEgg + goto_if_ne VAR_RESULT, PARTY_SIZE, Route117_EventScript_DaycareReceiveEgg msgbox Route117_Text_YouHaveNoRoomForIt, MSGBOX_DEFAULT release end @@ -49,8 +43,7 @@ Route117_EventScript_DaycareReceiveEgg:: Route117_EventScript_CheckMonReceivedMail:: specialvar VAR_RESULT, CheckDaycareMonReceivedMail - compare VAR_RESULT, 1 - call_if_eq Route117_EventScript_MonReceivedMail + call_if_eq VAR_RESULT, 1, Route117_EventScript_MonReceivedMail return Route117_EventScript_MonReceivedMail:: @@ -83,35 +76,27 @@ Route117_PokemonDayCare_EventScript_DaycareWoman:: lock faceplayer specialvar VAR_RESULT, GetDaycareState - compare VAR_RESULT, DAYCARE_EGG_WAITING - goto_if_eq Route117_PokemonDayCare_EventScript_EggWaiting - compare VAR_RESULT, DAYCARE_ONE_MON - goto_if_eq Route117_PokemonDayCare_EventScript_OneMonInDaycare - compare VAR_RESULT, DAYCARE_TWO_MONS - goto_if_eq Route117_PokemonDayCare_EventScript_TwoMonsInDaycare + goto_if_eq VAR_RESULT, DAYCARE_EGG_WAITING, Route117_PokemonDayCare_EventScript_EggWaiting + goto_if_eq VAR_RESULT, DAYCARE_ONE_MON, Route117_PokemonDayCare_EventScript_OneMonInDaycare + goto_if_eq VAR_RESULT, DAYCARE_TWO_MONS, Route117_PokemonDayCare_EventScript_TwoMonsInDaycare msgbox Route117_PokemonDayCare_Text_WouldYouLikeUsToRaiseAMon, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq Route117_PokemonDayCare_EventScript_GiveMonToRaise + goto_if_eq VAR_RESULT, YES, Route117_PokemonDayCare_EventScript_GiveMonToRaise msgbox Route117_PokemonDayCare_Text_FineThenComeAgain, MSGBOX_DEFAULT release end Route117_PokemonDayCare_EventScript_GiveMonToRaise:: specialvar VAR_RESULT, CountPartyNonEggMons - compare VAR_RESULT, 1 - goto_if_eq Route117_PokemonDayCare_EventScript_OnlyOneMon + goto_if_eq VAR_RESULT, 1, Route117_PokemonDayCare_EventScript_OnlyOneMon specialvar VAR_RESULT, CountPartyAliveNonEggMons - compare VAR_RESULT, 2 - goto_if_eq Route117_PokemonDayCare_EventScript_OnlyTwoAliveMons + goto_if_eq VAR_RESULT, 2, Route117_PokemonDayCare_EventScript_OnlyTwoAliveMons msgbox Route117_PokemonDayCare_Text_WhichMonShouldWeRaise, MSGBOX_DEFAULT fadescreen FADE_TO_BLACK special ChooseSendDaycareMon waitstate - compare VAR_0x8004, 255 - goto_if_eq Route117_PokemonDayCare_EventScript_ComeAgain + goto_if_eq VAR_0x8004, PARTY_NOTHING_CHOSEN, Route117_PokemonDayCare_EventScript_ComeAgain specialvar VAR_RESULT, CountPartyAliveNonEggMons_IgnoreVar0x8004Slot - compare VAR_RESULT, 0 - goto_if_eq Route117_PokemonDayCare_EventScript_OnlyOneAliveMon + goto_if_eq VAR_RESULT, 0, Route117_PokemonDayCare_EventScript_OnlyOneAliveMon specialvar VAR_0x8005, GetSelectedMonNicknameAndSpecies waitse playmoncry VAR_0x8005, CRY_MODE_NORMAL @@ -120,8 +105,7 @@ Route117_PokemonDayCare_EventScript_GiveMonToRaise:: special StoreSelectedPokemonInDaycare incrementgamestat GAME_STAT_USED_DAYCARE specialvar VAR_RESULT, GetDaycareState - compare VAR_RESULT, DAYCARE_ONE_MON - goto_if_eq Route117_PokemonDayCare_EventScript_CanRaiseOneMore + goto_if_eq VAR_RESULT, DAYCARE_ONE_MON, Route117_PokemonDayCare_EventScript_CanRaiseOneMore release end @@ -132,8 +116,7 @@ Route117_PokemonDayCare_EventScript_ComeAgain:: Route117_PokemonDayCare_EventScript_CanRaiseOneMore:: msgbox Route117_PokemonDayCare_Text_WeCanRaiseOneMore, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq Route117_PokemonDayCare_EventScript_GiveMonToRaise + goto_if_eq VAR_RESULT, YES, Route117_PokemonDayCare_EventScript_GiveMonToRaise goto Route117_PokemonDayCare_EventScript_ComeAgain end @@ -163,8 +146,7 @@ Route117_PokemonDayCare_EventScript_YourMonHasGrownXLevels:: Route117_PokemonDayCare_EventScript_DisplayLevelsGained:: specialvar VAR_RESULT, GetNumLevelsGainedFromDaycare - compare VAR_RESULT, 0 - call_if_ne Route117_PokemonDayCare_EventScript_YourMonHasGrownXLevels + call_if_ne VAR_RESULT, 0, Route117_PokemonDayCare_EventScript_YourMonHasGrownXLevels return Route117_PokemonDayCare_EventScript_OneMonInDaycare:: @@ -172,42 +154,35 @@ Route117_PokemonDayCare_EventScript_OneMonInDaycare:: setvar VAR_0x8004, 0 call Route117_PokemonDayCare_EventScript_DisplayLevelsGained msgbox Route117_PokemonDayCare_Text_WeCanRaiseOneMore, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq Route117_PokemonDayCare_EventScript_GiveMonToRaise + goto_if_eq VAR_RESULT, YES, Route117_PokemonDayCare_EventScript_GiveMonToRaise msgbox Route117_PokemonDayCare_Text_TakeYourMonBack, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq Route117_PokemonDayCare_EventScript_TryRetrieveMon + goto_if_eq VAR_RESULT, YES, Route117_PokemonDayCare_EventScript_TryRetrieveMon goto Route117_PokemonDayCare_EventScript_ComeAgain end Route117_PokemonDayCare_EventScript_TryRetrieveMon:: specialvar VAR_RESULT, CalculatePlayerPartyCount - compare VAR_RESULT, PARTY_SIZE - goto_if_eq Route117_PokemonDayCare_EventScript_NoRoom + goto_if_eq VAR_RESULT, PARTY_SIZE, Route117_PokemonDayCare_EventScript_NoRoom specialvar VAR_RESULT, GetDaycareState setvar VAR_0x8004, 0 - compare VAR_RESULT, DAYCARE_ONE_MON - goto_if_eq Route117_PokemonDayCare_EventScript_CostPrompt + goto_if_eq VAR_RESULT, DAYCARE_ONE_MON, Route117_PokemonDayCare_EventScript_CostPrompt special ShowDaycareLevelMenu waitstate copyvar VAR_0x8004, VAR_RESULT - compare VAR_RESULT, DAYCARE_EXITED_LEVEL_MENU - goto_if_eq Route117_PokemonDayCare_EventScript_ComeAgain + goto_if_eq VAR_RESULT, DAYCARE_EXITED_LEVEL_MENU, Route117_PokemonDayCare_EventScript_ComeAgain goto Route117_PokemonDayCare_EventScript_CostPrompt end Route117_PokemonDayCare_EventScript_CostPrompt:: special GetDaycareCost msgbox Route117_PokemonDayCare_Text_ItWillCostX, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq Route117_PokemonDayCare_EventScript_CheckEnoughMoney + goto_if_eq VAR_RESULT, YES, Route117_PokemonDayCare_EventScript_CheckEnoughMoney goto Route117_PokemonDayCare_EventScript_ComeAgain end Route117_PokemonDayCare_EventScript_CheckEnoughMoney:: specialvar VAR_RESULT, IsEnoughForCostInVar0x8005 - compare VAR_RESULT, 1 - goto_if_eq Route117_PokemonDayCare_EventScript_RetrieveMon + goto_if_eq VAR_RESULT, 1, Route117_PokemonDayCare_EventScript_RetrieveMon msgbox Route117_PokemonDayCare_Text_NotEnoughMoney, MSGBOX_DEFAULT release end @@ -224,15 +199,13 @@ Route117_PokemonDayCare_EventScript_RetrieveMon:: msgbox Route117_PokemonDayCare_Text_TookBackMon, MSGBOX_DEFAULT waitmoncry specialvar VAR_RESULT, GetDaycareState - compare VAR_RESULT, DAYCARE_ONE_MON - goto_if_eq Route117_PokemonDayCare_EventScript_AskRetrieveOtherMon + goto_if_eq VAR_RESULT, DAYCARE_ONE_MON, Route117_PokemonDayCare_EventScript_AskRetrieveOtherMon goto Route117_PokemonDayCare_EventScript_ComeAgain end Route117_PokemonDayCare_EventScript_AskRetrieveOtherMon:: msgbox Route117_PokemonDayCare_Text_TakeOtherOneBackToo, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq Route117_PokemonDayCare_EventScript_TryRetrieveMon + goto_if_eq VAR_RESULT, YES, Route117_PokemonDayCare_EventScript_TryRetrieveMon goto Route117_PokemonDayCare_EventScript_ComeAgain end @@ -274,8 +247,7 @@ Route117_PokemonDayCare_EventScript_TwoMonsInDaycare:: setvar VAR_0x8004, 1 call Route117_PokemonDayCare_EventScript_DisplayLevelsGained msgbox Route117_PokemonDayCare_Text_TakeYourMonBack, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq Route117_PokemonDayCare_EventScript_TryRetrieveMon + goto_if_eq VAR_RESULT, YES, Route117_PokemonDayCare_EventScript_TryRetrieveMon msgbox Route117_PokemonDayCare_Text_ComeAgain, MSGBOX_DEFAULT release end @@ -284,8 +256,7 @@ Route117_PokemonDayCare_EventScript_TwoMonsInDaycare:: Route117_PokemonDayCare_EventScript_UnusedRetrieveMon:: special ShowDaycareLevelMenu waitstate - compare VAR_RESULT, 2 - goto_if_eq Route117_PokemonDayCare_EventScript_ComeAgain + goto_if_eq VAR_RESULT, 2, Route117_PokemonDayCare_EventScript_ComeAgain copyvar VAR_0x8004, VAR_RESULT specialvar VAR_RESULT, TakePokemonFromDaycare msgbox Route117_PokemonDayCare_Text_HeresYourMon, MSGBOX_DEFAULT diff --git a/data/scripts/elite_four.inc b/data/scripts/elite_four.inc index 0ae319061..97d7f4131 100644 --- a/data/scripts/elite_four.inc +++ b/data/scripts/elite_four.inc @@ -2,18 +2,18 @@ PokemonLeague_EliteFour_SetAdvanceToNextRoomMetatiles:: 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 + setmetatile 6, 1, METATILE_EliteFour_OpenDoor_Frame, FALSE + setmetatile 6, 2, METATILE_EliteFour_OpenDoor_Opening, FALSE + setmetatile 0, 2, METATILE_EliteFour_RightSpotlightOff, TRUE + setmetatile 1, 2, METATILE_EliteFour_LeftSpotlightOff, TRUE + setmetatile 2, 2, METATILE_EliteFour_RightSpotlightOff, TRUE + setmetatile 3, 2, METATILE_EliteFour_LeftSpotlightOff, TRUE + setmetatile 4, 2, METATILE_EliteFour_RightSpotlightOff, TRUE + setmetatile 8, 2, METATILE_EliteFour_LeftSpotlightOff, TRUE + setmetatile 9, 2, METATILE_EliteFour_RightSpotlightOff, TRUE + setmetatile 10, 2, METATILE_EliteFour_LeftSpotlightOff, TRUE + setmetatile 11, 2, METATILE_EliteFour_RightSpotlightOff, TRUE + setmetatile 12, 2, METATILE_EliteFour_LeftSpotlightOff, TRUE special DrawWholeMapView return @@ -21,42 +21,42 @@ PokemonLeague_EliteFour_EventScript_WalkInCloseDoor:: applymovement OBJ_EVENT_ID_PLAYER, Common_Movement_WalkUp6 waitmovement 0 playse SE_TRUCK_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 + setmetatile 5, 12, METATILE_EliteFour_EntryDoor_ClosedTop, TRUE + setmetatile 6, 12, METATILE_EliteFour_EntryDoor_ClosedTop, TRUE + setmetatile 7, 12, METATILE_EliteFour_EntryDoor_ClosedTop, TRUE + setmetatile 5, 13, METATILE_EliteFour_EntryDoor_ClosedBottom, TRUE + setmetatile 6, 13, METATILE_EliteFour_EntryDoor_ClosedBottom, TRUE + setmetatile 7, 13, METATILE_EliteFour_EntryDoor_ClosedBottom, TRUE 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:: - 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 + setmetatile 6, 1, METATILE_EliteFour_OpenDoor_Frame, FALSE + setmetatile 6, 2, METATILE_EliteFour_OpenDoor_Opening, FALSE + setmetatile 5, 12, METATILE_EliteFour_EntryDoor_ClosedTop, TRUE + setmetatile 6, 12, METATILE_EliteFour_EntryDoor_ClosedTop, TRUE + setmetatile 7, 12, METATILE_EliteFour_EntryDoor_ClosedTop, TRUE + setmetatile 5, 13, METATILE_EliteFour_EntryDoor_ClosedBottom, TRUE + setmetatile 6, 13, METATILE_EliteFour_EntryDoor_ClosedBottom, TRUE + setmetatile 7, 13, METATILE_EliteFour_EntryDoor_ClosedBottom, TRUE + setmetatile 0, 2, METATILE_EliteFour_RightSpotlightOff, TRUE + setmetatile 1, 2, METATILE_EliteFour_LeftSpotlightOff, TRUE + setmetatile 2, 2, METATILE_EliteFour_RightSpotlightOff, TRUE + setmetatile 3, 2, METATILE_EliteFour_LeftSpotlightOff, TRUE + setmetatile 4, 2, METATILE_EliteFour_RightSpotlightOff, TRUE + setmetatile 8, 2, METATILE_EliteFour_LeftSpotlightOff, TRUE + setmetatile 9, 2, METATILE_EliteFour_RightSpotlightOff, TRUE + setmetatile 10, 2, METATILE_EliteFour_LeftSpotlightOff, TRUE + setmetatile 11, 2, METATILE_EliteFour_RightSpotlightOff, TRUE + setmetatile 12, 2, METATILE_EliteFour_LeftSpotlightOff, TRUE return PokemonLeague_EliteFour_EventScript_CloseDoor:: - 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 5, 12, METATILE_EliteFour_EntryDoor_ClosedTop, TRUE + setmetatile 6, 12, METATILE_EliteFour_EntryDoor_ClosedTop, TRUE + setmetatile 7, 12, METATILE_EliteFour_EntryDoor_ClosedTop, TRUE + setmetatile 5, 13, METATILE_EliteFour_EntryDoor_ClosedBottom, TRUE + setmetatile 6, 13, METATILE_EliteFour_EntryDoor_ClosedBottom, TRUE + setmetatile 7, 13, METATILE_EliteFour_EntryDoor_ClosedBottom, TRUE return diff --git a/data/scripts/field_move_scripts.inc b/data/scripts/field_move_scripts.inc index b81ca21dd..3e99fc08e 100644 --- a/data/scripts/field_move_scripts.inc +++ b/data/scripts/field_move_scripts.inc @@ -3,14 +3,12 @@ EventScript_CutTree:: lockall goto_if_unset FLAG_BADGE01_GET, EventScript_CheckTreeCantCut checkpartymove MOVE_CUT - compare VAR_RESULT, PARTY_SIZE - goto_if_eq EventScript_CheckTreeCantCut + goto_if_eq VAR_RESULT, PARTY_SIZE, EventScript_CheckTreeCantCut setfieldeffectargument 0, VAR_RESULT - bufferpartymonnick 0, VAR_RESULT - buffermovename 1, MOVE_CUT + bufferpartymonnick STR_VAR_1, VAR_RESULT + buffermovename STR_VAR_2, MOVE_CUT msgbox Text_WantToCut, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq EventScript_CancelCut + goto_if_eq VAR_RESULT, NO, EventScript_CancelCut msgbox Text_MonUsedFieldMove, MSGBOX_DEFAULT closemessage dofieldeffect FLDEFF_USE_CUT_ON_TREE @@ -64,14 +62,12 @@ EventScript_RockSmash:: lockall goto_if_unset FLAG_BADGE03_GET, EventScript_CantSmashRock checkpartymove MOVE_ROCK_SMASH - compare VAR_RESULT, PARTY_SIZE - goto_if_eq EventScript_CantSmashRock + goto_if_eq VAR_RESULT, PARTY_SIZE, EventScript_CantSmashRock setfieldeffectargument 0, VAR_RESULT - bufferpartymonnick 0, VAR_RESULT - buffermovename 1, MOVE_ROCK_SMASH + bufferpartymonnick STR_VAR_1, VAR_RESULT + buffermovename STR_VAR_2, MOVE_ROCK_SMASH msgbox Text_WantToSmash, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq EventScript_CancelSmash + goto_if_eq VAR_RESULT, NO, EventScript_CancelSmash msgbox Text_MonUsedFieldMove, MSGBOX_DEFAULT closemessage dofieldeffect FLDEFF_USE_ROCK_SMASH @@ -92,11 +88,9 @@ EventScript_SmashRock:: waitmovement 0 removeobject VAR_LAST_TALKED specialvar VAR_RESULT, TryUpdateRusturfTunnelState - compare VAR_RESULT, TRUE - goto_if_eq EventScript_EndSmash + goto_if_eq VAR_RESULT, TRUE, EventScript_EndSmash special RockSmashWildEncounter - compare VAR_RESULT, FALSE - goto_if_eq EventScript_EndSmash + goto_if_eq VAR_RESULT, FALSE, EventScript_EndSmash waitstate releaseall end @@ -132,12 +126,10 @@ EventScript_StrengthBoulder:: goto_if_unset FLAG_BADGE04_GET, EventScript_CantStrength goto_if_set FLAG_SYS_USE_STRENGTH, EventScript_CheckActivatedBoulder checkpartymove MOVE_STRENGTH - compare VAR_RESULT, PARTY_SIZE - goto_if_eq EventScript_CantStrength + goto_if_eq VAR_RESULT, PARTY_SIZE, EventScript_CantStrength setfieldeffectargument 0, VAR_RESULT msgbox Text_WantToStrength, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq EventScript_CancelStrength + goto_if_eq VAR_RESULT, NO, EventScript_CancelStrength closemessage dofieldeffect FLDEFF_USE_STRENGTH waitstate @@ -193,13 +185,11 @@ Text_StrengthActivated: EventScript_UseWaterfall:: lockall checkpartymove MOVE_WATERFALL - compare VAR_RESULT, PARTY_SIZE - goto_if_eq EventScript_CantWaterfall - bufferpartymonnick 0, VAR_RESULT + goto_if_eq VAR_RESULT, PARTY_SIZE, EventScript_CantWaterfall + bufferpartymonnick STR_VAR_1, VAR_RESULT setfieldeffectargument 0, VAR_RESULT msgbox Text_WantToWaterfall, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq EventScript_EndWaterfall + goto_if_eq VAR_RESULT, NO, EventScript_EndWaterfall msgbox Text_MonUsedWaterfall, MSGBOX_DEFAULT dofieldeffect FLDEFF_USE_WATERFALL goto EventScript_EndWaterfall @@ -228,14 +218,12 @@ Text_MonUsedWaterfall: EventScript_UseDive:: lockall checkpartymove MOVE_DIVE - compare VAR_RESULT, PARTY_SIZE - goto_if_eq EventScript_CantDive - bufferpartymonnick 0, VAR_RESULT + goto_if_eq VAR_RESULT, PARTY_SIZE, EventScript_CantDive + bufferpartymonnick STR_VAR_1, VAR_RESULT setfieldeffectargument 0, VAR_RESULT setfieldeffectargument 1, 1 msgbox Text_WantToDive, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq EventScript_EndDive + goto_if_eq VAR_RESULT, NO, EventScript_EndDive msgbox Text_MonUsedDive, MSGBOX_DEFAULT dofieldeffect FLDEFF_USE_DIVE goto EventScript_EndDive @@ -253,14 +241,12 @@ EventScript_EndDive:: EventScript_UseDiveUnderwater:: lockall checkpartymove MOVE_DIVE - compare VAR_RESULT, PARTY_SIZE - goto_if_eq EventScript_CantSurface - bufferpartymonnick 0, VAR_RESULT + goto_if_eq VAR_RESULT, PARTY_SIZE, EventScript_CantSurface + bufferpartymonnick STR_VAR_1, VAR_RESULT setfieldeffectargument 0, VAR_RESULT setfieldeffectargument 1, 1 msgbox Text_WantToSurface, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq EventScript_EndSurface + goto_if_eq VAR_RESULT, NO, EventScript_EndSurface msgbox Text_MonUsedDive, MSGBOX_DEFAULT dofieldeffect FLDEFF_USE_DIVE goto EventScript_EndSurface diff --git a/data/scripts/field_poison.inc b/data/scripts/field_poison.inc index a4f9b90b6..ddda34eba 100644 --- a/data/scripts/field_poison.inc +++ b/data/scripts/field_poison.inc @@ -2,10 +2,8 @@ EventScript_FieldPoison:: lockall special TryFieldPoisonWhiteOut waitstate - compare VAR_RESULT, FLDPSN_WHITEOUT - goto_if_eq EventScript_FieldWhiteOut - compare VAR_RESULT, FLDPSN_FRONTIER_WHITEOUT - goto_if_eq EventScript_FrontierFieldWhiteOut + goto_if_eq VAR_RESULT, FLDPSN_WHITEOUT, EventScript_FieldWhiteOut + goto_if_eq VAR_RESULT, FLDPSN_FRONTIER_WHITEOUT, EventScript_FrontierFieldWhiteOut releaseall end @@ -30,16 +28,12 @@ EventScript_FrontierFieldWhiteOut:: waitmessage waitbuttonpress pike_inchallenge - compare VAR_RESULT, TRUE - goto_if_eq BattleFrontier_BattlePike_EventScript_Retire + goto_if_eq VAR_RESULT, TRUE, BattleFrontier_BattlePike_EventScript_Retire pyramid_inchallenge - compare VAR_RESULT, 1 @ On Pyramid floor - goto_if_eq BattleFrontier_BattlePyramid_EventScript_WarpToLobbyLost - compare VAR_RESULT, 2 @ On Pyramid peak - goto_if_eq BattleFrontier_BattlePyramid_EventScript_WarpToLobbyLost + goto_if_eq VAR_RESULT, 1, BattleFrontier_BattlePyramid_EventScript_WarpToLobbyLost @ On Pyramid floor + goto_if_eq VAR_RESULT, 2, BattleFrontier_BattlePyramid_EventScript_WarpToLobbyLost @ On Pyramid peak trainerhill_inchallenge - compare VAR_RESULT, TRUE - goto_if_eq TrainerHill_1F_EventScript_Lost + goto_if_eq VAR_RESULT, TRUE, TrainerHill_1F_EventScript_Lost special Script_FadeOutMapMusic waitstate fadescreen FADE_TO_BLACK diff --git a/data/scripts/flash.inc b/data/scripts/flash.inc index a69975a16..dbfec2314 100644 --- a/data/scripts/flash.inc +++ b/data/scripts/flash.inc @@ -1,4 +1,4 @@ EventScript_UseFlash:: animateflash 1 - setflashradius 1 + setflashlevel 1 end diff --git a/data/scripts/gabby_and_ty.inc b/data/scripts/gabby_and_ty.inc index 68be27a02..e3dbdfd66 100644 --- a/data/scripts/gabby_and_ty.inc +++ b/data/scripts/gabby_and_ty.inc @@ -199,12 +199,9 @@ GabbyAndTy_EventScript_TyBattle6:: GabbyAndTy_EventScript_FirstInterview:: special GabbyAndTyBeforeInterview special GetGabbyAndTyLocalIds - compare VAR_FACING, DIR_NORTH - call_if_eq GabbyAndTy_EventScript_FacePlayerNorth - compare VAR_FACING, DIR_SOUTH - call_if_eq GabbyAndTy_EventScript_FacePlayerSouth - compare VAR_FACING, DIR_EAST - call_if_eq GabbyAndTy_EventScript_FacePlayerEast + call_if_eq VAR_FACING, DIR_NORTH, GabbyAndTy_EventScript_FacePlayerNorth + call_if_eq VAR_FACING, DIR_SOUTH, GabbyAndTy_EventScript_FacePlayerSouth + call_if_eq VAR_FACING, DIR_EAST, GabbyAndTy_EventScript_FacePlayerEast goto_if_set FLAG_TEMP_1, GabbyAndTy_EventScript_KeepingAnEyeOutForYou msgbox GabbyAndTy_Text_WhoAreYouInterview, MSGBOX_YESNO goto GabbyAndTy_EventScript_Interview @@ -230,16 +227,12 @@ GabbyAndTy_EventScript_FacePlayerEast:: GabbyAndTy_EventScript_RequestInterview:: special GabbyAndTyBeforeInterview special GetGabbyAndTyLocalIds - compare VAR_FACING, DIR_NORTH - call_if_eq GabbyAndTy_EventScript_FacePlayerNorth - compare VAR_FACING, DIR_SOUTH - call_if_eq GabbyAndTy_EventScript_FacePlayerSouth - compare VAR_FACING, DIR_EAST - call_if_eq GabbyAndTy_EventScript_FacePlayerEast + call_if_eq VAR_FACING, DIR_NORTH, GabbyAndTy_EventScript_FacePlayerNorth + call_if_eq VAR_FACING, DIR_SOUTH, GabbyAndTy_EventScript_FacePlayerSouth + call_if_eq VAR_FACING, DIR_EAST, GabbyAndTy_EventScript_FacePlayerEast goto_if_set FLAG_TEMP_1, GabbyAndTy_EventScript_KeepingAnEyeOutForYou specialvar VAR_RESULT, GabbyAndTyGetLastQuote - compare VAR_RESULT, 0 - goto_if_eq GabbyAndTy_EventScript_DidntInterviewLastTime + goto_if_eq VAR_RESULT, 0, GabbyAndTy_EventScript_DidntInterviewLastTime msgbox GabbyAndTy_Text_QuoteFromLastInterview, MSGBOX_DEFAULT specialvar VAR_RESULT, GabbyAndTyGetLastBattleTrivia switch VAR_RESULT @@ -293,15 +286,13 @@ GabbyAndTy_EventScript_RequestInterviewLostAMon:: end GabbyAndTy_EventScript_Interview:: - compare VAR_RESULT, NO - goto_if_eq GabbyAndTy_EventScript_DontGiveUpKeepingEyeOut + goto_if_eq VAR_RESULT, NO, GabbyAndTy_EventScript_DontGiveUpKeepingEyeOut msgbox GabbyAndTy_Text_DescribeYourFeelings, MSGBOX_DEFAULT setvar VAR_0x8004, EASY_CHAT_TYPE_GABBY_AND_TY call Common_ShowEasyChatScreen lock faceplayer - compare VAR_RESULT, 0 - goto_if_eq GabbyAndTy_EventScript_DontGiveUpKeepingEyeOut + goto_if_eq VAR_RESULT, 0, GabbyAndTy_EventScript_DontGiveUpKeepingEyeOut msgbox GabbyAndTy_Text_PerfectWellBeSeeingYou, MSGBOX_DEFAULT special GabbyAndTyAfterInterview setflag FLAG_TEMP_1 diff --git a/data/scripts/gift_altering_cave.inc b/data/scripts/gift_altering_cave.inc index 8761b5fa4..f86432ce2 100644 --- a/data/scripts/gift_altering_cave.inc +++ b/data/scripts/gift_altering_cave.inc @@ -1,8 +1,7 @@ MysteryGiftScript_AlteringCave:: setvaddress MysteryGiftScript_AlteringCave addvar VAR_ALTERING_CAVE_WILD_SET, 1 - compare VAR_ALTERING_CAVE_WILD_SET, 10 - vgoto_if_ne MysteryGiftScript_AlteringCave_ + vgoto_if_ne VAR_ALTERING_CAVE_WILD_SET, 10, MysteryGiftScript_AlteringCave_ setvar VAR_ALTERING_CAVE_WILD_SET, 0 MysteryGiftScript_AlteringCave_: lock diff --git a/data/scripts/gift_aurora_ticket.inc b/data/scripts/gift_aurora_ticket.inc index c9250b9f9..0cadf804a 100644 --- a/data/scripts/gift_aurora_ticket.inc +++ b/data/scripts/gift_aurora_ticket.inc @@ -4,15 +4,13 @@ MysteryGiftScript_AuroraTicket:: faceplayer vgoto_if_set FLAG_RECEIVED_AURORA_TICKET, AuroraTicket_Obtained vgoto_if_set FLAG_BATTLED_DEOXYS, AuroraTicket_Obtained - checkitem ITEM_AURORA_TICKET, 1 - compare VAR_RESULT, TRUE - vgoto_if_eq AuroraTicket_Obtained + checkitem ITEM_AURORA_TICKET + vgoto_if_eq VAR_RESULT, TRUE, AuroraTicket_Obtained vmessage sText_AuroraTicketForYou waitmessage waitbuttonpress - checkitemspace ITEM_AURORA_TICKET, 1 - compare VAR_RESULT, FALSE - vgoto_if_eq AuroraTicket_NoBagSpace + checkitemspace ITEM_AURORA_TICKET + vgoto_if_eq VAR_RESULT, FALSE, AuroraTicket_NoBagSpace giveitem ITEM_AURORA_TICKET setflag FLAG_ENABLE_SHIP_BIRTH_ISLAND setflag FLAG_RECEIVED_AURORA_TICKET diff --git a/data/scripts/gift_battle_card.inc b/data/scripts/gift_battle_card.inc index 80b4ba26e..95e55e1b9 100644 --- a/data/scripts/gift_battle_card.inc +++ b/data/scripts/gift_battle_card.inc @@ -3,8 +3,7 @@ MysteryGiftScript_BattleCard:: vgoto_if_set FLAG_MYSTERY_GIFT_DONE, MysteryGiftScript_BattleCardInfo setorcopyvar VAR_RESULT, GET_CARD_BATTLES_WON specialvar VAR_0x8008, GetMysteryGiftCardStat - compare VAR_0x8008, REQUIRED_CARD_BATTLES - vgoto_if_ne MysteryGiftScript_BattleCardInfo + vgoto_if_ne VAR_0x8008, REQUIRED_CARD_BATTLES, MysteryGiftScript_BattleCardInfo lock faceplayer vmessage sText_MysteryGiftBattleCountCard_WonPrize diff --git a/data/scripts/gift_mystic_ticket.inc b/data/scripts/gift_mystic_ticket.inc index 29c325f72..3ed8aa6bc 100644 --- a/data/scripts/gift_mystic_ticket.inc +++ b/data/scripts/gift_mystic_ticket.inc @@ -5,15 +5,13 @@ MysteryGiftScript_MysticTicket:: vgoto_if_set FLAG_RECEIVED_MYSTIC_TICKET, MysticTicket_Obtained vgoto_if_set FLAG_CAUGHT_LUGIA, MysticTicket_Obtained vgoto_if_set FLAG_CAUGHT_HO_OH, MysticTicket_Obtained - checkitem ITEM_MYSTIC_TICKET, 1 - compare VAR_RESULT, TRUE - vgoto_if_eq MysticTicket_Obtained + checkitem ITEM_MYSTIC_TICKET + vgoto_if_eq VAR_RESULT, TRUE, MysticTicket_Obtained vmessage sText_MysticTicketForYou waitmessage waitbuttonpress - checkitemspace ITEM_MYSTIC_TICKET, 1 - compare VAR_RESULT, FALSE - vgoto_if_eq MysticTicket_NoBagSpace + checkitemspace ITEM_MYSTIC_TICKET + vgoto_if_eq VAR_RESULT, FALSE, MysticTicket_NoBagSpace giveitem ITEM_MYSTIC_TICKET setflag FLAG_ENABLE_SHIP_NAVEL_ROCK setflag FLAG_RECEIVED_MYSTIC_TICKET diff --git a/data/scripts/gift_old_sea_map.inc b/data/scripts/gift_old_sea_map.inc index 5e47a10df..06435492e 100644 --- a/data/scripts/gift_old_sea_map.inc +++ b/data/scripts/gift_old_sea_map.inc @@ -4,15 +4,13 @@ MysteryGiftScript_OldSeaMap:: faceplayer vgoto_if_set FLAG_RECEIVED_OLD_SEA_MAP, OldSeaMap_Obtained vgoto_if_set FLAG_CAUGHT_MEW, OldSeaMap_Obtained - checkitem ITEM_OLD_SEA_MAP, 1 - compare VAR_RESULT, TRUE - vgoto_if_eq OldSeaMap_Obtained + checkitem ITEM_OLD_SEA_MAP + vgoto_if_eq VAR_RESULT, TRUE, OldSeaMap_Obtained vmessage sText_MysteryGiftOldSeaMapForYou waitmessage waitbuttonpress - checkitemspace ITEM_OLD_SEA_MAP, 1 - compare VAR_RESULT, FALSE - vgoto_if_eq OldSeaMap_NoBagSpace + checkitemspace ITEM_OLD_SEA_MAP + vgoto_if_eq VAR_RESULT, FALSE, OldSeaMap_NoBagSpace giveitem ITEM_OLD_SEA_MAP setflag FLAG_ENABLE_SHIP_FARAWAY_ISLAND setflag FLAG_RECEIVED_OLD_SEA_MAP diff --git a/data/scripts/gift_pichu.inc b/data/scripts/gift_pichu.inc index e62fc4536..d2cd381b5 100644 --- a/data/scripts/gift_pichu.inc +++ b/data/scripts/gift_pichu.inc @@ -5,8 +5,7 @@ MysteryGiftScript_SurfPichu:: SurfPichu_GiveIfPossible: specialvar VAR_GIFT_PICHU_SLOT, CalculatePlayerPartyCount - compare VAR_GIFT_PICHU_SLOT, PARTY_SIZE - vgoto_if_eq SurfPichu_FullParty + vgoto_if_eq VAR_GIFT_PICHU_SLOT, PARTY_SIZE, SurfPichu_FullParty setflag FLAG_MYSTERY_GIFT_DONE vcall SurfPichu_GiveEgg lock @@ -32,16 +31,11 @@ SurfPichu_GiveEgg: giveegg SPECIES_PICHU setmoneventlegal VAR_GIFT_PICHU_SLOT setmonmetlocation VAR_GIFT_PICHU_SLOT, METLOC_FATEFUL_ENCOUNTER - compare VAR_GIFT_PICHU_SLOT, 1 - vgoto_if_eq SurfPichu_Slot1 - compare VAR_GIFT_PICHU_SLOT, 2 - vgoto_if_eq SurfPichu_Slot2 - compare VAR_GIFT_PICHU_SLOT, 3 - vgoto_if_eq SurfPichu_Slot3 - compare VAR_GIFT_PICHU_SLOT, 4 - vgoto_if_eq SurfPichu_Slot4 - compare VAR_GIFT_PICHU_SLOT, 5 - vgoto_if_eq SurfPichu_Slot5 + vgoto_if_eq VAR_GIFT_PICHU_SLOT, 1, SurfPichu_Slot1 + vgoto_if_eq VAR_GIFT_PICHU_SLOT, 2, SurfPichu_Slot2 + vgoto_if_eq VAR_GIFT_PICHU_SLOT, 3, SurfPichu_Slot3 + vgoto_if_eq VAR_GIFT_PICHU_SLOT, 4, SurfPichu_Slot4 + vgoto_if_eq VAR_GIFT_PICHU_SLOT, 5, SurfPichu_Slot5 return SurfPichu_Slot1: diff --git a/data/scripts/gift_stamp_card.inc b/data/scripts/gift_stamp_card.inc index f6e1eb7c7..4ac399bec 100644 --- a/data/scripts/gift_stamp_card.inc +++ b/data/scripts/gift_stamp_card.inc @@ -5,7 +5,7 @@ MysteryGiftScript_StampCard:: setorcopyvar VAR_RESULT, GET_NUM_STAMPS specialvar VAR_0x8009, GetMysteryGiftCardStat subvar VAR_0x8008, VAR_0x8009 - buffernumberstring 0, VAR_0x8008 + buffernumberstring STR_VAR_1, VAR_0x8008 lock faceplayer vmessage sText_MysteryGiftStampCard diff --git a/data/scripts/gift_trainer.inc b/data/scripts/gift_trainer.inc index 2dbc86d53..b92780905 100644 --- a/data/scripts/gift_trainer.inc +++ b/data/scripts/gift_trainer.inc @@ -1,8 +1,7 @@ MysteryGiftScript_VisitingTrainer:: setvaddress MysteryGiftScript_VisitingTrainer special ValidateEReaderTrainer - compare VAR_RESULT, 0 - vgoto_if_eq MysteryGiftScript_VisitingTrainerArrived + vgoto_if_eq VAR_RESULT, 0, MysteryGiftScript_VisitingTrainerArrived lock faceplayer vmessage sText_MysteryGiftVisitingTrainerInstructions diff --git a/data/scripts/hall_of_fame.inc b/data/scripts/hall_of_fame.inc index 9b730de31..fc082870f 100644 --- a/data/scripts/hall_of_fame.inc +++ b/data/scripts/hall_of_fame.inc @@ -2,8 +2,7 @@ EverGrandeCity_HallOfFame_EventScript_SetGameClearFlags:: special SetChampionSaveWarp setflag FLAG_IS_CHAMPION call EverGrandeCity_HallOfFame_EventScript_ResetDefeatedEventLegendaries - compare VAR_FOSSIL_MANIAC_STATE, 0 - call_if_eq EverGrandeCity_HallOfFame_EventScript_SetDesertUnderpassCommentReady + call_if_eq VAR_FOSSIL_MANIAC_STATE, 0, EverGrandeCity_HallOfFame_EventScript_SetDesertUnderpassCommentReady clearflag FLAG_HIDE_LILYCOVE_MOTEL_GAME_DESIGNERS call EverGrandeCity_HallOfFame_EventScript_ResetEliteFour setflag FLAG_HIDE_SLATEPORT_CITY_STERNS_SHIPYARD_MR_BRINEY @@ -22,8 +21,7 @@ EverGrandeCity_HallOfFame_EventScript_SetGameClearFlags:: call_if_unset FLAG_RECEIVED_BELDUM, EverGrandeCity_HallOfFame_EventScript_ShowStevensHouseBeldum setflag FLAG_HIDE_LITTLEROOT_TOWN_BRENDANS_HOUSE_RIVAL_BEDROOM setflag FLAG_HIDE_LITTLEROOT_TOWN_MAYS_HOUSE_RIVAL_BEDROOM - compare VAR_DEX_UPGRADE_JOHTO_STARTER_STATE, 0 - call_if_eq EverGrandeCity_HallOfFame_EventScript_ReadyDexUpgradeEvent + call_if_eq VAR_DEX_UPGRADE_JOHTO_STARTER_STATE, 0, EverGrandeCity_HallOfFame_EventScript_ReadyDexUpgradeEvent return EverGrandeCity_HallOfFame_EventScript_ResetDefeatedEventLegendaries:: diff --git a/data/scripts/interview.inc b/data/scripts/interview.inc index 90fceb9d1..e102bf889 100644 --- a/data/scripts/interview.inc +++ b/data/scripts/interview.inc @@ -8,14 +8,11 @@ Interview_EventScript_EndInterview:: SlateportCity_PokemonFanClub_EventScript_ReporterNoNickname:: setvar VAR_0x8005, TVSHOW_FAN_CLUB_LETTER special InterviewBefore - compare VAR_RESULT, TRUE - goto_if_eq SlateportCity_PokemonFanClub_EventScript_AlreadyInterviewed2 + goto_if_eq VAR_RESULT, TRUE, SlateportCity_PokemonFanClub_EventScript_AlreadyInterviewed2 copyvar VAR_0x8009, VAR_0x8006 msgbox SlateportCity_PokemonFanClub_Text_InterviewRequest, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq SlateportCity_PokemonFanClub_EventScript_AcceptInterview2 - compare VAR_RESULT, NO - goto_if_eq SlateportCity_PokemonFanClub_EventScript_DeclineInterview2 + goto_if_eq VAR_RESULT, YES, SlateportCity_PokemonFanClub_EventScript_AcceptInterview2 + goto_if_eq VAR_RESULT, NO, SlateportCity_PokemonFanClub_EventScript_DeclineInterview2 end SlateportCity_PokemonFanClub_EventScript_AcceptInterview2:: @@ -26,10 +23,8 @@ SlateportCity_PokemonFanClub_EventScript_AcceptInterview2:: call Common_ShowEasyChatScreen lock faceplayer - compare VAR_RESULT, 1 - goto_if_eq SlateportCity_PokemonFanClub_EventScript_SubmitResponse2 - compare VAR_RESULT, 0 - goto_if_eq SlateportCity_PokemonFanClub_EventScript_DeclineInterview2 + goto_if_eq VAR_RESULT, 1, SlateportCity_PokemonFanClub_EventScript_SubmitResponse2 + goto_if_eq VAR_RESULT, 0, SlateportCity_PokemonFanClub_EventScript_DeclineInterview2 end SlateportCity_PokemonFanClub_EventScript_DeclineInterview2:: @@ -53,24 +48,19 @@ SlateportCity_OceanicMuseum_1F_EventScript_Reporter:: faceplayer setvar VAR_0x8005, TVSHOW_RECENT_HAPPENINGS special InterviewBefore - compare VAR_RESULT, TRUE - goto_if_eq SlateportCity_OceanicMuseum_1F_EventScript_AlreadyInterviewed + goto_if_eq VAR_RESULT, TRUE, SlateportCity_OceanicMuseum_1F_EventScript_AlreadyInterviewed copyvar VAR_0x8009, VAR_0x8006 goto_if_set FLAG_OCEANIC_MUSEUM_MET_REPORTER, SlateportCity_OceanicMuseum_1F_EventScript_RequestInterviewShort setflag FLAG_OCEANIC_MUSEUM_MET_REPORTER msgbox SlateportCity_OceanicMuseum_1F_Text_InterviewRequest, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq SlateportCity_OceanicMuseum_1F_EventScript_AcceptInterview - compare VAR_RESULT, NO - goto_if_eq SlateportCity_OceanicMuseum_1F_EventScript_DeclineInterview + goto_if_eq VAR_RESULT, YES, SlateportCity_OceanicMuseum_1F_EventScript_AcceptInterview + goto_if_eq VAR_RESULT, NO, SlateportCity_OceanicMuseum_1F_EventScript_DeclineInterview end SlateportCity_OceanicMuseum_1F_EventScript_RequestInterviewShort:: msgbox SlateportCity_OceanicMuseum_1F_Text_InterviewRequestShort, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq SlateportCity_OceanicMuseum_1F_EventScript_AcceptInterview - compare VAR_RESULT, NO - goto_if_eq SlateportCity_OceanicMuseum_1F_EventScript_DeclineInterview + goto_if_eq VAR_RESULT, YES, SlateportCity_OceanicMuseum_1F_EventScript_AcceptInterview + goto_if_eq VAR_RESULT, NO, SlateportCity_OceanicMuseum_1F_EventScript_DeclineInterview end SlateportCity_OceanicMuseum_1F_EventScript_AcceptInterview:: @@ -81,10 +71,8 @@ SlateportCity_OceanicMuseum_1F_EventScript_AcceptInterview:: call Common_ShowEasyChatScreen lock faceplayer - compare VAR_RESULT, 1 - goto_if_eq SlateportCity_OceanicMuseum_1F_EventScript_SubmitResponse - compare VAR_RESULT, 0 - goto_if_eq SlateportCity_OceanicMuseum_1F_EventScript_DeclineInterview + goto_if_eq VAR_RESULT, 1, SlateportCity_OceanicMuseum_1F_EventScript_SubmitResponse + goto_if_eq VAR_RESULT, 0, SlateportCity_OceanicMuseum_1F_EventScript_DeclineInterview end SlateportCity_OceanicMuseum_1F_EventScript_DeclineInterview:: @@ -107,18 +95,14 @@ SlateportCity_PokemonFanClub_EventScript_Reporter:: lock faceplayer specialvar VAR_RESULT, IsLeadMonNicknamedOrNotEnglish - compare VAR_RESULT, FALSE - goto_if_eq SlateportCity_PokemonFanClub_EventScript_ReporterNoNickname + goto_if_eq VAR_RESULT, FALSE, SlateportCity_PokemonFanClub_EventScript_ReporterNoNickname setvar VAR_0x8005, TVSHOW_PKMN_FAN_CLUB_OPINIONS special InterviewBefore - compare VAR_RESULT, TRUE - goto_if_eq SlateportCity_PokemonFanClub_EventScript_AlreadyInterviewed + goto_if_eq VAR_RESULT, TRUE, SlateportCity_PokemonFanClub_EventScript_AlreadyInterviewed copyvar VAR_0x8009, VAR_0x8006 msgbox SlateportCity_PokemonFanClub_Text_InterviewRequestHasName, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq SlateportCity_PokemonFanClub_EventScript_AcceptInterview - compare VAR_RESULT, NO - goto_if_eq SlateportCity_PokemonFanClub_EventScript_DeclineInterview + goto_if_eq VAR_RESULT, YES, SlateportCity_PokemonFanClub_EventScript_AcceptInterview + goto_if_eq VAR_RESULT, NO, SlateportCity_PokemonFanClub_EventScript_DeclineInterview end SlateportCity_PokemonFanClub_EventScript_AcceptInterview:: @@ -153,15 +137,13 @@ SlateportCity_PokemonFanClub_EventScript_ContinueInterview:: call Common_ShowEasyChatScreen lock faceplayer - compare VAR_RESULT, 0 - goto_if_eq SlateportCity_PokemonFanClub_EventScript_DeclineInterview + goto_if_eq VAR_RESULT, 0, SlateportCity_PokemonFanClub_EventScript_DeclineInterview msgbox SlateportCity_PokemonFanClub_Text_WhatDoPokemonMeanToYou, MSGBOX_DEFAULT setvar VAR_0x8006, 1 call Common_ShowEasyChatScreen lock faceplayer - compare VAR_RESULT, 0 - goto_if_eq SlateportCity_PokemonFanClub_EventScript_DeclineInterview + goto_if_eq VAR_RESULT, 0, SlateportCity_PokemonFanClub_EventScript_DeclineInterview msgbox SlateportCity_PokemonFanClub_Text_ThatsAllForInterview, MSGBOX_DEFAULT copyvar VAR_0x8007, VAR_0x800A setvar VAR_0x8005, TVSHOW_PKMN_FAN_CLUB_OPINIONS @@ -184,14 +166,11 @@ LilycoveCity_ContestLobby_EventScript_Reporter:: goto_if_set FLAG_TEMP_2, LilycoveCity_ContestLobby_EventScript_AlreadyInterviewed setvar VAR_0x8005, TVSHOW_BRAVO_TRAINER_POKEMON_PROFILE special InterviewBefore - compare VAR_RESULT, TRUE - goto_if_eq LilycoveCity_ContestLobby_EventScript_AlreadyInterviewed + goto_if_eq VAR_RESULT, TRUE, LilycoveCity_ContestLobby_EventScript_AlreadyInterviewed copyvar VAR_0x8009, VAR_0x8006 msgbox LilycoveCity_ContestLobby_Text_InterviewRequest, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq LilycoveCity_ContestLobby_EventScript_AcceptInterview - compare VAR_RESULT, NO - goto_if_eq LilycoveCity_ContestLobby_EventScript_DeclineInterview + goto_if_eq VAR_RESULT, YES, LilycoveCity_ContestLobby_EventScript_AcceptInterview + goto_if_eq VAR_RESULT, NO, LilycoveCity_ContestLobby_EventScript_DeclineInterview end LilycoveCity_ContestLobby_EventScript_AcceptInterview:: @@ -202,10 +181,8 @@ LilycoveCity_ContestLobby_EventScript_AcceptInterview:: call Common_ShowEasyChatScreen lock faceplayer - compare VAR_RESULT, 1 - goto_if_eq LilycoveCity_ContestLobby_EventScript_SubmitResponse - compare VAR_RESULT, 0 - goto_if_eq LilycoveCity_ContestLobby_EventScript_DeclineInterview + goto_if_eq VAR_RESULT, 1, LilycoveCity_ContestLobby_EventScript_SubmitResponse + goto_if_eq VAR_RESULT, 0, LilycoveCity_ContestLobby_EventScript_DeclineInterview end LilycoveCity_ContestLobby_EventScript_DeclineInterview:: @@ -223,8 +200,7 @@ LilycoveCity_ContestLobby_EventScript_SubmitResponse:: call Common_ShowEasyChatScreen lock faceplayer - compare VAR_RESULT, 0 - goto_if_eq LilycoveCity_ContestLobby_EventScript_DeclineInterview + goto_if_eq VAR_RESULT, 0, LilycoveCity_ContestLobby_EventScript_DeclineInterview msgbox LilycoveCity_ContestLobby_Text_ThatsAllForInterview, MSGBOX_DEFAULT setflag FLAG_TEMP_2 setvar VAR_0x8005, TVSHOW_BRAVO_TRAINER_POKEMON_PROFILE @@ -237,12 +213,10 @@ LilycoveCity_ContestLobby_EventScript_AlreadyInterviewed:: end LilycoveCity_ContestLobby_EventScript_TryShowContestReporter:: - compare VAR_CONTEST_HALL_STATE, 2 - goto_if_ne LilycoveCity_ContestLobby_EventScript_DontShowContestReporter + goto_if_ne VAR_CONTEST_HALL_STATE, 2, LilycoveCity_ContestLobby_EventScript_DontShowContestReporter setvar VAR_0x8005, TVSHOW_BRAVO_TRAINER_POKEMON_PROFILE special InterviewBefore - compare VAR_RESULT, TRUE - goto_if_eq LilycoveCity_ContestLobby_EventScript_DontShowContestReporter + goto_if_eq VAR_RESULT, TRUE, LilycoveCity_ContestLobby_EventScript_DontShowContestReporter switch VAR_CONTEST_TYPE case 0, LilycoveCity_ContestLobby_EventScript_DontShowContestReporter case 2, LilycoveCity_ContestLobby_EventScript_ShowContestReporter @@ -265,14 +239,11 @@ BattleFrontier_BattleTowerLobby_EventScript_Reporter:: goto_if_set FLAG_TEMP_2, BattleFrontier_BattleTowerLobby_EventScript_AlreadyInterviewed setvar VAR_0x8005, TVSHOW_BRAVO_TRAINER_BATTLE_TOWER_PROFILE special InterviewBefore - compare VAR_RESULT, TRUE - goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_AlreadyInterviewed + goto_if_eq VAR_RESULT, TRUE, BattleFrontier_BattleTowerLobby_EventScript_AlreadyInterviewed copyvar VAR_0x8009, VAR_0x8006 msgbox BattleFrontier_BattleTowerLobby_Text_InterviewRequest, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_AcceptInterview - compare VAR_RESULT, NO - goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_DeclineInterview + goto_if_eq VAR_RESULT, YES, BattleFrontier_BattleTowerLobby_EventScript_AcceptInterview + goto_if_eq VAR_RESULT, NO, BattleFrontier_BattleTowerLobby_EventScript_DeclineInterview end BattleFrontier_BattleTowerLobby_EventScript_AcceptInterview:: @@ -280,20 +251,16 @@ BattleFrontier_BattleTowerLobby_EventScript_AcceptInterview:: waitmessage multichoice 20, 8, MULTI_SATISFACTION, TRUE copyvar VAR_0x8008, VAR_RESULT - compare VAR_RESULT, 0 - call_if_eq BattleFrontier_BattleTowerLobby_EventScript_Satisfied - compare VAR_RESULT, 1 - call_if_eq BattleFrontier_BattleTowerLobby_EventScript_Dissatisfied + call_if_eq VAR_RESULT, 0, BattleFrontier_BattleTowerLobby_EventScript_Satisfied + call_if_eq VAR_RESULT, 1, BattleFrontier_BattleTowerLobby_EventScript_Dissatisfied msgbox BattleFrontier_BattleTowerLobby_Text_DescribeYourBattle, MSGBOX_DEFAULT setvar VAR_0x8004, EASY_CHAT_TYPE_BATTLE_TOWER_INTERVIEW copyvar VAR_0x8005, VAR_0x8009 call Common_ShowEasyChatScreen lock faceplayer - compare VAR_RESULT, 1 - goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_SubmitResponse - compare VAR_RESULT, 0 - goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_CancelInterview + goto_if_eq VAR_RESULT, 1, BattleFrontier_BattleTowerLobby_EventScript_SubmitResponse + goto_if_eq VAR_RESULT, 0, BattleFrontier_BattleTowerLobby_EventScript_CancelInterview end BattleFrontier_BattleTowerLobby_EventScript_DeclineInterview:: @@ -310,8 +277,7 @@ BattleFrontier_BattleTowerLobby_EventScript_Dissatisfied:: return BattleFrontier_BattleTowerLobby_EventScript_SubmitResponse:: - compare VAR_RESULT, 0 - goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_CancelInterview + goto_if_eq VAR_RESULT, 0, BattleFrontier_BattleTowerLobby_EventScript_CancelInterview msgbox BattleFrontier_BattleTowerLobby_Text_ThatsGreatLine, MSGBOX_DEFAULT setflag FLAG_TEMP_2 copyvar VAR_0x8004, VAR_0x8008 @@ -330,12 +296,10 @@ BattleFrontier_BattleTowerLobby_EventScript_AlreadyInterviewed:: end BattleFrontier_BattleTowerLobby_EventScript_ShowOrHideReporter:: - compare VAR_BRAVO_TRAINER_BATTLE_TOWER_ON, 0 - goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_HideReporter + goto_if_eq VAR_BRAVO_TRAINER_BATTLE_TOWER_ON, 0, BattleFrontier_BattleTowerLobby_EventScript_HideReporter setvar VAR_0x8005, TVSHOW_BRAVO_TRAINER_BATTLE_TOWER_PROFILE special InterviewBefore - compare VAR_RESULT, TRUE - goto_if_eq BattleFrontier_BattleTowerLobby_EventScript_HideReporter + goto_if_eq VAR_RESULT, TRUE, BattleFrontier_BattleTowerLobby_EventScript_HideReporter clearflag FLAG_HIDE_BATTLE_TOWER_REPORTER return @@ -347,8 +311,7 @@ BattleFrontier_BattleTowerLobby_EventScript_HideReporter:: EventScript_ContestLiveInterview:: setvar VAR_0x8005, TVSHOW_CONTEST_LIVE_UPDATES special InterviewBefore - compare VAR_RESULT, TRUE - goto_if_eq EventScript_ContestLiveInterviewEnd + goto_if_eq VAR_RESULT, TRUE, EventScript_ContestLiveInterviewEnd setvar VAR_0x8005, TVSHOW_CONTEST_LIVE_UPDATES special InterviewAfter return diff --git a/data/scripts/kecleon.inc b/data/scripts/kecleon.inc index 82eca777d..f51dc2fbd 100644 --- a/data/scripts/kecleon.inc +++ b/data/scripts/kecleon.inc @@ -48,17 +48,15 @@ Route119_EventScript_Kecleon2:: end EventScript_Kecleon:: - checkitem ITEM_DEVON_SCOPE, 1 - compare VAR_RESULT, 1 - goto_if_eq EventScript_AskUseDevonScope + checkitem ITEM_DEVON_SCOPE + goto_if_eq VAR_RESULT, TRUE, EventScript_AskUseDevonScope msgbox Kecleon_Text_SomethingUnseeable, MSGBOX_DEFAULT release end EventScript_AskUseDevonScope:: msgbox Kecleon_Text_WantToUseDevonScope, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq EventScript_BattleKecleon + goto_if_eq VAR_RESULT, YES, EventScript_BattleKecleon release end @@ -78,12 +76,9 @@ EventScript_BattleKecleon:: dowildbattle clearflag FLAG_SYS_CTRL_OBJ_DELETE specialvar VAR_RESULT, GetBattleOutcome - compare VAR_RESULT, B_OUTCOME_WON - goto_if_eq EventScript_RemoveKecleon - compare VAR_RESULT, B_OUTCOME_RAN - goto_if_eq EventScript_RemoveKecleon - compare VAR_RESULT, B_OUTCOME_PLAYER_TELEPORTED - goto_if_eq EventScript_RemoveKecleon + goto_if_eq VAR_RESULT, B_OUTCOME_WON, EventScript_RemoveKecleon + goto_if_eq VAR_RESULT, B_OUTCOME_RAN, EventScript_RemoveKecleon + goto_if_eq VAR_RESULT, B_OUTCOME_PLAYER_TELEPORTED, EventScript_RemoveKecleon release end diff --git a/data/scripts/lilycove_lady.inc b/data/scripts/lilycove_lady.inc index 576fa28ad..5519de979 100644 --- a/data/scripts/lilycove_lady.inc +++ b/data/scripts/lilycove_lady.inc @@ -2,858 +2,789 @@ .set LOCALID_LADYS_MON, 5 LilycoveCity_PokemonCenter_1F_EventScript_LilycoveLady:: - special Script_GetLilycoveLadyId - switch VAR_RESULT - case LILYCOVE_LADY_QUIZ, LilycoveCity_PokemonCenter_1F_EventScript_QuizLady - case LILYCOVE_LADY_FAVOR, LilycoveCity_PokemonCenter_1F_EventScript_FavorLady - case LILYCOVE_LADY_CONTEST, LilycoveCity_PokemonCenter_1F_EventScript_ContestLady - end + special Script_GetLilycoveLadyId + switch VAR_RESULT + case LILYCOVE_LADY_QUIZ, LilycoveCity_PokemonCenter_1F_EventScript_QuizLady + case LILYCOVE_LADY_FAVOR, LilycoveCity_PokemonCenter_1F_EventScript_FavorLady + case LILYCOVE_LADY_CONTEST, LilycoveCity_PokemonCenter_1F_EventScript_ContestLady + end LilycoveCity_PokemonCenter_1F_EventScript_FavorLady:: - lock - faceplayer - msgbox LilycoveCity_PokemonCenter_1F_Text_ImTheFavorLady, MSGBOX_DEFAULT - specialvar VAR_RESULT, GetFavorLadyState - compare VAR_RESULT, LILYCOVE_LADY_STATE_READY - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_FavorLadyReady - compare VAR_RESULT, LILYCOVE_LADY_STATE_COMPLETED - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_FavorLadyCompleted - compare VAR_RESULT, LILYCOVE_LADY_STATE_PRIZE - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_FavorLadyPrize - end + lock + faceplayer + msgbox LilycoveCity_PokemonCenter_1F_Text_ImTheFavorLady, MSGBOX_DEFAULT + specialvar VAR_RESULT, GetFavorLadyState + goto_if_eq VAR_RESULT, LILYCOVE_LADY_STATE_READY, LilycoveCity_PokemonCenter_1F_EventScript_FavorLadyReady + goto_if_eq VAR_RESULT, LILYCOVE_LADY_STATE_COMPLETED, LilycoveCity_PokemonCenter_1F_EventScript_FavorLadyCompleted + goto_if_eq VAR_RESULT, LILYCOVE_LADY_STATE_PRIZE, LilycoveCity_PokemonCenter_1F_EventScript_FavorLadyPrize + end LilycoveCity_PokemonCenter_1F_EventScript_FavorLadyCompleted:: - msgbox LilycoveCity_PokemonCenter_1F_Text_ThankYouForLastTime, MSGBOX_DEFAULT - release - end + msgbox LilycoveCity_PokemonCenter_1F_Text_ThankYouForLastTime, MSGBOX_DEFAULT + release + end LilycoveCity_PokemonCenter_1F_EventScript_FavorLadyReady:: - special BufferFavorLadyRequest - msgbox LilycoveCity_PokemonCenter_1F_Text_ObsessedWithThing, MSGBOX_DEFAULT - specialvar VAR_RESULT, HasAnotherPlayerGivenFavorLadyItem - compare VAR_RESULT, FALSE - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_RequestItem - compare VAR_RESULT, TRUE - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_TellAboutPlayersItem - end + special BufferFavorLadyRequest + msgbox LilycoveCity_PokemonCenter_1F_Text_ObsessedWithThing, MSGBOX_DEFAULT + specialvar VAR_RESULT, HasAnotherPlayerGivenFavorLadyItem + goto_if_eq VAR_RESULT, FALSE, LilycoveCity_PokemonCenter_1F_EventScript_RequestItem + goto_if_eq VAR_RESULT, TRUE, LilycoveCity_PokemonCenter_1F_EventScript_TellAboutPlayersItem + end LilycoveCity_PokemonCenter_1F_EventScript_TellAboutPlayersItem:: - special BufferFavorLadyItemName - special BufferFavorLadyPlayerName - specialvar VAR_RESULT, DidFavorLadyLikeItem - compare VAR_RESULT, FALSE - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_PlayerGaveBadThing - compare VAR_RESULT, TRUE - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_PlayerGaveGreatThing - end + special BufferFavorLadyItemName + special BufferFavorLadyPlayerName + specialvar VAR_RESULT, DidFavorLadyLikeItem + goto_if_eq VAR_RESULT, FALSE, LilycoveCity_PokemonCenter_1F_EventScript_PlayerGaveBadThing + goto_if_eq VAR_RESULT, TRUE, LilycoveCity_PokemonCenter_1F_EventScript_PlayerGaveGreatThing + end LilycoveCity_PokemonCenter_1F_EventScript_PlayerGaveBadThing:: - msgbox LilycoveCity_PokemonCenter_1F_Text_PlayerGaveMeBadThing, MSGBOX_DEFAULT - goto LilycoveCity_PokemonCenter_1F_EventScript_RequestItem - end + msgbox LilycoveCity_PokemonCenter_1F_Text_PlayerGaveMeBadThing, MSGBOX_DEFAULT + goto LilycoveCity_PokemonCenter_1F_EventScript_RequestItem + end LilycoveCity_PokemonCenter_1F_EventScript_PlayerGaveGreatThing:: - msgbox LilycoveCity_PokemonCenter_1F_Text_PlayerGaveMeGreatThing, MSGBOX_DEFAULT - goto LilycoveCity_PokemonCenter_1F_EventScript_RequestItem - end + msgbox LilycoveCity_PokemonCenter_1F_Text_PlayerGaveMeGreatThing, MSGBOX_DEFAULT + goto LilycoveCity_PokemonCenter_1F_EventScript_RequestItem + end LilycoveCity_PokemonCenter_1F_EventScript_RequestItem:: - msgbox LilycoveCity_PokemonCenter_1F_Text_WillYouShareThing, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_DeclineFavor - compare VAR_RESULT, YES - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_AcceptFavor - end + msgbox LilycoveCity_PokemonCenter_1F_Text_WillYouShareThing, MSGBOX_YESNO + goto_if_eq VAR_RESULT, NO, LilycoveCity_PokemonCenter_1F_EventScript_DeclineFavor + goto_if_eq VAR_RESULT, YES, LilycoveCity_PokemonCenter_1F_EventScript_AcceptFavor + end LilycoveCity_PokemonCenter_1F_EventScript_DeclineFavor:: - msgbox LilycoveCity_PokemonCenter_1F_Text_IsThatSoGoodbye, MSGBOX_DEFAULT - release - end + msgbox LilycoveCity_PokemonCenter_1F_Text_IsThatSoGoodbye, MSGBOX_DEFAULT + release + end LilycoveCity_PokemonCenter_1F_EventScript_AcceptFavor:: - msgbox LilycoveCity_PokemonCenter_1F_Text_WhatWillYouGiveMe, MSGBOX_DEFAULT - goto LilycoveCity_PokemonCenter_1F_EventScript_ChooseFavorItem - end + msgbox LilycoveCity_PokemonCenter_1F_Text_WhatWillYouGiveMe, MSGBOX_DEFAULT + goto LilycoveCity_PokemonCenter_1F_EventScript_ChooseFavorItem + end LilycoveCity_PokemonCenter_1F_EventScript_ChooseFavorItem:: - fadescreen FADE_TO_BLACK - setvar VAR_RESULT, 0 - special Script_FavorLadyOpenBagMenu - waitstate - compare VAR_RESULT, 0 - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_AskQuitChooseFavorItem - compare VAR_RESULT, 1 - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_GiveFavorItem - end + fadescreen FADE_TO_BLACK + setvar VAR_RESULT, 0 + special Script_FavorLadyOpenBagMenu + waitstate + goto_if_eq VAR_RESULT, 0, LilycoveCity_PokemonCenter_1F_EventScript_AskQuitChooseFavorItem + goto_if_eq VAR_RESULT, 1, LilycoveCity_PokemonCenter_1F_EventScript_GiveFavorItem + end LilycoveCity_PokemonCenter_1F_EventScript_AskQuitChooseFavorItem:: - msgbox LilycoveCity_PokemonCenter_1F_Text_NotWillingToShare, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_DeclineFavor - compare VAR_RESULT, NO - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_ChooseFavorItem - end + msgbox LilycoveCity_PokemonCenter_1F_Text_NotWillingToShare, MSGBOX_YESNO + goto_if_eq VAR_RESULT, YES, LilycoveCity_PokemonCenter_1F_EventScript_DeclineFavor + goto_if_eq VAR_RESULT, NO, LilycoveCity_PokemonCenter_1F_EventScript_ChooseFavorItem + end LilycoveCity_PokemonCenter_1F_EventScript_GiveFavorItem:: - specialvar VAR_RESULT, Script_DoesFavorLadyLikeItem - compare VAR_RESULT, FALSE - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_DidntLikeFavorItem - compare VAR_RESULT, TRUE - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_CheckLovedItem - end + specialvar VAR_RESULT, Script_DoesFavorLadyLikeItem + goto_if_eq VAR_RESULT, FALSE, LilycoveCity_PokemonCenter_1F_EventScript_DidntLikeFavorItem + goto_if_eq VAR_RESULT, TRUE, LilycoveCity_PokemonCenter_1F_EventScript_CheckLovedItem + end LilycoveCity_PokemonCenter_1F_EventScript_DidntLikeFavorItem:: - special BufferFavorLadyRequest - msgbox LilycoveCity_PokemonCenter_1F_Text_IllTryToCherishIt, MSGBOX_DEFAULT - release - end + special BufferFavorLadyRequest + msgbox LilycoveCity_PokemonCenter_1F_Text_IllTryToCherishIt, MSGBOX_DEFAULT + release + end LilycoveCity_PokemonCenter_1F_EventScript_CheckLovedItem:: - specialvar VAR_RESULT, IsFavorLadyThresholdMet - compare VAR_RESULT, FALSE - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_LikedFavorItem - compare VAR_RESULT, TRUE - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_LovedFavorItem - end + specialvar VAR_RESULT, IsFavorLadyThresholdMet + goto_if_eq VAR_RESULT, FALSE, LilycoveCity_PokemonCenter_1F_EventScript_LikedFavorItem + goto_if_eq VAR_RESULT, TRUE, LilycoveCity_PokemonCenter_1F_EventScript_LovedFavorItem + end LilycoveCity_PokemonCenter_1F_EventScript_LikedFavorItem:: - special BufferFavorLadyRequest - msgbox LilycoveCity_PokemonCenter_1F_Text_IWillCherishThis, MSGBOX_DEFAULT - release - end + special BufferFavorLadyRequest + msgbox LilycoveCity_PokemonCenter_1F_Text_IWillCherishThis, MSGBOX_DEFAULT + release + end LilycoveCity_PokemonCenter_1F_EventScript_LovedFavorItem:: - special BufferFavorLadyRequest - msgbox LilycoveCity_PokemonCenter_1F_Text_IWillTreasureThis, MSGBOX_DEFAULT - goto LilycoveCity_PokemonCenter_1F_EventScript_FavorLadyPrize - end + special BufferFavorLadyRequest + msgbox LilycoveCity_PokemonCenter_1F_Text_IWillTreasureThis, MSGBOX_DEFAULT + goto LilycoveCity_PokemonCenter_1F_EventScript_FavorLadyPrize + end LilycoveCity_PokemonCenter_1F_EventScript_FavorLadyPrize:: - setvar VAR_0x8004, 0 - specialvar VAR_0x8004, FavorLadyGetPrize - msgbox LilycoveCity_PokemonCenter_1F_Text_IllGiveYouThisInReturn, MSGBOX_DEFAULT - giveitem VAR_0x8004 - compare VAR_RESULT, 0 - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_NoRoomForFavorPrize - compare VAR_RESULT, 1 - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_ReceivedFavorPrize - end + setvar VAR_0x8004, 0 + specialvar VAR_0x8004, FavorLadyGetPrize + msgbox LilycoveCity_PokemonCenter_1F_Text_IllGiveYouThisInReturn, MSGBOX_DEFAULT + giveitem VAR_0x8004 + goto_if_eq VAR_RESULT, 0, LilycoveCity_PokemonCenter_1F_EventScript_NoRoomForFavorPrize + goto_if_eq VAR_RESULT, 1, LilycoveCity_PokemonCenter_1F_EventScript_ReceivedFavorPrize + end LilycoveCity_PokemonCenter_1F_EventScript_NoRoomForFavorPrize:: - msgbox LilycoveCity_PokemonCenter_1F_Text_YouDontHaveSpaceForIt, MSGBOX_DEFAULT - release - end + msgbox LilycoveCity_PokemonCenter_1F_Text_YouDontHaveSpaceForIt, MSGBOX_DEFAULT + release + end LilycoveCity_PokemonCenter_1F_EventScript_ReceivedFavorPrize:: - special SetFavorLadyState_Complete - release - end + special SetFavorLadyState_Complete + release + end LilycoveCity_PokemonCenter_1F_EventScript_QuizLady:: - lock - faceplayer - msgbox LilycoveCity_PokemonCenter_1F_Text_ImTheQuizLady, MSGBOX_DEFAULT - specialvar VAR_RESULT, GetQuizLadyState - compare VAR_RESULT, LILYCOVE_LADY_STATE_READY - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_HasQuiz - compare VAR_RESULT, LILYCOVE_LADY_STATE_COMPLETED - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_CheckMadeQuiz - compare VAR_RESULT, LILYCOVE_LADY_STATE_PRIZE - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_ReadyGivePrize - end + lock + faceplayer + msgbox LilycoveCity_PokemonCenter_1F_Text_ImTheQuizLady, MSGBOX_DEFAULT + specialvar VAR_RESULT, GetQuizLadyState + goto_if_eq VAR_RESULT, LILYCOVE_LADY_STATE_READY, LilycoveCity_PokemonCenter_1F_EventScript_HasQuiz + goto_if_eq VAR_RESULT, LILYCOVE_LADY_STATE_COMPLETED, LilycoveCity_PokemonCenter_1F_EventScript_CheckMadeQuiz + goto_if_eq VAR_RESULT, LILYCOVE_LADY_STATE_PRIZE, LilycoveCity_PokemonCenter_1F_EventScript_ReadyGivePrize + end LilycoveCity_PokemonCenter_1F_EventScript_HasQuiz:: - specialvar VAR_RESULT, GetQuizAuthor - compare VAR_RESULT, QUIZ_AUTHOR_PLAYER - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_WaitingToTakeYourQuiz - compare VAR_RESULT, QUIZ_AUTHOR_OTHER_PLAYER - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_PlayerQuizReady - compare VAR_RESULT, QUIZ_AUTHOR_LADY - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_LadyQuizReady - end + specialvar VAR_RESULT, GetQuizAuthor + goto_if_eq VAR_RESULT, QUIZ_AUTHOR_PLAYER, LilycoveCity_PokemonCenter_1F_EventScript_WaitingToTakeYourQuiz + goto_if_eq VAR_RESULT, QUIZ_AUTHOR_OTHER_PLAYER, LilycoveCity_PokemonCenter_1F_EventScript_PlayerQuizReady + goto_if_eq VAR_RESULT, QUIZ_AUTHOR_LADY, LilycoveCity_PokemonCenter_1F_EventScript_LadyQuizReady + end LilycoveCity_PokemonCenter_1F_EventScript_CheckMadeQuiz:: - specialvar VAR_RESULT, IsQuizLadyWaitingForChallenger - compare VAR_RESULT, FALSE - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_AskMakeQuiz - compare VAR_RESULT, TRUE - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_WaitingToTakeYourQuiz - end + specialvar VAR_RESULT, IsQuizLadyWaitingForChallenger + goto_if_eq VAR_RESULT, FALSE, LilycoveCity_PokemonCenter_1F_EventScript_AskMakeQuiz + goto_if_eq VAR_RESULT, TRUE, LilycoveCity_PokemonCenter_1F_EventScript_WaitingToTakeYourQuiz + end LilycoveCity_PokemonCenter_1F_EventScript_WaitingToTakeYourQuiz:: - msgbox LilycoveCity_PokemonCenter_1F_Text_WaitingToTakeYourQuiz, MSGBOX_DEFAULT - release - end + msgbox LilycoveCity_PokemonCenter_1F_Text_WaitingToTakeYourQuiz, MSGBOX_DEFAULT + release + end LilycoveCity_PokemonCenter_1F_EventScript_PlayerQuizReady:: - msgbox LilycoveCity_PokemonCenter_1F_Text_WaitingForChallenger, MSGBOX_DEFAULT - goto LilycoveCity_PokemonCenter_1F_EventScript_AskTakeQuiz - end + msgbox LilycoveCity_PokemonCenter_1F_Text_WaitingForChallenger, MSGBOX_DEFAULT + goto LilycoveCity_PokemonCenter_1F_EventScript_AskTakeQuiz + end LilycoveCity_PokemonCenter_1F_EventScript_LadyQuizReady:: - msgbox LilycoveCity_PokemonCenter_1F_Text_WaitingForChallenger, MSGBOX_DEFAULT - goto LilycoveCity_PokemonCenter_1F_EventScript_AskTakeQuiz - end + msgbox LilycoveCity_PokemonCenter_1F_Text_WaitingForChallenger, MSGBOX_DEFAULT + goto LilycoveCity_PokemonCenter_1F_EventScript_AskTakeQuiz + end LilycoveCity_PokemonCenter_1F_EventScript_AskTakeQuiz:: - setvar VAR_0x8004, 0 - msgbox LilycoveCity_PokemonCenter_1F_Text_TakeQuizChallenge, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_TakeQuiz - compare VAR_RESULT, NO - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_DeclineQuiz - end + setvar VAR_0x8004, 0 + msgbox LilycoveCity_PokemonCenter_1F_Text_TakeQuizChallenge, MSGBOX_YESNO + goto_if_eq VAR_RESULT, YES, LilycoveCity_PokemonCenter_1F_EventScript_TakeQuiz + goto_if_eq VAR_RESULT, NO, LilycoveCity_PokemonCenter_1F_EventScript_DeclineQuiz + end LilycoveCity_PokemonCenter_1F_EventScript_DeclineQuiz:: - msgbox LilycoveCity_PokemonCenter_1F_Text_HowBoringBye, MSGBOX_DEFAULT - release - end + msgbox LilycoveCity_PokemonCenter_1F_Text_HowBoringBye, MSGBOX_DEFAULT + release + end LilycoveCity_PokemonCenter_1F_EventScript_TakeQuiz:: - special ClearQuizLadyPlayerAnswer - compare VAR_0x8004, 0 - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_ShowQuestion - compare VAR_0x8004, EASY_CHAT_TYPE_QUIZ_ANSWER - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_GetAnswer + special ClearQuizLadyPlayerAnswer + goto_if_eq VAR_0x8004, 0, LilycoveCity_PokemonCenter_1F_EventScript_ShowQuestion + goto_if_eq VAR_0x8004, EASY_CHAT_TYPE_QUIZ_ANSWER, LilycoveCity_PokemonCenter_1F_EventScript_GetAnswer LilycoveCity_PokemonCenter_1F_EventScript_CheckQuizTakingState:: - compare VAR_RESULT, 0 - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_AskQuitQuiz - compare VAR_RESULT, 1 - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_SubmitQuizResponse - end + goto_if_eq VAR_RESULT, 0, LilycoveCity_PokemonCenter_1F_EventScript_AskQuitQuiz + goto_if_eq VAR_RESULT, 1, LilycoveCity_PokemonCenter_1F_EventScript_SubmitQuizResponse + end LilycoveCity_PokemonCenter_1F_EventScript_ShowQuestion:: - special QuizLadyShowQuizQuestion - waitstate - goto LilycoveCity_PokemonCenter_1F_EventScript_CheckQuizTakingState - end + special QuizLadyShowQuizQuestion + waitstate + goto LilycoveCity_PokemonCenter_1F_EventScript_CheckQuizTakingState + end LilycoveCity_PokemonCenter_1F_EventScript_GetAnswer:: - special QuizLadyGetPlayerAnswer - waitstate - goto LilycoveCity_PokemonCenter_1F_EventScript_CheckQuizTakingState - end + special QuizLadyGetPlayerAnswer + waitstate + goto LilycoveCity_PokemonCenter_1F_EventScript_CheckQuizTakingState + end LilycoveCity_PokemonCenter_1F_EventScript_AskQuitQuiz:: - msgbox LilycoveCity_PokemonCenter_1F_Text_YoureGoingToQuit, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_QuitTakingQuiz - compare VAR_RESULT, NO - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_TakeQuiz - end + msgbox LilycoveCity_PokemonCenter_1F_Text_YoureGoingToQuit, MSGBOX_YESNO + goto_if_eq VAR_RESULT, YES, LilycoveCity_PokemonCenter_1F_EventScript_QuitTakingQuiz + goto_if_eq VAR_RESULT, NO, LilycoveCity_PokemonCenter_1F_EventScript_TakeQuiz + end LilycoveCity_PokemonCenter_1F_EventScript_QuitTakingQuiz:: - msgbox LilycoveCity_PokemonCenter_1F_Text_TakeTheQuizAnotherTime, MSGBOX_DEFAULT - release - end + msgbox LilycoveCity_PokemonCenter_1F_Text_TakeTheQuizAnotherTime, MSGBOX_DEFAULT + release + end LilycoveCity_PokemonCenter_1F_EventScript_SubmitQuizResponse:: - special SetQuizLadyState_Complete - msgbox LilycoveCity_PokemonCenter_1F_Text_WaitForAnswer, MSGBOX_DEFAULT - specialvar VAR_RESULT, IsQuizAnswerCorrect - compare VAR_RESULT, FALSE - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_IncorrectResponse - compare VAR_RESULT, TRUE - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_CorrectResponse - end + special SetQuizLadyState_Complete + msgbox LilycoveCity_PokemonCenter_1F_Text_WaitForAnswer, MSGBOX_DEFAULT + specialvar VAR_RESULT, IsQuizAnswerCorrect + goto_if_eq VAR_RESULT, FALSE, LilycoveCity_PokemonCenter_1F_EventScript_IncorrectResponse + goto_if_eq VAR_RESULT, TRUE, LilycoveCity_PokemonCenter_1F_EventScript_CorrectResponse + end LilycoveCity_PokemonCenter_1F_EventScript_CorrectResponse:: - playse SE_SUCCESS - delay 10 - playse SE_SUCCESS - msgbox LilycoveCity_PokemonCenter_1F_Text_YouGotItRight, MSGBOX_DEFAULT - goto LilycoveCity_PokemonCenter_1F_EventScript_ReadyGivePrize - end + playse SE_SUCCESS + delay 10 + playse SE_SUCCESS + msgbox LilycoveCity_PokemonCenter_1F_Text_YouGotItRight, MSGBOX_DEFAULT + goto LilycoveCity_PokemonCenter_1F_EventScript_ReadyGivePrize + end LilycoveCity_PokemonCenter_1F_EventScript_IncorrectResponse:: - special BufferQuizCorrectAnswer - special BufferQuizPrizeName - playse SE_FAILURE - delay 10 - playse SE_FAILURE - msgbox LilycoveCity_PokemonCenter_1F_Text_WrongTheCorrectAnswerIs, MSGBOX_DEFAULT - msgbox LilycoveCity_PokemonCenter_1F_Text_IGetToKeepPrize, MSGBOX_DEFAULT - goto LilycoveCity_PokemonCenter_1F_EventScript_AskMakeQuiz - end + special BufferQuizCorrectAnswer + special BufferQuizPrizeName + playse SE_FAILURE + delay 10 + playse SE_FAILURE + msgbox LilycoveCity_PokemonCenter_1F_Text_WrongTheCorrectAnswerIs, MSGBOX_DEFAULT + msgbox LilycoveCity_PokemonCenter_1F_Text_IGetToKeepPrize, MSGBOX_DEFAULT + goto LilycoveCity_PokemonCenter_1F_EventScript_AskMakeQuiz + end @ VAR_RESULT is essentially ignored, both jumps are identical LilycoveCity_PokemonCenter_1F_EventScript_ReadyGivePrize:: - specialvar VAR_RESULT, BufferQuizAuthorNameAndCheckIfLady - compare VAR_RESULT, 1 - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_GivePrize1 - compare VAR_RESULT, 0 - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_GivePrize0 - end + specialvar VAR_RESULT, BufferQuizAuthorNameAndCheckIfLady + goto_if_eq VAR_RESULT, 1, LilycoveCity_PokemonCenter_1F_EventScript_GivePrize1 + goto_if_eq VAR_RESULT, 0, LilycoveCity_PokemonCenter_1F_EventScript_GivePrize0 + end LilycoveCity_PokemonCenter_1F_EventScript_GivePrize1:: - msgbox LilycoveCity_PokemonCenter_1F_Text_YouGotItRightYouveWonPersonsPrize, MSGBOX_DEFAULT - goto LilycoveCity_PokemonCenter_1F_EventScript_GivePrize - end + msgbox LilycoveCity_PokemonCenter_1F_Text_YouGotItRightYouveWonPersonsPrize, MSGBOX_DEFAULT + goto LilycoveCity_PokemonCenter_1F_EventScript_GivePrize + end LilycoveCity_PokemonCenter_1F_EventScript_GivePrize0:: - msgbox LilycoveCity_PokemonCenter_1F_Text_YouGotItRightYouveWonPersonsPrize, MSGBOX_DEFAULT - goto LilycoveCity_PokemonCenter_1F_EventScript_GivePrize - end + msgbox LilycoveCity_PokemonCenter_1F_Text_YouGotItRightYouveWonPersonsPrize, MSGBOX_DEFAULT + goto LilycoveCity_PokemonCenter_1F_EventScript_GivePrize + end LilycoveCity_PokemonCenter_1F_EventScript_GivePrize:: - setvar VAR_0x8005, 0 - special BufferQuizPrizeItem - special SetQuizLadyState_Complete - giveitem VAR_0x8005 - compare VAR_RESULT, FALSE - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_NoSpaceForQuizPrize - goto LilycoveCity_PokemonCenter_1F_EventScript_AskMakeQuiz - end + setvar VAR_0x8005, 0 + special BufferQuizPrizeItem + special SetQuizLadyState_Complete + giveitem VAR_0x8005 + goto_if_eq VAR_RESULT, FALSE, LilycoveCity_PokemonCenter_1F_EventScript_NoSpaceForQuizPrize + goto LilycoveCity_PokemonCenter_1F_EventScript_AskMakeQuiz + end LilycoveCity_PokemonCenter_1F_EventScript_NoSpaceForQuizPrize:: - msgbox LilycoveCity_PokemonCenter_1F_Text_YourBagIsFilledUp, MSGBOX_DEFAULT - special SetQuizLadyState_GivePrize - release - end + msgbox LilycoveCity_PokemonCenter_1F_Text_YourBagIsFilledUp, MSGBOX_DEFAULT + special SetQuizLadyState_GivePrize + release + end LilycoveCity_PokemonCenter_1F_EventScript_AskMakeQuiz:: - msgbox LilycoveCity_PokemonCenter_1F_Text_MakeYourOwnQuiz, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_MakeQuiz - compare VAR_RESULT, NO - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_DeclineMakeQuiz - end + msgbox LilycoveCity_PokemonCenter_1F_Text_MakeYourOwnQuiz, MSGBOX_YESNO + goto_if_eq VAR_RESULT, YES, LilycoveCity_PokemonCenter_1F_EventScript_MakeQuiz + goto_if_eq VAR_RESULT, NO, LilycoveCity_PokemonCenter_1F_EventScript_DeclineMakeQuiz + end LilycoveCity_PokemonCenter_1F_EventScript_DeclineMakeQuiz:: - special QuizLadyPickNewQuestion - msgbox LilycoveCity_PokemonCenter_1F_Text_MaybeNextTime, MSGBOX_DEFAULT - release - end + special QuizLadyPickNewQuestion + msgbox LilycoveCity_PokemonCenter_1F_Text_MaybeNextTime, MSGBOX_DEFAULT + release + end LilycoveCity_PokemonCenter_1F_EventScript_MakeQuiz:: - msgbox LilycoveCity_PokemonCenter_1F_Text_PickYourPrize, MSGBOX_DEFAULT + msgbox LilycoveCity_PokemonCenter_1F_Text_PickYourPrize, MSGBOX_DEFAULT LilycoveCity_PokemonCenter_1F_EventScript_PickPrize:: - fadescreen FADE_TO_BLACK - setvar VAR_RESULT, 0 - special Script_QuizLadyOpenBagMenu - waitstate - compare VAR_RESULT, 0 - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_AskQuitChoosingPrize - compare VAR_RESULT, 1 - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_WriteQuiz - end + fadescreen FADE_TO_BLACK + setvar VAR_RESULT, 0 + special Script_QuizLadyOpenBagMenu + waitstate + goto_if_eq VAR_RESULT, 0, LilycoveCity_PokemonCenter_1F_EventScript_AskQuitChoosingPrize + goto_if_eq VAR_RESULT, 1, LilycoveCity_PokemonCenter_1F_EventScript_WriteQuiz + end LilycoveCity_PokemonCenter_1F_EventScript_AskQuitChoosingPrize:: - msgbox LilycoveCity_PokemonCenter_1F_Text_QuitChoosingPrize, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_DeclineMakeQuiz - compare VAR_RESULT, NO - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_PickPrize - end + msgbox LilycoveCity_PokemonCenter_1F_Text_QuitChoosingPrize, MSGBOX_YESNO + goto_if_eq VAR_RESULT, YES, LilycoveCity_PokemonCenter_1F_EventScript_DeclineMakeQuiz + goto_if_eq VAR_RESULT, NO, LilycoveCity_PokemonCenter_1F_EventScript_PickPrize + end LilycoveCity_PokemonCenter_1F_EventScript_WriteQuiz:: - msgbox LilycoveCity_PokemonCenter_1F_Text_WriteYourQuiz, MSGBOX_DEFAULT - special ClearQuizLadyQuestionAndAnswer - special ClearQuizLadyPlayerAnswer - setvar VAR_0x8004, EASY_CHAT_TYPE_QUIZ_QUESTION + msgbox LilycoveCity_PokemonCenter_1F_Text_WriteYourQuiz, MSGBOX_DEFAULT + special ClearQuizLadyQuestionAndAnswer + special ClearQuizLadyPlayerAnswer + setvar VAR_0x8004, EASY_CHAT_TYPE_QUIZ_QUESTION LilycoveCity_PokemonCenter_1F_EventScript_WriteQuizQuestion:: - fadescreen FADE_TO_BLACK - special QuizLadySetCustomQuestion - waitstate - compare VAR_RESULT, 0 - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_AskQuitWritingQuizQuestion - goto LilycoveCity_PokemonCenter_1F_EventScript_FinishMakingQuiz - end + fadescreen FADE_TO_BLACK + special QuizLadySetCustomQuestion + waitstate + goto_if_eq VAR_RESULT, 0, LilycoveCity_PokemonCenter_1F_EventScript_AskQuitWritingQuizQuestion + goto LilycoveCity_PokemonCenter_1F_EventScript_FinishMakingQuiz + end LilycoveCity_PokemonCenter_1F_EventScript_AskQuitWritingQuizQuestion:: - msgbox LilycoveCity_PokemonCenter_1F_Text_QuitWritingQuizQuestion, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_DeclineMakeQuiz - compare VAR_RESULT, NO - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_WriteQuizQuestion - end + msgbox LilycoveCity_PokemonCenter_1F_Text_QuitWritingQuizQuestion, MSGBOX_YESNO + goto_if_eq VAR_RESULT, YES, LilycoveCity_PokemonCenter_1F_EventScript_DeclineMakeQuiz + goto_if_eq VAR_RESULT, NO, LilycoveCity_PokemonCenter_1F_EventScript_WriteQuizQuestion + end LilycoveCity_PokemonCenter_1F_EventScript_FinishMakingQuiz:: - special QuizLadyTakePrizeForCustomQuiz - special QuizLadyRecordCustomQuizData - special QuizLadySetWaitingForChallenger - msgbox LilycoveCity_PokemonCenter_1F_Text_IllLookForAChallenger, MSGBOX_DEFAULT - release - end + special QuizLadyTakePrizeForCustomQuiz + special QuizLadyRecordCustomQuizData + special QuizLadySetWaitingForChallenger + msgbox LilycoveCity_PokemonCenter_1F_Text_IllLookForAChallenger, MSGBOX_DEFAULT + release + end LilycoveCity_PokemonCenter_1F_EventScript_ContestLady:: - lock - faceplayer - msgbox LilycoveCity_PokemonCenter_1F_Text_ImTheContestLady, MSGBOX_DEFAULT - specialvar VAR_RESULT, HasPlayerGivenContestLadyPokeblock - compare VAR_RESULT, FALSE - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_NotGivenPokeblock - compare VAR_RESULT, TRUE - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_GivenPokeblock - end + lock + faceplayer + msgbox LilycoveCity_PokemonCenter_1F_Text_ImTheContestLady, MSGBOX_DEFAULT + specialvar VAR_RESULT, HasPlayerGivenContestLadyPokeblock + goto_if_eq VAR_RESULT, FALSE, LilycoveCity_PokemonCenter_1F_EventScript_NotGivenPokeblock + goto_if_eq VAR_RESULT, TRUE, LilycoveCity_PokemonCenter_1F_EventScript_GivenPokeblock + end @ Redundant with above script, VAR_RESULT will always be FALSE here LilycoveCity_PokemonCenter_1F_EventScript_NotGivenPokeblock:: - specialvar VAR_RESULT, ShouldContestLadyShowGoOnAir - compare VAR_RESULT, FALSE - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_AskForPokeblock - compare VAR_RESULT, TRUE - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_GivenPokeblock - end + specialvar VAR_RESULT, ShouldContestLadyShowGoOnAir + goto_if_eq VAR_RESULT, FALSE, LilycoveCity_PokemonCenter_1F_EventScript_AskForPokeblock + goto_if_eq VAR_RESULT, TRUE, LilycoveCity_PokemonCenter_1F_EventScript_GivenPokeblock + end LilycoveCity_PokemonCenter_1F_EventScript_GivenPokeblock:: - msgbox LilycoveCity_PokemonCenter_1F_Text_ThankForPokeblock, MSGBOX_DEFAULT - release - end + msgbox LilycoveCity_PokemonCenter_1F_Text_ThankForPokeblock, MSGBOX_DEFAULT + release + end LilycoveCity_PokemonCenter_1F_EventScript_AskForPokeblock:: - special Script_BufferContestLadyCategoryAndMonName - msgbox LilycoveCity_PokemonCenter_1F_Text_MyFriendDisplaysQuality, MSGBOX_DEFAULT - checkitem ITEM_POKEBLOCK_CASE, 1 - compare VAR_RESULT, FALSE - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_NoPokeblockCase - msgbox LilycoveCity_PokemonCenter_1F_Text_AskingForOnePokeblock, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_DeclineGivePokeblock - compare VAR_RESULT, YES - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_ChoosePokeblock - end + special Script_BufferContestLadyCategoryAndMonName + msgbox LilycoveCity_PokemonCenter_1F_Text_MyFriendDisplaysQuality, MSGBOX_DEFAULT + checkitem ITEM_POKEBLOCK_CASE + goto_if_eq VAR_RESULT, FALSE, LilycoveCity_PokemonCenter_1F_EventScript_NoPokeblockCase + msgbox LilycoveCity_PokemonCenter_1F_Text_AskingForOnePokeblock, MSGBOX_YESNO + goto_if_eq VAR_RESULT, NO, LilycoveCity_PokemonCenter_1F_EventScript_DeclineGivePokeblock + goto_if_eq VAR_RESULT, YES, LilycoveCity_PokemonCenter_1F_EventScript_ChoosePokeblock + end LilycoveCity_PokemonCenter_1F_EventScript_DeclineGivePokeblock:: - msgbox LilycoveCity_PokemonCenter_1F_Text_WhatACheapskate, MSGBOX_DEFAULT - release - end + msgbox LilycoveCity_PokemonCenter_1F_Text_WhatACheapskate, MSGBOX_DEFAULT + release + end LilycoveCity_PokemonCenter_1F_EventScript_ChoosePokeblock:: - fadescreen FADE_TO_BLACK - special OpenPokeblockCaseForContestLady - waitstate - compare VAR_RESULT, 0xFFFF - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_AskQuitGivingPokeblock - compare VAR_RESULT, 0xFFFF - goto_if_ne LilycoveCity_PokemonCenter_1F_EventScript_GivePokeblock - end + fadescreen FADE_TO_BLACK + special OpenPokeblockCaseForContestLady + waitstate + goto_if_eq VAR_RESULT, 0xFFFF, LilycoveCity_PokemonCenter_1F_EventScript_AskQuitGivingPokeblock + goto_if_ne VAR_RESULT, 0xFFFF, LilycoveCity_PokemonCenter_1F_EventScript_GivePokeblock + end LilycoveCity_PokemonCenter_1F_EventScript_AskQuitGivingPokeblock:: - msgbox LilycoveCity_PokemonCenter_1F_Text_ICantHaveOnePokeblock, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_DeclineGivePokeblock - compare VAR_RESULT, NO - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_ChoosePokeblock - end + msgbox LilycoveCity_PokemonCenter_1F_Text_ICantHaveOnePokeblock, MSGBOX_YESNO + goto_if_eq VAR_RESULT, YES, LilycoveCity_PokemonCenter_1F_EventScript_DeclineGivePokeblock + goto_if_eq VAR_RESULT, NO, LilycoveCity_PokemonCenter_1F_EventScript_ChoosePokeblock + end LilycoveCity_PokemonCenter_1F_EventScript_GivePokeblock:: - msgbox LilycoveCity_PokemonCenter_1F_Text_IllUseYourPokeblock, MSGBOX_DEFAULT - special SetContestLadyGivenPokeblock - special GetContestLadyMonSpecies - goto LilycoveCity_PokemonCenter_1F_EventScript_FeedPokeblock - end + msgbox LilycoveCity_PokemonCenter_1F_Text_IllUseYourPokeblock, MSGBOX_DEFAULT + special SetContestLadyGivenPokeblock + special GetContestLadyMonSpecies + goto LilycoveCity_PokemonCenter_1F_EventScript_FeedPokeblock + end @ VAR_0x8004 here is the return value from GivePokeblockToContestLady LilycoveCity_PokemonCenter_1F_EventScript_FeedPokeblock:: - applymovement LOCALID_LILYCOVE_LADY, LilycoveCity_PokemonCenter_1F_Movement_LadyFaceMon - waitmovement 0 - delay 60 - applymovement LOCALID_LADYS_MON, LilycoveCity_PokemonCenter_1F_Movement_MonFaceLady - waitmovement 0 - delay 60 - waitse - playmoncry VAR_0x8005, CRY_MODE_NORMAL - delay 120 - waitmoncry - compare VAR_0x8004, 1 - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_MonEnjoyPokeblock - goto LilycoveCity_PokemonCenter_1F_EventScript_FinishFeedPokeblock - end + applymovement LOCALID_LILYCOVE_LADY, LilycoveCity_PokemonCenter_1F_Movement_LadyFaceMon + waitmovement 0 + delay 60 + applymovement LOCALID_LADYS_MON, LilycoveCity_PokemonCenter_1F_Movement_MonFaceLady + waitmovement 0 + delay 60 + waitse + playmoncry VAR_0x8005, CRY_MODE_NORMAL + delay 120 + waitmoncry + goto_if_eq VAR_0x8004, 1, LilycoveCity_PokemonCenter_1F_EventScript_MonEnjoyPokeblock + goto LilycoveCity_PokemonCenter_1F_EventScript_FinishFeedPokeblock + end @ VAR_0x8004 here is the return value from GivePokeblockToContestLady LilycoveCity_PokemonCenter_1F_EventScript_MonEnjoyPokeblock:: - applymovement LOCALID_LADYS_MON, LilycoveCity_PokemonCenter_1F_Movement_MonJump - waitmovement 0 - delay 60 + applymovement LOCALID_LADYS_MON, LilycoveCity_PokemonCenter_1F_Movement_MonJump + waitmovement 0 + delay 60 LilycoveCity_PokemonCenter_1F_EventScript_FinishFeedPokeblock:: - applymovement LOCALID_LILYCOVE_LADY, LilycoveCity_PokemonCenter_1F_Movement_LadyFacePlayer - waitmovement 0 - delay 60 - compare VAR_0x8004, 0 - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_MonDislikedPokeblock - compare VAR_0x8004, 1 - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_MonLikedPokeblock - end + applymovement LOCALID_LILYCOVE_LADY, LilycoveCity_PokemonCenter_1F_Movement_LadyFacePlayer + waitmovement 0 + delay 60 + goto_if_eq VAR_0x8004, 0, LilycoveCity_PokemonCenter_1F_EventScript_MonDislikedPokeblock + goto_if_eq VAR_0x8004, 1, LilycoveCity_PokemonCenter_1F_EventScript_MonLikedPokeblock + end LilycoveCity_PokemonCenter_1F_EventScript_MonDislikedPokeblock:: - msgbox LilycoveCity_PokemonCenter_1F_Text_NoChangeThanks, MSGBOX_DEFAULT - goto LilycoveCity_PokemonCenter_1F_EventScript_CheckAirContestLadyShow - end + msgbox LilycoveCity_PokemonCenter_1F_Text_NoChangeThanks, MSGBOX_DEFAULT + goto LilycoveCity_PokemonCenter_1F_EventScript_CheckAirContestLadyShow + end LilycoveCity_PokemonCenter_1F_EventScript_MonLikedPokeblock:: - special Script_BufferContestLadyCategoryAndMonName - msgbox LilycoveCity_PokemonCenter_1F_Text_ReallyImprovedThanks, MSGBOX_DEFAULT - goto LilycoveCity_PokemonCenter_1F_EventScript_CheckAirContestLadyShow - end + special Script_BufferContestLadyCategoryAndMonName + msgbox LilycoveCity_PokemonCenter_1F_Text_ReallyImprovedThanks, MSGBOX_DEFAULT + goto LilycoveCity_PokemonCenter_1F_EventScript_CheckAirContestLadyShow + end LilycoveCity_PokemonCenter_1F_EventScript_CheckAirContestLadyShow:: - specialvar VAR_RESULT, ShouldContestLadyShowGoOnAir - compare VAR_RESULT, 1 - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_AirContestLadyShow - release - end + specialvar VAR_RESULT, ShouldContestLadyShowGoOnAir + goto_if_eq VAR_RESULT, 1, LilycoveCity_PokemonCenter_1F_EventScript_AirContestLadyShow + release + end LilycoveCity_PokemonCenter_1F_EventScript_AirContestLadyShow:: - msgbox LilycoveCity_PokemonCenter_1F_Text_ReadyToEnterContests, MSGBOX_DEFAULT - special PutLilycoveContestLadyShowOnTheAir - release - end + msgbox LilycoveCity_PokemonCenter_1F_Text_ReadyToEnterContests, MSGBOX_DEFAULT + special PutLilycoveContestLadyShowOnTheAir + release + end LilycoveCity_PokemonCenter_1F_EventScript_NoPokeblockCase:: - msgbox LilycoveCity_PokemonCenter_1F_Text_DontHaveAPokeblockCase, MSGBOX_DEFAULT - release - end + msgbox LilycoveCity_PokemonCenter_1F_Text_DontHaveAPokeblockCase, MSGBOX_DEFAULT + release + end LilycoveCity_PokemonCenter_1F_Movement_LadyFaceMon: - face_right - delay_8 - step_end + face_right + delay_8 + step_end LilycoveCity_PokemonCenter_1F_Movement_MonFaceLady: - face_left - delay_8 - step_end + face_left + delay_8 + step_end @ Unused LilycoveCity_PokemonCenter_1F_Movement_MonFaceDown: - face_down - step_end + face_down + step_end LilycoveCity_PokemonCenter_1F_Movement_LadyFacePlayer: - face_player - step_end + face_player + step_end LilycoveCity_PokemonCenter_1F_Movement_MonJump: - disable_jump_landing_ground_effect - jump_in_place_left - disable_jump_landing_ground_effect - jump_in_place_left - step_end + disable_jump_landing_ground_effect + jump_in_place_left + disable_jump_landing_ground_effect + jump_in_place_left + step_end LilycoveCity_PokemonCenter_1F_EventScript_ContestLadyMon:: - specialvar VAR_RESULT, GetContestLadyCategory - special Script_BufferContestLadyCategoryAndMonName - special GetContestLadyMonSpecies - compare VAR_RESULT, CONTEST_CATEGORY_COOL - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_Zigzagoon - compare VAR_RESULT, CONTEST_CATEGORY_BEAUTY - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_Skitty - compare VAR_RESULT, CONTEST_CATEGORY_CUTE - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_Poochyena - compare VAR_RESULT, CONTEST_CATEGORY_SMART - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_Kecleon - compare VAR_RESULT, CONTEST_CATEGORY_TOUGH - goto_if_eq LilycoveCity_PokemonCenter_1F_EventScript_Pikachu - end + specialvar VAR_RESULT, GetContestLadyCategory + special Script_BufferContestLadyCategoryAndMonName + special GetContestLadyMonSpecies + goto_if_eq VAR_RESULT, CONTEST_CATEGORY_COOL, LilycoveCity_PokemonCenter_1F_EventScript_Zigzagoon + goto_if_eq VAR_RESULT, CONTEST_CATEGORY_BEAUTY, LilycoveCity_PokemonCenter_1F_EventScript_Skitty + goto_if_eq VAR_RESULT, CONTEST_CATEGORY_CUTE, LilycoveCity_PokemonCenter_1F_EventScript_Poochyena + goto_if_eq VAR_RESULT, CONTEST_CATEGORY_SMART, LilycoveCity_PokemonCenter_1F_EventScript_Kecleon + goto_if_eq VAR_RESULT, CONTEST_CATEGORY_TOUGH, LilycoveCity_PokemonCenter_1F_EventScript_Pikachu + end LilycoveCity_PokemonCenter_1F_EventScript_Zigzagoon:: - lock - faceplayer - waitse - playmoncry VAR_0x8005, CRY_MODE_NORMAL - msgbox LilycoveCity_PokemonCenter_1F_Text_Zigzagoon, MSGBOX_DEFAULT - waitmoncry - release - end + lock + faceplayer + waitse + playmoncry VAR_0x8005, CRY_MODE_NORMAL + msgbox LilycoveCity_PokemonCenter_1F_Text_Zigzagoon, MSGBOX_DEFAULT + waitmoncry + release + end LilycoveCity_PokemonCenter_1F_EventScript_Skitty:: - lock - faceplayer - waitse - playmoncry VAR_0x8005, CRY_MODE_NORMAL - msgbox LilycoveCity_PokemonCenter_1F_Text_Skitty, MSGBOX_DEFAULT - waitmoncry - release - end + lock + faceplayer + waitse + playmoncry VAR_0x8005, CRY_MODE_NORMAL + msgbox LilycoveCity_PokemonCenter_1F_Text_Skitty, MSGBOX_DEFAULT + waitmoncry + release + end LilycoveCity_PokemonCenter_1F_EventScript_Poochyena:: - lock - faceplayer - waitse - playmoncry VAR_0x8005, CRY_MODE_NORMAL - msgbox LilycoveCity_PokemonCenter_1F_Text_Poochyena, MSGBOX_DEFAULT - waitmoncry - release - end + lock + faceplayer + waitse + playmoncry VAR_0x8005, CRY_MODE_NORMAL + msgbox LilycoveCity_PokemonCenter_1F_Text_Poochyena, MSGBOX_DEFAULT + waitmoncry + release + end LilycoveCity_PokemonCenter_1F_EventScript_Kecleon:: - lock - faceplayer - waitse - playmoncry VAR_0x8005, CRY_MODE_NORMAL - msgbox LilycoveCity_PokemonCenter_1F_Text_Kecleon, MSGBOX_DEFAULT - waitmoncry - release - end + lock + faceplayer + waitse + playmoncry VAR_0x8005, CRY_MODE_NORMAL + msgbox LilycoveCity_PokemonCenter_1F_Text_Kecleon, MSGBOX_DEFAULT + waitmoncry + release + end LilycoveCity_PokemonCenter_1F_EventScript_Pikachu:: - lock - faceplayer - waitse - playmoncry VAR_0x8005, CRY_MODE_NORMAL - msgbox LilycoveCity_PokemonCenter_1F_Text_Pikachu, MSGBOX_DEFAULT - waitmoncry - release - end + lock + faceplayer + waitse + playmoncry VAR_0x8005, CRY_MODE_NORMAL + msgbox LilycoveCity_PokemonCenter_1F_Text_Pikachu, MSGBOX_DEFAULT + waitmoncry + release + end LilycoveCity_PokemonCenter_1F_Text_ImTheFavorLady: - .string "I'm the FAVOR LADY…$" + .string "I'm the FAVOR LADY…$" LilycoveCity_PokemonCenter_1F_Text_ObsessedWithThing: - .string "I've recently developed an obsession\n" - .string "for {STR_VAR_1} things…$" + .string "I've recently developed an obsession\n" + .string "for {STR_VAR_1} things…$" LilycoveCity_PokemonCenter_1F_Text_ThankYouForLastTime: - .string "Oh…\n" - .string "Thank you for last time…$" + .string "Oh…\n" + .string "Thank you for last time…$" LilycoveCity_PokemonCenter_1F_Text_PlayerGaveMeBadThing: - .string "Before, I think it was {STR_VAR_3}…\p" - .string "{STR_VAR_3} gave me one {STR_VAR_2},\n" - .string "saying it was {STR_VAR_1}.\p" - .string "But it wasn't {STR_VAR_1}.\n" - .string "Not in the least bit.$" + .string "Before, I think it was {STR_VAR_3}…\p" + .string "{STR_VAR_3} gave me one {STR_VAR_2},\n" + .string "saying it was {STR_VAR_1}.\p" + .string "But it wasn't {STR_VAR_1}.\n" + .string "Not in the least bit.$" LilycoveCity_PokemonCenter_1F_Text_PlayerGaveMeGreatThing: - .string "Before, {STR_VAR_3} gave me a very\n" - .string "{STR_VAR_1} {STR_VAR_2}.\p" - .string "I cherish it now.$" + .string "Before, {STR_VAR_3} gave me a very\n" + .string "{STR_VAR_1} {STR_VAR_2}.\p" + .string "I cherish it now.$" LilycoveCity_PokemonCenter_1F_Text_WillYouShareThing: - .string "Listen, if you have anything that\n" - .string "is {STR_VAR_1}, will you share it\l" - .string "with me?$" + .string "Listen, if you have anything that\n" + .string "is {STR_VAR_1}, will you share it\l" + .string "with me?$" LilycoveCity_PokemonCenter_1F_Text_WhatWillYouGiveMe: - .string "…Really?\n" - .string "What will you give me?$" + .string "…Really?\n" + .string "What will you give me?$" LilycoveCity_PokemonCenter_1F_Text_IsThatSoGoodbye: - .string "Is that so?\n" - .string "Then, it's good-bye…$" + .string "Is that so?\n" + .string "Then, it's good-bye…$" LilycoveCity_PokemonCenter_1F_Text_NotWillingToShare: - .string "Oh…\n" - .string "You're not willing to share?$" + .string "Oh…\n" + .string "You're not willing to share?$" LilycoveCity_PokemonCenter_1F_Text_IllTryToCherishIt: - .string "Oh?\n" - .string "That {STR_VAR_2} is {STR_VAR_1}?\p" - .string "…Oh, is that right?\p" - .string "Well, I owe you a thanks anyway.\n" - .string "I'll try to cherish it…$" + .string "Oh?\n" + .string "That {STR_VAR_2} is {STR_VAR_1}?\p" + .string "…Oh, is that right?\p" + .string "Well, I owe you a thanks anyway.\n" + .string "I'll try to cherish it…$" LilycoveCity_PokemonCenter_1F_Text_IWillCherishThis: - .string "Oh…\p" - .string "That's a quite {STR_VAR_1}\n" - .string "{STR_VAR_2}…\p" - .string "Isn't it nice?\n" - .string "It's so dreamy…\p" - .string "Thank you…\n" - .string "I will cherish this…$" + .string "Oh…\p" + .string "That's a quite {STR_VAR_1}\n" + .string "{STR_VAR_2}…\p" + .string "Isn't it nice?\n" + .string "It's so dreamy…\p" + .string "Thank you…\n" + .string "I will cherish this…$" LilycoveCity_PokemonCenter_1F_Text_IWillTreasureThis: - .string "…Oh, oh, oh…\p" - .string "This is amazing!\n" - .string "This really is {STR_VAR_1}!\p" - .string "I never knew that one {STR_VAR_2}\n" - .string "could be this {STR_VAR_1}!\p" - .string "Thank you!\p" - .string "I will treasure this for the rest\n" - .string "of my life!$" + .string "…Oh, oh, oh…\p" + .string "This is amazing!\n" + .string "This really is {STR_VAR_1}!\p" + .string "I never knew that one {STR_VAR_2}\n" + .string "could be this {STR_VAR_1}!\p" + .string "Thank you!\p" + .string "I will treasure this for the rest\n" + .string "of my life!$" LilycoveCity_PokemonCenter_1F_Text_IllGiveYouThisInReturn: - .string "I'll give you this wonderful item in\n" - .string "return for your fabulous gift.\p" - .string "I hope you will cherish it…$" + .string "I'll give you this wonderful item in\n" + .string "return for your fabulous gift.\p" + .string "I hope you will cherish it…$" LilycoveCity_PokemonCenter_1F_Text_YouDontHaveSpaceForIt: - .string "Oh, you can't have it if you don't have\n" - .string "the space for it.\p" - .string "Please come see me when you get\n" - .string "your BAG organized…$" + .string "Oh, you can't have it if you don't have\n" + .string "the space for it.\p" + .string "Please come see me when you get\n" + .string "your BAG organized…$" LilycoveCity_PokemonCenter_1F_Text_ImTheQuizLady: - .string "I'm the QUIZ LADY!\n" - .string "I love quizzes!$" + .string "I'm the QUIZ LADY!\n" + .string "I love quizzes!$" LilycoveCity_PokemonCenter_1F_Text_WaitingToTakeYourQuiz: - .string "Oh?\p" - .string "I'm waiting for a challenger to answer\n" - .string "the quiz you made.\p" - .string "We can chat another time, okay?$" + .string "Oh?\p" + .string "I'm waiting for a challenger to answer\n" + .string "the quiz you made.\p" + .string "We can chat another time, okay?$" LilycoveCity_PokemonCenter_1F_Text_WaitingForChallenger: - .string "I'm waiting for someone to challenge\n" - .string "a quiz this {STR_VAR_1} thought up!$" + .string "I'm waiting for someone to challenge\n" + .string "a quiz this {STR_VAR_1} thought up!$" LilycoveCity_PokemonCenter_1F_Text_TakeQuizChallenge: - .string "If you answer correctly, you can win\n" - .string "fabulous prizes!\p" - .string "Would you like to take the quiz\n" - .string "challenge?$" + .string "If you answer correctly, you can win\n" + .string "fabulous prizes!\p" + .string "Would you like to take the quiz\n" + .string "challenge?$" LilycoveCity_PokemonCenter_1F_Text_WaitForAnswer: - .string "… … … … … …\n" - .string "… … … … … …$" + .string "… … … … … …\n" + .string "… … … … … …$" LilycoveCity_PokemonCenter_1F_Text_HowBoringBye: - .string "Oh, how boring!\n" - .string "Bye-bye!$" + .string "Oh, how boring!\n" + .string "Bye-bye!$" LilycoveCity_PokemonCenter_1F_Text_YoureGoingToQuit: - .string "Awww!\n" - .string "You're going to quit?$" + .string "Awww!\n" + .string "You're going to quit?$" LilycoveCity_PokemonCenter_1F_Text_TakeTheQuizAnotherTime: - .string "Please take the quiz challenge\n" - .string "another time!$" + .string "Please take the quiz challenge\n" + .string "another time!$" LilycoveCity_PokemonCenter_1F_Text_YouGotItRight: - .string "You're amazing! You've got it right!\n" - .string "You're one sharp customer!$" + .string "You're amazing! You've got it right!\n" + .string "You're one sharp customer!$" LilycoveCity_PokemonCenter_1F_Text_YouGotItRightYouveWonPersonsPrize: - .string "Congratulations!\n" - .string "You've got the quiz right!\p" - .string "You've won a prize provided by\n" - .string "{STR_VAR_1}!$" + .string "Congratulations!\n" + .string "You've got the quiz right!\p" + .string "You've won a prize provided by\n" + .string "{STR_VAR_1}!$" @ Unused LilycoveCity_PokemonCenter_1F_Text_XReceivedOneY: - .string "{STR_VAR_1} received\n" - .string "one {STR_VAR_2}!$" + .string "{STR_VAR_1} received\n" + .string "one {STR_VAR_2}!$" LilycoveCity_PokemonCenter_1F_Text_YourBagIsFilledUp: - .string "Oh? Your BAG is filled up!\n" - .string "Come see me when you have room.$" + .string "Oh? Your BAG is filled up!\n" + .string "Come see me when you have room.$" LilycoveCity_PokemonCenter_1F_Text_WrongTheCorrectAnswerIs: - .string "Hmm… Wrong!\n" - .string "The correct answer is “{STR_VAR_3}”!$" + .string "Hmm… Wrong!\n" + .string "The correct answer is “{STR_VAR_3}”!$" LilycoveCity_PokemonCenter_1F_Text_IGetToKeepPrize: - .string "Too bad!\p" - .string "I get to keep the quiz prize\n" - .string "{STR_VAR_1} now!$" + .string "Too bad!\p" + .string "I get to keep the quiz prize\n" + .string "{STR_VAR_1} now!$" LilycoveCity_PokemonCenter_1F_Text_MakeYourOwnQuiz: - .string "Listen, listen!\n" - .string "Would you like to make your own quiz?$" + .string "Listen, listen!\n" + .string "Would you like to make your own quiz?$" LilycoveCity_PokemonCenter_1F_Text_MaybeNextTime: - .string "Oh, I see…\n" - .string "Well, maybe next time!$" + .string "Oh, I see…\n" + .string "Well, maybe next time!$" LilycoveCity_PokemonCenter_1F_Text_PickYourPrize: - .string "Okay, the first thing you have to do\n" - .string "is pick the prize for the person that\l" - .string "answers your quiz correctly.\p" - .string "But beware, if the person taking\n" - .string "the quiz can't get it right, I get to\l" - .string "keep the prize!$" + .string "Okay, the first thing you have to do\n" + .string "is pick the prize for the person that\l" + .string "answers your quiz correctly.\p" + .string "But beware, if the person taking\n" + .string "the quiz can't get it right, I get to\l" + .string "keep the prize!$" LilycoveCity_PokemonCenter_1F_Text_QuitChoosingPrize: - .string "If you don't choose a prize,\n" - .string "your quiz can't be made.\p" - .string "Are you going to quit making\n" - .string "your quiz?$" + .string "If you don't choose a prize,\n" + .string "your quiz can't be made.\p" + .string "Are you going to quit making\n" + .string "your quiz?$" LilycoveCity_PokemonCenter_1F_Text_WriteYourQuiz: - .string "Oh, how nice!\n" - .string "That's a wonderful prize!\p" - .string "Next, you need to write your quiz\n" - .string "question and its answer.$" + .string "Oh, how nice!\n" + .string "That's a wonderful prize!\p" + .string "Next, you need to write your quiz\n" + .string "question and its answer.$" LilycoveCity_PokemonCenter_1F_Text_QuitWritingQuizQuestion: - .string "Are you going to quit writing\n" - .string "your quiz question?$" + .string "Are you going to quit writing\n" + .string "your quiz question?$" @ Unused LilycoveCity_PokemonCenter_1F_Text_QuitWritingQuizAnswer: - .string "Are you going to quit choosing\n" - .string "your quiz answer?$" + .string "Are you going to quit choosing\n" + .string "your quiz answer?$" LilycoveCity_PokemonCenter_1F_Text_IllLookForAChallenger: - .string "Thank you!\n" - .string "You've put together a nice quiz.\p" - .string "I'll go look for someone who'll take\n" - .string "your quiz challenge right away.$" + .string "Thank you!\n" + .string "You've put together a nice quiz.\p" + .string "I'll go look for someone who'll take\n" + .string "your quiz challenge right away.$" LilycoveCity_PokemonCenter_1F_Text_ImTheContestLady: - .string "I'm the CONTEST LADY!\n" - .string "I sure do love CONTESTS!$" + .string "I'm the CONTEST LADY!\n" + .string "I sure do love CONTESTS!$" LilycoveCity_PokemonCenter_1F_Text_ThankForPokeblock: - .string "Thanks for your {POKEBLOCK} before!$" + .string "Thanks for your {POKEBLOCK} before!$" LilycoveCity_PokemonCenter_1F_Text_MyFriendDisplaysQuality: - .string "This is my friend {STR_VAR_1}!\n" - .string "It's the epitome of {STR_VAR_2}!\p" - .string "But I think that it will display\n" - .string "even more {STR_VAR_2}!$" + .string "This is my friend {STR_VAR_1}!\n" + .string "It's the epitome of {STR_VAR_2}!\p" + .string "But I think that it will display\n" + .string "even more {STR_VAR_2}!$" LilycoveCity_PokemonCenter_1F_Text_DontHaveAPokeblockCase: - .string "So, I need your help!\p" - .string "Please, may I have one {POKEBLOCK}?\n" - .string "All I'm asking for is one!\p" - .string "…Oh, but…\n" - .string "Don't you have a {POKEBLOCK} CASE?\l" - .string "That's no good. Next time, then!$" + .string "So, I need your help!\p" + .string "Please, may I have one {POKEBLOCK}?\n" + .string "All I'm asking for is one!\p" + .string "…Oh, but…\n" + .string "Don't you have a {POKEBLOCK} CASE?\l" + .string "That's no good. Next time, then!$" LilycoveCity_PokemonCenter_1F_Text_AskingForOnePokeblock: - .string "So, I need your help!\p" - .string "Please, may I have one {POKEBLOCK}?\n" - .string "All I'm asking for is one!$" + .string "So, I need your help!\p" + .string "Please, may I have one {POKEBLOCK}?\n" + .string "All I'm asking for is one!$" LilycoveCity_PokemonCenter_1F_Text_ICantHaveOnePokeblock: - .string "Awww!\n" - .string "I can't have one {POKEBLOCK}?!$" + .string "Awww!\n" + .string "I can't have one {POKEBLOCK}?!$" LilycoveCity_PokemonCenter_1F_Text_WhatACheapskate: - .string "Sheesh!\n" - .string "What a cheapskate!$" + .string "Sheesh!\n" + .string "What a cheapskate!$" LilycoveCity_PokemonCenter_1F_Text_IllUseYourPokeblock: - .string "Yay!\n" - .string "Thank you!\p" - .string "I'll feed my POKéMON your {POKEBLOCK}\n" - .string "right away.$" + .string "Yay!\n" + .string "Thank you!\p" + .string "I'll feed my POKéMON your {POKEBLOCK}\n" + .string "right away.$" LilycoveCity_PokemonCenter_1F_Text_NoChangeThanks: - .string "…It doesn't seem to have changed\n" - .string "in any way at all…\p" - .string "Hmm…\p" - .string "Oh, well!\n" - .string "Thank you very much!$" + .string "…It doesn't seem to have changed\n" + .string "in any way at all…\p" + .string "Hmm…\p" + .string "Oh, well!\n" + .string "Thank you very much!$" LilycoveCity_PokemonCenter_1F_Text_ReallyImprovedThanks: - .string "Oh, yay!\n" - .string "It's really delighted!\p" - .string "I think it really improved {STR_VAR_1}'s\n" - .string "{STR_VAR_2} quality, too.\p" - .string "Thank you so much!$" + .string "Oh, yay!\n" + .string "It's really delighted!\p" + .string "I think it really improved {STR_VAR_1}'s\n" + .string "{STR_VAR_2} quality, too.\p" + .string "Thank you so much!$" LilycoveCity_PokemonCenter_1F_Text_ReadyToEnterContests: - .string "Hmm…\p" - .string "I think we may be ready to enter\n" - .string "some CONTESTS.\p" - .string "If you see us in one somewhere,\n" - .string "I hope you'll cheer for us.$" + .string "Hmm…\p" + .string "I think we may be ready to enter\n" + .string "some CONTESTS.\p" + .string "If you see us in one somewhere,\n" + .string "I hope you'll cheer for us.$" LilycoveCity_PokemonCenter_1F_Text_Zigzagoon: - .string "{STR_VAR_1}: Guguuh!$" + .string "{STR_VAR_1}: Guguuh!$" LilycoveCity_PokemonCenter_1F_Text_Kecleon: - .string "{STR_VAR_1}: Igigigiiih!$" + .string "{STR_VAR_1}: Igigigiiih!$" LilycoveCity_PokemonCenter_1F_Text_Poochyena: - .string "{STR_VAR_1}: Baaarun…$" + .string "{STR_VAR_1}: Baaarun…$" LilycoveCity_PokemonCenter_1F_Text_Pikachu: - .string "{STR_VAR_1}: Pikka!$" + .string "{STR_VAR_1}: Pikka!$" LilycoveCity_PokemonCenter_1F_Text_Skitty: - .string "{STR_VAR_1}: Umyaaaan!$" + .string "{STR_VAR_1}: Umyaaaan!$" diff --git a/data/scripts/mauville_man.inc b/data/scripts/mauville_man.inc index b34f84e8e..e1fa3d179 100644 --- a/data/scripts/mauville_man.inc +++ b/data/scripts/mauville_man.inc @@ -13,10 +13,8 @@ MauvilleCity_PokemonCenter_1F_EventScript_Bard:: lock faceplayer msgbox MauvilleCity_PokemonCenter_1F_Text_WouldYouLikeToHearMySong, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_PlaySong - compare VAR_RESULT, NO - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_DeclineSong + goto_if_eq VAR_RESULT, YES, MauvilleCity_PokemonCenter_1F_EventScript_PlaySong + goto_if_eq VAR_RESULT, NO, MauvilleCity_PokemonCenter_1F_EventScript_DeclineSong end MauvilleCity_PokemonCenter_1F_EventScript_PlaySong:: @@ -24,8 +22,7 @@ MauvilleCity_PokemonCenter_1F_EventScript_PlaySong:: special PlayBardSong delay 60 special HasBardSongBeenChanged - compare VAR_RESULT, FALSE - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_AskToWriteLyrics + goto_if_eq VAR_RESULT, FALSE, MauvilleCity_PokemonCenter_1F_EventScript_AskToWriteLyrics msgbox MauvilleCity_PokemonCenter_1F_Text_WishICouldPlaySongForOthers, MSGBOX_DEFAULT release end @@ -37,10 +34,8 @@ MauvilleCity_PokemonCenter_1F_EventScript_DeclineSong:: MauvilleCity_PokemonCenter_1F_EventScript_AskToWriteLyrics:: msgbox MauvilleCity_PokemonCenter_1F_Text_WouldYouLikeToWriteSomeLyrics, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_WriteLyrics - compare VAR_RESULT, NO - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_DeclineWritingLyrics + goto_if_eq VAR_RESULT, YES, MauvilleCity_PokemonCenter_1F_EventScript_WriteLyrics + goto_if_eq VAR_RESULT, NO, MauvilleCity_PokemonCenter_1F_EventScript_DeclineWritingLyrics end MauvilleCity_PokemonCenter_1F_EventScript_WriteLyrics:: @@ -48,15 +43,13 @@ MauvilleCity_PokemonCenter_1F_EventScript_WriteLyrics:: call Common_ShowEasyChatScreen lock faceplayer - compare VAR_RESULT, 0 - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_DeclineWritingLyrics + goto_if_eq VAR_RESULT, 0, MauvilleCity_PokemonCenter_1F_EventScript_DeclineWritingLyrics msgbox MauvilleCity_PokemonCenter_1F_Text_LetMeSingItForYou, MSGBOX_DEFAULT setvar VAR_0x8004, 1 special PlayBardSong delay 60 msgbox MauvilleCity_PokemonCenter_1F_Text_ThatHowYouWantedSongToGo, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_WriteLyrics + goto_if_eq VAR_RESULT, NO, MauvilleCity_PokemonCenter_1F_EventScript_WriteLyrics special SaveBardSongLyrics msgbox MauvilleCity_PokemonCenter_1F_Text_IllSingThisSongForAWhile, MSGBOX_DEFAULT release @@ -74,16 +67,14 @@ MauvilleCity_PokemonCenter_1F_EventScript_Hipster:: setflag FLAG_SYS_HIPSTER_MEET msgbox MauvilleCity_PokemonCenter_1F_Text_TeachWhatsHipAndHappening, MSGBOX_DEFAULT special GetHipsterSpokenFlag - compare VAR_RESULT, FALSE - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_TryTeachWord + goto_if_eq VAR_RESULT, FALSE, MauvilleCity_PokemonCenter_1F_EventScript_TryTeachWord msgbox MauvilleCity_PokemonCenter_1F_Text_IAlreadyTaughtYou, MSGBOX_DEFAULT release end MauvilleCity_PokemonCenter_1F_EventScript_TryTeachWord:: special HipsterTryTeachWord - compare VAR_RESULT, TRUE - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_TeachWord + goto_if_eq VAR_RESULT, TRUE, MauvilleCity_PokemonCenter_1F_EventScript_TeachWord msgbox MauvilleCity_PokemonCenter_1F_Text_IveGotNothingNewToTeach, MSGBOX_DEFAULT release end @@ -158,11 +149,9 @@ MauvilleCity_PokemonCenter_1F_EventScript_Trader:: lock faceplayer msgbox MauvilleCity_PokemonCenter_1F_Text_WantToTradeDecor, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_DeclineTrade + goto_if_eq VAR_RESULT, NO, MauvilleCity_PokemonCenter_1F_EventScript_DeclineTrade special GetTraderTradedFlag - compare VAR_RESULT, TRUE - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_AlreadyTraded + goto_if_eq VAR_RESULT, TRUE, MauvilleCity_PokemonCenter_1F_EventScript_AlreadyTraded message MauvilleCity_PokemonCenter_1F_Text_PickADecorItem waitmessage goto MauvilleCity_PokemonCenter_1F_EventScript_PickDecorToReceive @@ -181,16 +170,12 @@ MauvilleCity_PokemonCenter_1F_EventScript_AlreadyTraded:: MauvilleCity_PokemonCenter_1F_EventScript_PickDecorToReceive:: special TraderMenuGetDecoration waitstate - compare VAR_0x8004, 0 - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_CancelPickDecor - compare VAR_0x8004, 0xFFFF - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_InvalidDecor + goto_if_eq VAR_0x8004, 0, MauvilleCity_PokemonCenter_1F_EventScript_CancelPickDecor + goto_if_eq VAR_0x8004, 0xFFFF, MauvilleCity_PokemonCenter_1F_EventScript_InvalidDecor msgbox MauvilleCity_PokemonCenter_1F_Text_OnceBelongedToPlayerDoYouWantIt, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_PickDifferentDecor + goto_if_eq VAR_RESULT, NO, MauvilleCity_PokemonCenter_1F_EventScript_PickDifferentDecor special DoesPlayerHaveNoDecorations - compare VAR_RESULT, TRUE - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_DontHaveAnyDecor + goto_if_eq VAR_RESULT, TRUE, MauvilleCity_PokemonCenter_1F_EventScript_DontHaveAnyDecor goto MauvilleCity_PokemonCenter_1F_EventScript_PickDecorToGive end @@ -220,16 +205,12 @@ MauvilleCity_PokemonCenter_1F_EventScript_PickDecorToGive:: msgbox MauvilleCity_PokemonCenter_1F_Text_PickTheDecorToTrade, MSGBOX_DEFAULT special TraderShowDecorationMenu waitstate - compare VAR_0x8006, 0 - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_CancelGiveDecor - compare VAR_0x8006, 0xFFFF - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_DecorInUse + goto_if_eq VAR_0x8006, 0, MauvilleCity_PokemonCenter_1F_EventScript_CancelGiveDecor + goto_if_eq VAR_0x8006, 0xFFFF, MauvilleCity_PokemonCenter_1F_EventScript_DecorInUse special IsDecorationCategoryFull - compare VAR_RESULT, TRUE - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_NoRoomForDecor + goto_if_eq VAR_RESULT, TRUE, MauvilleCity_PokemonCenter_1F_EventScript_NoRoomForDecor msgbox MauvilleCity_PokemonCenter_1F_Text_SoWellTradeTheseDecor, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_PickDecorToGive + goto_if_eq VAR_RESULT, NO, MauvilleCity_PokemonCenter_1F_EventScript_PickDecorToGive special TraderDoDecorationTrade msgbox MauvilleCity_PokemonCenter_1F_Text_SendDecorToYourPC, MSGBOX_DEFAULT release @@ -816,24 +797,20 @@ MauvilleCity_PokemonCenter_1F_EventScript_Storyteller:: setvar VAR_0x800A, 0 setvar VAR_0x800B, 0 msgbox MauvilleCity_PokemonCenter_1F_Text_WillYouHearMyTale, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_DeclineStoryteller + goto_if_eq VAR_RESULT, NO, MauvilleCity_PokemonCenter_1F_EventScript_DeclineStoryteller specialvar VAR_RESULT, StorytellerGetFreeStorySlot - compare VAR_RESULT, 0 - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_KnowNoTales + goto_if_eq VAR_RESULT, 0, MauvilleCity_PokemonCenter_1F_EventScript_KnowNoTales message MauvilleCity_PokemonCenter_1F_Text_WhichTaleToTell waitmessage special StorytellerStoryListMenu waitstate - compare VAR_RESULT, 0 - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_CancelStorySelection + goto_if_eq VAR_RESULT, 0, MauvilleCity_PokemonCenter_1F_EventScript_CancelStorySelection setvar VAR_0x8008, 1 special Script_StorytellerDisplayStory waitmessage waitbuttonpress specialvar VAR_RESULT, StorytellerUpdateStat - compare VAR_RESULT, 0 - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_AreThereOtherTales + goto_if_eq VAR_RESULT, 0, MauvilleCity_PokemonCenter_1F_EventScript_AreThereOtherTales goto MauvilleCity_PokemonCenter_1F_EventScript_TellPlayersTale MauvilleCity_PokemonCenter_1F_EventScript_CancelStorySelection:: @@ -843,19 +820,16 @@ MauvilleCity_PokemonCenter_1F_EventScript_CancelStorySelection:: MauvilleCity_PokemonCenter_1F_EventScript_AreThereOtherTales:: msgbox MauvilleCity_PokemonCenter_1F_Text_CouldThereBeOtherLegends, MSGBOX_DEFAULT specialvar VAR_RESULT, HasStorytellerAlreadyRecorded - compare VAR_RESULT, TRUE - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_StorytellerEnd + goto_if_eq VAR_RESULT, TRUE, MauvilleCity_PokemonCenter_1F_EventScript_StorytellerEnd goto MauvilleCity_PokemonCenter_1F_EventScript_DoYouHaveAnyTales MauvilleCity_PokemonCenter_1F_EventScript_KnowNoTales:: msgbox MauvilleCity_PokemonCenter_1F_Text_IKnowNoTales, MSGBOX_DEFAULT MauvilleCity_PokemonCenter_1F_EventScript_DoYouHaveAnyTales:: msgbox MauvilleCity_PokemonCenter_1F_Text_HaveYouAnyLegendaryTales, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_DeclineStoryteller + goto_if_eq VAR_RESULT, NO, MauvilleCity_PokemonCenter_1F_EventScript_DeclineStoryteller specialvar VAR_RESULT, Script_StorytellerInitializeRandomStat - compare VAR_RESULT, 1 - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_TellPlayersTale + goto_if_eq VAR_RESULT, 1, MauvilleCity_PokemonCenter_1F_EventScript_TellPlayersTale msgbox MauvilleCity_PokemonCenter_1F_Text_NotWorthyOfLegend, MSGBOX_DEFAULT release end @@ -902,26 +876,20 @@ MauvilleCity_PokemonCenter_1F_EventScript_Giddy:: lock faceplayer msgbox MauvilleCity_PokemonCenter_1F_Text_HearMyStory, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_TryTellTale - compare VAR_RESULT, NO - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_DeclineGiddy + goto_if_eq VAR_RESULT, YES, MauvilleCity_PokemonCenter_1F_EventScript_TryTellTale + goto_if_eq VAR_RESULT, NO, MauvilleCity_PokemonCenter_1F_EventScript_DeclineGiddy end MauvilleCity_PokemonCenter_1F_EventScript_TryTellTale:: special GiddyShouldTellAnotherTale - compare VAR_RESULT, TRUE - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_GiddyTellTale - compare VAR_RESULT, FALSE - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_ToldEnoughTales + goto_if_eq VAR_RESULT, TRUE, MauvilleCity_PokemonCenter_1F_EventScript_GiddyTellTale + goto_if_eq VAR_RESULT, FALSE, MauvilleCity_PokemonCenter_1F_EventScript_ToldEnoughTales end MauvilleCity_PokemonCenter_1F_EventScript_TryTellNewTale:: special GiddyShouldTellAnotherTale - compare VAR_RESULT, TRUE - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_GiddyStartNewTale - compare VAR_RESULT, FALSE - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_ToldEnoughTales + goto_if_eq VAR_RESULT, TRUE, MauvilleCity_PokemonCenter_1F_EventScript_GiddyStartNewTale + goto_if_eq VAR_RESULT, FALSE, MauvilleCity_PokemonCenter_1F_EventScript_ToldEnoughTales end MauvilleCity_PokemonCenter_1F_EventScript_GiddyStartNewTale:: @@ -936,10 +904,8 @@ MauvilleCity_PokemonCenter_1F_EventScript_GiddyTellTale:: special ShowFieldMessageStringVar4 waitmessage yesnobox 20, 8 - compare VAR_RESULT, YES - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_TryTellNewTale - compare VAR_RESULT, NO - goto_if_eq MauvilleCity_PokemonCenter_1F_EventScript_TryTellNewTale + goto_if_eq VAR_RESULT, YES, MauvilleCity_PokemonCenter_1F_EventScript_TryTellNewTale + goto_if_eq VAR_RESULT, NO, MauvilleCity_PokemonCenter_1F_EventScript_TryTellNewTale end MauvilleCity_PokemonCenter_1F_EventScript_DeclineGiddy:: diff --git a/data/scripts/move_tutors.inc b/data/scripts/move_tutors.inc index cc952749d..4155969a0 100644 --- a/data/scripts/move_tutors.inc +++ b/data/scripts/move_tutors.inc @@ -3,16 +3,13 @@ SlateportCity_PokemonFanClub_EventScript_SwaggerTutor:: faceplayer goto_if_set FLAG_MOVE_TUTOR_TAUGHT_SWAGGER, MoveTutor_EventScript_SwaggerTaught msgbox MoveTutor_Text_SwaggerTeach, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq MoveTutor_EventScript_SwaggerDeclined + goto_if_eq VAR_RESULT, NO, MoveTutor_EventScript_SwaggerDeclined call MoveTutor_EventScript_CanOnlyBeLearnedOnce - compare VAR_RESULT, NO - goto_if_eq MoveTutor_EventScript_SwaggerDeclined + goto_if_eq VAR_RESULT, NO, MoveTutor_EventScript_SwaggerDeclined msgbox MoveTutor_Text_SwaggerWhichMon, MSGBOX_DEFAULT setvar VAR_0x8005, TUTOR_MOVE_SWAGGER call MoveTutor_EventScript_OpenPartyMenu - compare VAR_RESULT, 0 - goto_if_eq MoveTutor_EventScript_SwaggerDeclined + goto_if_eq VAR_RESULT, 0, MoveTutor_EventScript_SwaggerDeclined setflag FLAG_MOVE_TUTOR_TAUGHT_SWAGGER goto MoveTutor_EventScript_SwaggerTaught end @@ -32,16 +29,13 @@ MauvilleCity_EventScript_RolloutTutor:: faceplayer goto_if_set FLAG_MOVE_TUTOR_TAUGHT_ROLLOUT, MoveTutor_EventScript_RolloutTaught msgbox MoveTutor_Text_RolloutTeach, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq MoveTutor_EventScript_RolloutDeclined + goto_if_eq VAR_RESULT, NO, MoveTutor_EventScript_RolloutDeclined call MoveTutor_EventScript_CanOnlyBeLearnedOnce - compare VAR_RESULT, NO - goto_if_eq MoveTutor_EventScript_RolloutDeclined + goto_if_eq VAR_RESULT, NO, MoveTutor_EventScript_RolloutDeclined msgbox MoveTutor_Text_RolloutWhichMon, MSGBOX_DEFAULT setvar VAR_0x8005, TUTOR_MOVE_ROLLOUT call MoveTutor_EventScript_OpenPartyMenu - compare VAR_RESULT, 0 - goto_if_eq MoveTutor_EventScript_RolloutDeclined + goto_if_eq VAR_RESULT, 0, MoveTutor_EventScript_RolloutDeclined setflag FLAG_MOVE_TUTOR_TAUGHT_ROLLOUT goto MoveTutor_EventScript_RolloutTaught end @@ -61,16 +55,13 @@ VerdanturfTown_PokemonCenter_1F_EventScript_FuryCutterTutor:: faceplayer goto_if_set FLAG_MOVE_TUTOR_TAUGHT_FURY_CUTTER, MoveTutor_EventScript_FuryCutterTaught msgbox MoveTutor_Text_FuryCutterTeach, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq MoveTutor_EventScript_FuryCutterDeclined + goto_if_eq VAR_RESULT, NO, MoveTutor_EventScript_FuryCutterDeclined call MoveTutor_EventScript_CanOnlyBeLearnedOnce - compare VAR_RESULT, NO - goto_if_eq MoveTutor_EventScript_FuryCutterDeclined + goto_if_eq VAR_RESULT, NO, MoveTutor_EventScript_FuryCutterDeclined msgbox MoveTutor_Text_FuryCutterWhichMon, MSGBOX_DEFAULT setvar VAR_0x8005, TUTOR_MOVE_FURY_CUTTER call MoveTutor_EventScript_OpenPartyMenu - compare VAR_RESULT, 0 - goto_if_eq MoveTutor_EventScript_FuryCutterDeclined + goto_if_eq VAR_RESULT, 0, MoveTutor_EventScript_FuryCutterDeclined setflag FLAG_MOVE_TUTOR_TAUGHT_FURY_CUTTER goto MoveTutor_EventScript_FuryCutterTaught end @@ -90,16 +81,13 @@ LavaridgeTown_House_EventScript_MimicTutor:: faceplayer goto_if_set FLAG_MOVE_TUTOR_TAUGHT_MIMIC, MoveTutor_EventScript_MimicTaught msgbox MoveTutor_MimicTeach, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq MoveTutor_EventScript_MimicDeclined + goto_if_eq VAR_RESULT, NO, MoveTutor_EventScript_MimicDeclined call MoveTutor_EventScript_CanOnlyBeLearnedOnce - compare VAR_RESULT, NO - goto_if_eq MoveTutor_EventScript_MimicDeclined + goto_if_eq VAR_RESULT, NO, MoveTutor_EventScript_MimicDeclined msgbox MoveTutor_Text_MimicWhichMon, MSGBOX_DEFAULT setvar VAR_0x8005, TUTOR_MOVE_MIMIC call MoveTutor_EventScript_OpenPartyMenu - compare VAR_RESULT, 0 - goto_if_eq MoveTutor_EventScript_MimicDeclined + goto_if_eq VAR_RESULT, 0, MoveTutor_EventScript_MimicDeclined setflag FLAG_MOVE_TUTOR_TAUGHT_MIMIC goto MoveTutor_EventScript_MimicTaught end @@ -119,16 +107,13 @@ FallarborTown_Mart_EventScript_MetronomeTutor:: faceplayer goto_if_set FLAG_MOVE_TUTOR_TAUGHT_METRONOME, MoveTutor_EventScript_MetronomeTaught msgbox MoveTutor_Text_MetronomeTeach, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq MoveTutor_EventScript_MetronomeDeclined + goto_if_eq VAR_RESULT, NO, MoveTutor_EventScript_MetronomeDeclined call MoveTutor_EventScript_CanOnlyBeLearnedOnce - compare VAR_RESULT, NO - goto_if_eq MoveTutor_EventScript_MetronomeDeclined + goto_if_eq VAR_RESULT, NO, MoveTutor_EventScript_MetronomeDeclined msgbox MoveTutor_Text_MetronomeWhichMon, MSGBOX_DEFAULT setvar VAR_0x8005, TUTOR_MOVE_METRONOME call MoveTutor_EventScript_OpenPartyMenu - compare VAR_RESULT, 0 - goto_if_eq MoveTutor_EventScript_MetronomeDeclined + goto_if_eq VAR_RESULT, 0, MoveTutor_EventScript_MetronomeDeclined setflag FLAG_MOVE_TUTOR_TAUGHT_METRONOME goto MoveTutor_EventScript_MetronomeTaught end @@ -148,16 +133,13 @@ FortreeCity_House2_EventScript_SleepTalkTutor:: faceplayer goto_if_set FLAG_MOVE_TUTOR_TAUGHT_SLEEP_TALK, MoveTutor_EventScript_SleepTalkTaught msgbox MoveTutor_Text_SleepTalkTeach, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq MoveTutor_EventScript_SleepTalkDeclined + goto_if_eq VAR_RESULT, NO, MoveTutor_EventScript_SleepTalkDeclined call MoveTutor_EventScript_CanOnlyBeLearnedOnce - compare VAR_RESULT, NO - goto_if_eq MoveTutor_EventScript_SleepTalkDeclined + goto_if_eq VAR_RESULT, NO, MoveTutor_EventScript_SleepTalkDeclined msgbox MoveTutor_Text_SleepTalkWhichMon, MSGBOX_DEFAULT setvar VAR_0x8005, TUTOR_MOVE_SLEEP_TALK call MoveTutor_EventScript_OpenPartyMenu - compare VAR_RESULT, 0 - goto_if_eq MoveTutor_EventScript_SleepTalkDeclined + goto_if_eq VAR_RESULT, 0, MoveTutor_EventScript_SleepTalkDeclined setflag FLAG_MOVE_TUTOR_TAUGHT_SLEEP_TALK goto MoveTutor_EventScript_SleepTalkTaught end @@ -177,16 +159,13 @@ LilycoveCity_DepartmentStoreRooftop_EventScript_SubstituteTutor:: faceplayer goto_if_set FLAG_MOVE_TUTOR_TAUGHT_SUBSTITUTE, MoveTutor_EventScript_SubstituteTaught msgbox MoveTutor_Text_SubstituteTeach, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq MoveTutor_EventScript_SubstituteDeclined + goto_if_eq VAR_RESULT, NO, MoveTutor_EventScript_SubstituteDeclined call MoveTutor_EventScript_CanOnlyBeLearnedOnce - compare VAR_RESULT, NO - goto_if_eq MoveTutor_EventScript_SubstituteDeclined + goto_if_eq VAR_RESULT, NO, MoveTutor_EventScript_SubstituteDeclined msgbox MoveTutor_Text_SubstituteWhichMon, MSGBOX_DEFAULT setvar VAR_0x8005, TUTOR_MOVE_SUBSTITUTE call MoveTutor_EventScript_OpenPartyMenu - compare VAR_RESULT, 0 - goto_if_eq MoveTutor_EventScript_SubstituteDeclined + goto_if_eq VAR_RESULT, 0, MoveTutor_EventScript_SubstituteDeclined setflag FLAG_MOVE_TUTOR_TAUGHT_SUBSTITUTE goto MoveTutor_EventScript_SubstituteTaught end @@ -206,16 +185,13 @@ MossdeepCity_EventScript_DynamicPunchTutor:: faceplayer goto_if_set FLAG_MOVE_TUTOR_TAUGHT_DYNAMICPUNCH, MoveTutor_EventScript_DynamicPunchTaught msgbox MoveTutor_Text_DynamicPunchTeach, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq MoveTutor_EventScript_DynamicPunchDeclined + goto_if_eq VAR_RESULT, NO, MoveTutor_EventScript_DynamicPunchDeclined call MoveTutor_EventScript_CanOnlyBeLearnedOnce - compare VAR_RESULT, NO - goto_if_eq MoveTutor_EventScript_DynamicPunchDeclined + goto_if_eq VAR_RESULT, NO, MoveTutor_EventScript_DynamicPunchDeclined msgbox MoveTutor_Text_DynamicPunchWhichMon, MSGBOX_DEFAULT setvar VAR_0x8005, TUTOR_MOVE_DYNAMIC_PUNCH call MoveTutor_EventScript_OpenPartyMenu - compare VAR_RESULT, 0 - goto_if_eq MoveTutor_EventScript_DynamicPunchDeclined + goto_if_eq VAR_RESULT, 0, MoveTutor_EventScript_DynamicPunchDeclined setflag FLAG_MOVE_TUTOR_TAUGHT_DYNAMICPUNCH goto MoveTutor_EventScript_DynamicPunchTaught end @@ -235,16 +211,13 @@ SootopolisCity_PokemonCenter_1F_EventScript_DoubleEdgeTutor:: faceplayer goto_if_set FLAG_MOVE_TUTOR_TAUGHT_DOUBLE_EDGE, MoveTutor_EventScript_DoubleEdgeTaught msgbox MoveTutor_Text_DoubleEdgeTeach, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq MoveTutor_EventScript_DoubleEdgeDeclined + goto_if_eq VAR_RESULT, NO, MoveTutor_EventScript_DoubleEdgeDeclined call MoveTutor_EventScript_CanOnlyBeLearnedOnce - compare VAR_RESULT, NO - goto_if_eq MoveTutor_EventScript_DoubleEdgeDeclined + goto_if_eq VAR_RESULT, NO, MoveTutor_EventScript_DoubleEdgeDeclined msgbox MoveTutor_Text_DoubleEdgeWhichMon, MSGBOX_DEFAULT setvar VAR_0x8005, TUTOR_MOVE_DOUBLE_EDGE call MoveTutor_EventScript_OpenPartyMenu - compare VAR_RESULT, 0 - goto_if_eq MoveTutor_EventScript_DoubleEdgeDeclined + goto_if_eq VAR_RESULT, 0, MoveTutor_EventScript_DoubleEdgeDeclined setflag FLAG_MOVE_TUTOR_TAUGHT_DOUBLE_EDGE goto MoveTutor_EventScript_DoubleEdgeTaught end @@ -264,16 +237,13 @@ PacifidlogTown_PokemonCenter_1F_EventScript_ExplosionTutor:: faceplayer goto_if_set FLAG_MOVE_TUTOR_TAUGHT_EXPLOSION, MoveTutor_EventScript_ExplosionTaught msgbox MoveTutor_Text_ExplosionTeach, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq MoveTutor_EventScript_ExplosionDeclined + goto_if_eq VAR_RESULT, NO, MoveTutor_EventScript_ExplosionDeclined call MoveTutor_EventScript_CanOnlyBeLearnedOnce - compare VAR_RESULT, NO - goto_if_eq MoveTutor_EventScript_ExplosionDeclined + goto_if_eq VAR_RESULT, NO, MoveTutor_EventScript_ExplosionDeclined msgbox MoveTutor_Text_ExplosionWhichMon, MSGBOX_DEFAULT setvar VAR_0x8005, TUTOR_MOVE_EXPLOSION call MoveTutor_EventScript_OpenPartyMenu - compare VAR_RESULT, 0 - goto_if_eq MoveTutor_EventScript_ExplosionDeclined + goto_if_eq VAR_RESULT, 0, MoveTutor_EventScript_ExplosionDeclined setflag FLAG_MOVE_TUTOR_TAUGHT_EXPLOSION goto MoveTutor_EventScript_ExplosionTaught end diff --git a/data/scripts/obtain_item.inc b/data/scripts/obtain_item.inc index 382f5ce32..e982858e7 100644 --- a/data/scripts/obtain_item.inc +++ b/data/scripts/obtain_item.inc @@ -1,67 +1,63 @@ +.set ITEMID, VAR_0x8000 +.set AMOUNT, VAR_0x8001 + Std_ObtainItem:: - additem VAR_0x8000, VAR_0x8001 + additem ITEMID, AMOUNT copyvar VAR_0x8007, VAR_RESULT call EventScript_ObtainItemMessage return EventScript_ObtainItemMessage:: - bufferitemnameplural 1, VAR_0x8000, VAR_0x8001 - checkitemtype VAR_0x8000 + bufferitemnameplural STR_VAR_2, ITEMID, AMOUNT + checkitemtype ITEMID call EventScript_BufferPocketNameAndTryFanfare - compare VAR_0x8007, 1 - call_if_eq EventScript_ObtainedItem - compare VAR_0x8007, 0 - call_if_eq EventScript_NoRoomForItem + call_if_eq VAR_0x8007, TRUE, EventScript_ObtainedItem + call_if_eq VAR_0x8007, FALSE, EventScript_NoRoomForItem return EventScript_BufferPocketNameAndTryFanfare:: switch VAR_RESULT - case POCKET_ITEMS, EventScript_BufferItemsPocket - case POCKET_KEY_ITEMS, EventScript_BufferKeyItemsPocket + 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 + case POCKET_TM_HM, EventScript_BufferTMHMsPocket + case POCKET_BERRIES, EventScript_BufferBerriesPocket end EventScript_BufferItemsPocket:: - bufferstdstring 2, STDSTRING_ITEMS - compare VAR_0x8007, 1 - call_if_eq EventScript_PlayFanfareObtainedItem + bufferstdstring STR_VAR_3, STDSTRING_ITEMS + call_if_eq VAR_0x8007, TRUE, EventScript_PlayFanfareObtainedItem return EventScript_BufferKeyItemsPocket:: - bufferstdstring 2, STDSTRING_KEYITEMS - compare VAR_0x8007, 1 - call_if_eq EventScript_PlayFanfareObtainedItem + bufferstdstring STR_VAR_3, STDSTRING_KEYITEMS + call_if_eq VAR_0x8007, TRUE, EventScript_PlayFanfareObtainedItem return EventScript_BufferPokeballsPocket:: - bufferstdstring 2, STDSTRING_POKEBALLS - compare VAR_0x8007, 1 - call_if_eq EventScript_PlayFanfareObtainedItem + bufferstdstring STR_VAR_3, STDSTRING_POKEBALLS + call_if_eq VAR_0x8007, TRUE, EventScript_PlayFanfareObtainedItem return EventScript_BufferTMHMsPocket:: - bufferstdstring 2, STDSTRING_TMHMS - compare VAR_0x8007, 1 - call_if_eq EventScript_PlayFanfareObtainedTMHM + bufferstdstring STR_VAR_3, STDSTRING_TMHMS + call_if_eq VAR_0x8007, TRUE, EventScript_PlayFanfareObtainedTMHM return EventScript_BufferBerriesPocket:: - bufferstdstring 2, STDSTRING_BERRIES - compare VAR_0x8007, 1 - call_if_eq EventScript_PlayFanfareObtainedItem + bufferstdstring STR_VAR_3, STDSTRING_BERRIES + call_if_eq VAR_0x8007, TRUE, EventScript_PlayFanfareObtainedItem return EventScript_ObtainedItem:: message gText_ObtainedTheItem waitfanfare msgbox gText_PutItemInPocket, MSGBOX_DEFAULT - setvar VAR_RESULT, 1 + setvar VAR_RESULT, TRUE return EventScript_NoRoomForItem:: - setvar VAR_RESULT, 0 + setvar VAR_RESULT, FALSE return EventScript_PlayFanfareObtainedItem:: @@ -73,17 +69,15 @@ EventScript_PlayFanfareObtainedTMHM:: return Std_ObtainDecoration:: - adddecoration VAR_0x8000 + adddecoration ITEMID copyvar VAR_0x8007, VAR_RESULT call EventScript_ObtainDecorationMessage return EventScript_ObtainDecorationMessage:: - bufferdecorationname 1, VAR_0x8000 - compare VAR_0x8007, 1 - call_if_eq EventScript_ObtainedDecor - compare VAR_0x8007, 0 - call_if_eq EventScript_NoRoomForDecor + bufferdecorationname STR_VAR_2, ITEMID + call_if_eq VAR_0x8007, TRUE, EventScript_ObtainedDecor + call_if_eq VAR_0x8007, FALSE, EventScript_NoRoomForDecor return EventScript_ObtainedDecor:: @@ -91,28 +85,26 @@ EventScript_ObtainedDecor:: message gText_ObtainedTheDecor waitfanfare msgbox gText_TheDecorWasTransferredToThePC, MSGBOX_DEFAULT - setvar VAR_RESULT, 1 + setvar VAR_RESULT, TRUE return EventScript_NoRoomForDecor:: - setvar VAR_RESULT, 0 + setvar VAR_RESULT, FALSE return Std_FindItem:: lock faceplayer waitse - copyvar VAR_0x8004, VAR_0x8000 - copyvar VAR_0x8005, VAR_0x8001 - checkitemspace VAR_0x8000, VAR_0x8001 + copyvar VAR_0x8004, ITEMID + copyvar VAR_0x8005, AMOUNT + checkitemspace ITEMID, AMOUNT copyvar VAR_0x8007, VAR_RESULT - bufferitemnameplural 1, VAR_0x8000, VAR_0x8001 - checkitemtype VAR_0x8000 + bufferitemnameplural STR_VAR_2, ITEMID, AMOUNT + checkitemtype ITEMID call EventScript_BufferPocketNameAndTryFanfare - compare VAR_0x8007, 1 - call_if_eq EventScript_PickUpItem - compare VAR_0x8007, 0 - call_if_eq EventScript_NoRoomToPickUpItem + call_if_eq VAR_0x8007, TRUE, EventScript_PickUpItem + call_if_eq VAR_0x8007, FALSE, EventScript_NoRoomToPickUpItem release return @@ -121,16 +113,13 @@ EventScript_PickUpItem:: additem VAR_0x8004, VAR_0x8005 specialvar VAR_RESULT, BufferTMHMMoveName copyvar VAR_0x8008, VAR_RESULT - compare VAR_0x8008, 1 - call_if_eq EventScript_FoundTMHM - compare VAR_0x8008, 0 - call_if_eq EventScript_FoundItem + call_if_eq VAR_0x8008, TRUE, EventScript_FoundTMHM + call_if_eq VAR_0x8008, FALSE, EventScript_FoundItem waitfanfare waitmessage - bufferitemnameplural 1, VAR_0x8004, VAR_0x8005 + bufferitemnameplural STR_VAR_2, VAR_0x8004, VAR_0x8005 pyramid_inchallenge - compare VAR_RESULT, 1 - goto_if_eq EventScript_PutBattlePyramidItemInBag + goto_if_eq VAR_RESULT, TRUE, EventScript_PutBattlePyramidItemInBag msgbox gText_PutItemInPocket, MSGBOX_DEFAULT return @@ -139,7 +128,7 @@ EventScript_PutBattlePyramidItemInBag:: return EventScript_FoundTMHM:: - bufferitemnameplural 0, VAR_0x8004, VAR_0x8005 + bufferitemnameplural STR_VAR_1, VAR_0x8004, VAR_0x8005 message gText_PlayerFoundOneTMHM return @@ -150,7 +139,7 @@ EventScript_FoundItem:: EventScript_NoRoomToPickUpItem:: msgbox gText_ObtainedTheItem, MSGBOX_DEFAULT msgbox gText_TooBadBagIsFull, MSGBOX_DEFAULT - setvar VAR_RESULT, 0 + setvar VAR_RESULT, FALSE return EventScript_HiddenItemScript:: @@ -158,27 +147,23 @@ EventScript_HiddenItemScript:: waitse additem VAR_0x8005 copyvar VAR_0x8007, VAR_RESULT - bufferitemnameplural 1, VAR_0x8005, 1 + bufferitemnameplural STR_VAR_2, VAR_0x8005, 1 checkitemtype VAR_0x8005 call EventScript_BufferPocketNameAndTryFanfare - compare VAR_0x8007, 1 - goto_if_eq EventScript_PickUpHiddenItem - compare VAR_0x8007, 0 - goto_if_eq EventScript_NoRoomForHiddenItem + goto_if_eq VAR_0x8007, TRUE, EventScript_PickUpHiddenItem + goto_if_eq VAR_0x8007, FALSE, EventScript_NoRoomForHiddenItem end EventScript_PickUpHiddenItem:: copyvar VAR_0x8008, VAR_0x8004 copyvar VAR_0x8004, VAR_0x8005 specialvar VAR_RESULT, BufferTMHMMoveName - compare VAR_RESULT, 1 - goto_if_eq EventScript_FoundHiddenTMHM - compare VAR_RESULT, 0 - goto_if_eq EventScript_FoundHiddenItem + goto_if_eq VAR_RESULT, TRUE, EventScript_FoundHiddenTMHM + goto_if_eq VAR_RESULT, FALSE, EventScript_FoundHiddenItem end EventScript_FoundHiddenTMHM:: - bufferitemnameplural 0, VAR_0x8004, 1 + bufferitemnameplural STR_VAR_1, VAR_0x8004, 1 message gText_PlayerFoundOneTMHM goto EventScript_PutHiddenItemInPocket end @@ -191,7 +176,7 @@ EventScript_FoundHiddenItem:: EventScript_PutHiddenItemInPocket:: waitmessage waitfanfare - bufferitemnameplural 1, VAR_0x8004, 1 + bufferitemnameplural STR_VAR_2, VAR_0x8004, 1 copyvar VAR_0x8004, VAR_0x8008 msgbox gText_PutItemInPocket, MSGBOX_DEFAULT special TryPutTreasureInvestigatorsOnAir diff --git a/data/scripts/pc_transfer.inc b/data/scripts/pc_transfer.inc index 1fe575d55..1204bece3 100644 --- a/data/scripts/pc_transfer.inc +++ b/data/scripts/pc_transfer.inc @@ -14,35 +14,33 @@ Common_EventScript_NameReceivedBoxMon:: return Common_EventScript_TransferredToPC:: - bufferboxname 0, VAR_PC_BOX_TO_SEND_MON - bufferspeciesname 1, VAR_TEMP_1 + bufferboxname STR_VAR_1, VAR_PC_BOX_TO_SEND_MON + bufferspeciesname STR_VAR_2, VAR_TEMP_1 call_if_unset FLAG_SYS_PC_LANETTE, EventScript_TransferredSomeonesPC call_if_set FLAG_SYS_PC_LANETTE, EventScript_TransferredLanettesPC return EventScript_TransferredSomeonesPC:: specialvar VAR_RESULT, ShouldShowBoxWasFullMessage - compare VAR_RESULT, 1 - goto_if_eq EventScript_SomeonesPCBoxFull + goto_if_eq VAR_RESULT, TRUE, EventScript_SomeonesPCBoxFull msgbox gText_PkmnTransferredSomeonesPC, MSGBOX_DEFAULT return EventScript_SomeonesPCBoxFull:: specialvar VAR_RESULT, GetPCBoxToSendMon - bufferboxname 2, VAR_RESULT + bufferboxname STR_VAR_3, VAR_RESULT msgbox gText_PkmnTransferredSomeonesPCBoxFull, MSGBOX_DEFAULT return EventScript_TransferredLanettesPC:: specialvar VAR_RESULT, ShouldShowBoxWasFullMessage - compare VAR_RESULT, TRUE - goto_if_eq EventScript_LanettesPCBoxFull + goto_if_eq VAR_RESULT, TRUE, EventScript_LanettesPCBoxFull msgbox gText_PkmnTransferredLanettesPC, MSGBOX_DEFAULT return EventScript_LanettesPCBoxFull:: specialvar VAR_RESULT, GetPCBoxToSendMon - bufferboxname 2, VAR_RESULT + bufferboxname STR_VAR_3, VAR_RESULT msgbox gText_PkmnTransferredLanettesPCBoxFull, MSGBOX_DEFAULT return diff --git a/data/scripts/pkmn_center_nurse.inc b/data/scripts/pkmn_center_nurse.inc index 21f2abe0a..64ccdfa77 100644 --- a/data/scripts/pkmn_center_nurse.inc +++ b/data/scripts/pkmn_center_nurse.inc @@ -1,135 +1,122 @@ Common_EventScript_PkmnCenterNurse:: - lock - faceplayer - setvar VAR_0x8004, 0 - specialvar VAR_RESULT, CountPlayerTrainerStars - compare VAR_RESULT, 4 - goto_if_eq EventScript_PkmnCenterNurse_GoldCard - msgbox gText_WouldYouLikeToRestYourPkmn, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq EventScript_PkmnCenterNurse_HealPkmn - compare VAR_RESULT, NO - goto_if_eq EventScript_PkmnCenterNurse_Goodbye - end + lock + faceplayer + setvar VAR_0x8004, 0 + specialvar VAR_RESULT, CountPlayerTrainerStars + goto_if_eq VAR_RESULT, 4, EventScript_PkmnCenterNurse_GoldCard + msgbox gText_WouldYouLikeToRestYourPkmn, MSGBOX_YESNO + goto_if_eq VAR_RESULT, YES, EventScript_PkmnCenterNurse_HealPkmn + goto_if_eq VAR_RESULT, NO, EventScript_PkmnCenterNurse_Goodbye + end EventScript_PkmnCenterNurse_Goodbye:: - message gText_WeHopeToSeeYouAgain - return + message gText_WeHopeToSeeYouAgain + return @ VAR_0x8004 is 1 when player has Gold Card; jumps are identical EventScript_PkmnCenterNurse_HealPkmn:: - incrementgamestat GAME_STAT_USED_POKECENTER - compare VAR_0x8004, 0 - call_if_eq EventScript_PkmnCenterNurse_IllTakeYourPkmn - compare VAR_0x8004, 1 - call_if_eq EventScript_PkmnCenterNurse_IllTakeYourPkmn2 - waitmessage - call EventScript_PkmnCenterNurse_TakeAndHealPkmn - goto_if_unset FLAG_POKERUS_EXPLAINED, EventScript_PkmnCenterNurse_CheckPokerus - goto EventScript_PkmnCenterNurse_CheckTrainerHillAndUnionRoom - end + incrementgamestat GAME_STAT_USED_POKECENTER + call_if_eq VAR_0x8004, 0, EventScript_PkmnCenterNurse_IllTakeYourPkmn + call_if_eq VAR_0x8004, 1, EventScript_PkmnCenterNurse_IllTakeYourPkmn2 + waitmessage + call EventScript_PkmnCenterNurse_TakeAndHealPkmn + goto_if_unset FLAG_POKERUS_EXPLAINED, EventScript_PkmnCenterNurse_CheckPokerus + goto EventScript_PkmnCenterNurse_CheckTrainerHillAndUnionRoom + end EventScript_PkmnCenterNurse_IllTakeYourPkmn:: - message gText_IllTakeYourPkmn - return + message gText_IllTakeYourPkmn + return EventScript_PkmnCenterNurse_IllTakeYourPkmn2:: - message gText_IllTakeYourPkmn2 - return + message gText_IllTakeYourPkmn2 + return EventScript_PkmnCenterNurse_TakeAndHealPkmn:: - applymovement VAR_0x800B, Common_Movement_WalkInPlaceFasterLeft - waitmovement 0 - dofieldeffect FLDEFF_POKECENTER_HEAL - waitfieldeffect FLDEFF_POKECENTER_HEAL - applymovement VAR_0x800B, Common_Movement_WalkInPlaceFasterDown - waitmovement 0 - special HealPlayerParty - return + applymovement VAR_0x800B, Common_Movement_WalkInPlaceFasterLeft + waitmovement 0 + dofieldeffect FLDEFF_POKECENTER_HEAL + waitfieldeffect FLDEFF_POKECENTER_HEAL + applymovement VAR_0x800B, Common_Movement_WalkInPlaceFasterDown + waitmovement 0 + special HealPlayerParty + return EventScript_PkmnCenterNurse_CheckTrainerHillAndUnionRoom:: - specialvar VAR_RESULT, PlayerNotAtTrainerHillEntrance - compare VAR_RESULT, 0 - goto_if_eq EventScript_PkmnCenterNurse_ReturnPkmn - specialvar VAR_RESULT, BufferUnionRoomPlayerName - copyvar VAR_0x8008, VAR_RESULT - compare VAR_0x8008, 0 - goto_if_eq EventScript_PkmnCenterNurse_ReturnPkmn - compare VAR_0x8008, 1 - goto_if_eq EventScript_PkmnCenterNurse_PlayerWaitingInUnionRoom - end + specialvar VAR_RESULT, PlayerNotAtTrainerHillEntrance + goto_if_eq VAR_RESULT, 0, EventScript_PkmnCenterNurse_ReturnPkmn + specialvar VAR_RESULT, BufferUnionRoomPlayerName + copyvar VAR_0x8008, VAR_RESULT + goto_if_eq VAR_0x8008, 0, EventScript_PkmnCenterNurse_ReturnPkmn + goto_if_eq VAR_0x8008, 1, EventScript_PkmnCenterNurse_PlayerWaitingInUnionRoom + end @ VAR_0x8004 is 1 when player has Gold Card EventScript_PkmnCenterNurse_ReturnPkmn:: - compare VAR_0x8004, 1 - goto_if_eq EventScript_PkmnCenterNurse_ReturnPkmn2 - message gText_RestoredPkmnToFullHealth - waitmessage - applymovement VAR_0x800B, Movement_PkmnCenterNurse_Bow - waitmovement 0 - message gText_WeHopeToSeeYouAgain - return + goto_if_eq VAR_0x8004, 1, EventScript_PkmnCenterNurse_ReturnPkmn2 + message gText_RestoredPkmnToFullHealth + waitmessage + applymovement VAR_0x800B, Movement_PkmnCenterNurse_Bow + waitmovement 0 + message gText_WeHopeToSeeYouAgain + return EventScript_PkmnCenterNurse_ReturnPkmn2:: - message gText_ThankYouForWaiting - waitmessage - applymovement VAR_0x800B, Movement_PkmnCenterNurse_Bow - waitmovement 0 - message gText_WeHopeToSeeYouAgain2 - return + message gText_ThankYouForWaiting + waitmessage + applymovement VAR_0x800B, Movement_PkmnCenterNurse_Bow + waitmovement 0 + message gText_WeHopeToSeeYouAgain2 + return EventScript_PkmnCenterNurse_PlayerWaitingInUnionRoom:: - goto_if_set FLAG_NURSE_UNION_ROOM_REMINDER, EventScript_PkmnCenterNurse_ReturnPkmn - msgbox gText_RestoredPkmnToFullHealth, MSGBOX_DEFAULT - setflag FLAG_NURSE_UNION_ROOM_REMINDER - message CableClub_Text_PlayerIsWaiting - waitmessage - applymovement VAR_0x800B, Movement_PkmnCenterNurse_Bow - waitmovement 0 - message gText_WeHopeToSeeYouAgain - return + goto_if_set FLAG_NURSE_UNION_ROOM_REMINDER, EventScript_PkmnCenterNurse_ReturnPkmn + msgbox gText_RestoredPkmnToFullHealth, MSGBOX_DEFAULT + setflag FLAG_NURSE_UNION_ROOM_REMINDER + message CableClub_Text_PlayerIsWaiting + waitmessage + applymovement VAR_0x800B, Movement_PkmnCenterNurse_Bow + waitmovement 0 + message gText_WeHopeToSeeYouAgain + return EventScript_PkmnCenterNurse_CheckPokerus:: - specialvar VAR_RESULT, IsPokerusInParty - compare VAR_RESULT, TRUE - goto_if_eq EventScript_PkmnCenterNurse_ExplainPokerus - compare VAR_RESULT, FALSE - goto_if_eq EventScript_PkmnCenterNurse_CheckTrainerHillAndUnionRoom - end + specialvar VAR_RESULT, IsPokerusInParty + goto_if_eq VAR_RESULT, TRUE, EventScript_PkmnCenterNurse_ExplainPokerus + goto_if_eq VAR_RESULT, FALSE, EventScript_PkmnCenterNurse_CheckTrainerHillAndUnionRoom + end EventScript_PkmnCenterNurse_ExplainPokerus:: - message gText_PokerusExplanation - setflag FLAG_POKERUS_EXPLAINED - return + message gText_PokerusExplanation + setflag FLAG_POKERUS_EXPLAINED + return EventScript_PkmnCenterNurse_GoldCard:: - goto_if_set FLAG_NURSE_MENTIONS_GOLD_CARD, EventScript_PkmnCenterNurse_AskForUsual - setflag FLAG_NURSE_MENTIONS_GOLD_CARD - msgbox gText_WelcomeCutShort, MSGBOX_DEFAULT - playse SE_PIN - applymovement VAR_0x800B, Common_Movement_ExclamationMark - waitmovement 0 - applymovement VAR_0x800B, Common_Movement_Delay48 - waitmovement 0 - msgbox gText_NoticesGoldCard, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq EventScript_PkmnCenterNurse_GoldCardHealPkmn - message gText_WeHopeToSeeYouAgain2 - return + goto_if_set FLAG_NURSE_MENTIONS_GOLD_CARD, EventScript_PkmnCenterNurse_AskForUsual + setflag FLAG_NURSE_MENTIONS_GOLD_CARD + msgbox gText_WelcomeCutShort, MSGBOX_DEFAULT + playse SE_PIN + applymovement VAR_0x800B, Common_Movement_ExclamationMark + waitmovement 0 + applymovement VAR_0x800B, Common_Movement_Delay48 + waitmovement 0 + msgbox gText_NoticesGoldCard, MSGBOX_YESNO + goto_if_eq VAR_RESULT, YES, EventScript_PkmnCenterNurse_GoldCardHealPkmn + message gText_WeHopeToSeeYouAgain2 + return EventScript_PkmnCenterNurse_AskForUsual:: - msgbox gText_YouWantTheUsual, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq EventScript_PkmnCenterNurse_GoldCardHealPkmn - message gText_WeHopeToSeeYouAgain2 - return + msgbox gText_YouWantTheUsual, MSGBOX_YESNO + goto_if_eq VAR_RESULT, YES, EventScript_PkmnCenterNurse_GoldCardHealPkmn + message gText_WeHopeToSeeYouAgain2 + return EventScript_PkmnCenterNurse_GoldCardHealPkmn:: - setvar VAR_0x8004, 1 - goto EventScript_PkmnCenterNurse_HealPkmn - end + setvar VAR_0x8004, 1 + goto EventScript_PkmnCenterNurse_HealPkmn + end Movement_PkmnCenterNurse_Bow: - nurse_joy_bow - delay_4 - step_end + nurse_joy_bow + delay_4 + step_end diff --git a/data/scripts/players_house.inc b/data/scripts/players_house.inc index e2e985a7a..caa4e6955 100644 --- a/data/scripts/players_house.inc +++ b/data/scripts/players_house.inc @@ -11,10 +11,8 @@ PlayersHouse_1F_EventScript_EnterHouseMovingIn:: msgbox PlayersHouse_1F_Text_IsntItNiceInHere, MSGBOX_DEFAULT applymovement VAR_0x8004, Common_Movement_FacePlayer waitmovement 0 - compare VAR_0x8005, MALE - call_if_eq PlayersHouse_1F_EventScript_MomFacePlayerMovingInMale - compare VAR_0x8005, FEMALE - call_if_eq PlayersHouse_1F_EventScript_MomFacePlayerMovingInFemale + call_if_eq VAR_0x8005, MALE, PlayersHouse_1F_EventScript_MomFacePlayerMovingInMale + call_if_eq VAR_0x8005, FEMALE, PlayersHouse_1F_EventScript_MomFacePlayerMovingInFemale msgbox PlayersHouse_1F_Text_MoversPokemonGoSetClock, MSGBOX_DEFAULT closemessage setvar VAR_LITTLEROOT_INTRO_STATE, 4 @@ -69,10 +67,8 @@ PlayersHouse_2F_EventScript_WallClock:: setflag FLAG_HIDE_LITTLEROOT_TOWN_PLAYERS_HOUSE_VIGOROTH_1 setflag FLAG_HIDE_LITTLEROOT_TOWN_PLAYERS_HOUSE_VIGOROTH_2 checkplayergender - compare VAR_RESULT, MALE - call_if_eq PlayersHouse_2F_EventScript_MomComesUpstairsMale - compare VAR_RESULT, FEMALE - call_if_eq PlayersHouse_2F_EventScript_MomComesUpstairsFemale + call_if_eq VAR_RESULT, MALE, PlayersHouse_2F_EventScript_MomComesUpstairsMale + call_if_eq VAR_RESULT, FEMALE, PlayersHouse_2F_EventScript_MomComesUpstairsFemale playse SE_EXIT removeobject VAR_0x8008 releaseall @@ -310,16 +306,12 @@ PlayersHouse_1F_Movement_MomReturnToSeatFemale: PlayersHouse_1F_EventScript_Mom:: lock faceplayer - compare VAR_LITTLEROOT_HOUSES_STATE_MAY, 4 - goto_if_eq PlayersHouse_1F_EventScript_DontPushYourselfTooHard - compare VAR_LITTLEROOT_HOUSES_STATE_BRENDAN, 4 - goto_if_eq PlayersHouse_1F_EventScript_DontPushYourselfTooHard + goto_if_eq VAR_LITTLEROOT_HOUSES_STATE_MAY, 4, PlayersHouse_1F_EventScript_DontPushYourselfTooHard + goto_if_eq VAR_LITTLEROOT_HOUSES_STATE_BRENDAN, 4, PlayersHouse_1F_EventScript_DontPushYourselfTooHard goto_if_set FLAG_HAS_MATCH_CALL, PlayersHouse_1F_EventScript_TryRegisterMom goto_if_set FLAG_RESCUED_BIRCH, PlayersHouse_1F_EventScript_MomHealsParty - compare VAR_TEMP_1, 1 - goto_if_eq PlayersHouse_1F_EventScript_SeeYouHoney - compare VAR_LITTLEROOT_INTRO_STATE, 7 - goto_if_eq PlayersHouse_1F_EventScript_DidYouMeetProfBirch + goto_if_eq VAR_TEMP_1, 1, PlayersHouse_1F_EventScript_SeeYouHoney + goto_if_eq VAR_LITTLEROOT_INTRO_STATE, 7, PlayersHouse_1F_EventScript_DidYouMeetProfBirch msgbox PlayersHouse_1F_Text_IsntItNiceInHere, MSGBOX_DEFAULT release end @@ -351,8 +343,7 @@ PlayersHouse_1F_EventScript_TryGiveAmuletCoin:: goto_if_set FLAG_RECEIVED_AMULET_COIN, PlayersHouse_1F_EventScript_MomHealsParty msgbox PlayersHouse_1F_Text_GotDadsBadgeHeresSomethingFromMom, MSGBOX_DEFAULT giveitem ITEM_AMULET_COIN - compare VAR_RESULT, FALSE - goto_if_eq Common_EventScript_ShowBagIsFull + goto_if_eq VAR_RESULT, FALSE, Common_EventScript_ShowBagIsFull msgbox PlayersHouse_1F_Text_DontPushYourselfTooHard, MSGBOX_DEFAULT setflag FLAG_RECEIVED_AMULET_COIN release @@ -432,14 +423,10 @@ PlayersHouse_1F_Movement_MovePlayerAwayFromDoor: PlayersHouse_1F_EventScript_GetSSTicketAndSeeLatiTV:: lockall checkplayergender - compare VAR_RESULT, MALE - call_if_eq PlayersHouse_1F_EventScript_SetUpObjectEventVarsMale - compare VAR_RESULT, FEMALE - call_if_eq PlayersHouse_1F_EventScript_SetUpObjectEventVarsFemale - compare VAR_0x8008, MALE - call_if_eq PlayersHouse_1F_EventScript_PlayerEnterRoomMale - compare VAR_0x8008, FEMALE - call_if_eq PlayersHouse_1F_EventScript_PlayerEnterRoomFemale + call_if_eq VAR_RESULT, MALE, PlayersHouse_1F_EventScript_SetUpObjectEventVarsMale + call_if_eq VAR_RESULT, FEMALE, PlayersHouse_1F_EventScript_SetUpObjectEventVarsFemale + call_if_eq VAR_0x8008, MALE, PlayersHouse_1F_EventScript_PlayerEnterRoomMale + call_if_eq VAR_0x8008, FEMALE, PlayersHouse_1F_EventScript_PlayerEnterRoomFemale applymovement VAR_0x8009, Common_Movement_FacePlayer waitmovement 0 playse SE_PIN @@ -448,58 +435,44 @@ PlayersHouse_1F_EventScript_GetSSTicketAndSeeLatiTV:: applymovement VAR_0x8009, Common_Movement_Delay48 waitmovement 0 delay 20 - compare VAR_0x8008, MALE - call_if_eq PlayersHouse_1F_EventScript_DadApproachPlayerMale - compare VAR_0x8008, FEMALE - call_if_eq PlayersHouse_1F_EventScript_DadApproachPlayerFemale + call_if_eq VAR_0x8008, MALE, PlayersHouse_1F_EventScript_DadApproachPlayerMale + call_if_eq VAR_0x8008, FEMALE, PlayersHouse_1F_EventScript_DadApproachPlayerFemale msgbox PlayersHouse_1F_Text_TicketFromBrineyCameForYou, MSGBOX_DEFAULT giveitem ITEM_SS_TICKET msgbox PlayersHouse_1F_Text_PortsInSlateportLilycove, MSGBOX_DEFAULT closemessage delay 20 - compare VAR_0x8008, MALE - call_if_eq PlayersHouse_1F_EventScript_MomApproachDadMale - compare VAR_0x8008, FEMALE - call_if_eq PlayersHouse_1F_EventScript_MomApproachDadFemale + call_if_eq VAR_0x8008, MALE, PlayersHouse_1F_EventScript_MomApproachDadMale + call_if_eq VAR_0x8008, FEMALE, PlayersHouse_1F_EventScript_MomApproachDadFemale msgbox PlayersHouse_1F_Text_BetterGetBackToGym, MSGBOX_DEFAULT closemessage - compare VAR_0x8008, MALE - call_if_eq PlayersHouse_1F_EventScript_DadExitsMale - compare VAR_0x8008, FEMALE - call_if_eq PlayersHouse_1F_EventScript_DadExitsFemale + call_if_eq VAR_0x8008, MALE, PlayersHouse_1F_EventScript_DadExitsMale + call_if_eq VAR_0x8008, FEMALE, PlayersHouse_1F_EventScript_DadExitsFemale playse SE_DOOR removeobject VAR_0x8009 setflag FLAG_RECEIVED_SS_TICKET delay 30 - compare VAR_0x8008, MALE - call_if_eq PlayersHouse_1F_EventScript_MomApproachPlayerMale - compare VAR_0x8008, FEMALE - call_if_eq PlayersHouse_1F_EventScript_MomApproachPlayerFemale + call_if_eq VAR_0x8008, MALE, PlayersHouse_1F_EventScript_MomApproachPlayerMale + call_if_eq VAR_0x8008, FEMALE, PlayersHouse_1F_EventScript_MomApproachPlayerFemale delay 20 msgbox PlayersHouse_1F_Text_DadShouldStayLonger, MSGBOX_DEFAULT closemessage setflag FLAG_SYS_TV_LATIAS_LATIOS special TurnOnTVScreen delay 60 - compare VAR_0x8008, MALE - call_if_eq PlayersHouse_1F_EventScript_MomNoticesLatiBroadcastMale - compare VAR_0x8008, FEMALE - call_if_eq PlayersHouse_1F_EventScript_MomNoticesLatiBroadcastFemale + call_if_eq VAR_0x8008, MALE, PlayersHouse_1F_EventScript_MomNoticesLatiBroadcastMale + call_if_eq VAR_0x8008, FEMALE, PlayersHouse_1F_EventScript_MomNoticesLatiBroadcastFemale msgbox PlayersHouse_1F_Text_IsThatABreakingStory, MSGBOX_DEFAULT closemessage - compare VAR_0x8008, MALE - call_if_eq PlayersHouse_1F_EventScript_PlayerApproachTVForLatiMale - compare VAR_0x8008, FEMALE - call_if_eq PlayersHouse_1F_EventScript_PlayerApproachTVForLatiFemale + call_if_eq VAR_0x8008, MALE, PlayersHouse_1F_EventScript_PlayerApproachTVForLatiMale + call_if_eq VAR_0x8008, FEMALE, PlayersHouse_1F_EventScript_PlayerApproachTVForLatiFemale msgbox PlayersHouse_1F_Text_LatiEmergencyNewsFlash, MSGBOX_DEFAULT closemessage clearflag FLAG_SYS_TV_LATIAS_LATIOS setflag FLAG_LATIOS_OR_LATIAS_ROAMING special TurnOffTVScreen - compare VAR_0x8008, MALE - call_if_eq PlayersHouse_1F_EventScript_MomApproachPlayerAfterTVMale - compare VAR_0x8008, FEMALE - call_if_eq PlayersHouse_1F_EventScript_MomApproachPlayerAfterTVFemale + call_if_eq VAR_0x8008, MALE, PlayersHouse_1F_EventScript_MomApproachPlayerAfterTVMale + call_if_eq VAR_0x8008, FEMALE, PlayersHouse_1F_EventScript_MomApproachPlayerAfterTVFemale msgbox PlayersHouse_1F_Text_WhatColorDidTheySay, MSGBOX_DEFAULT multichoice 22, 8, MULTI_TV_LATI, TRUE copyvar VAR_0x8004, VAR_RESULT diff --git a/data/scripts/prof_birch.inc b/data/scripts/prof_birch.inc index 7eb1730fc..38a5dfec3 100644 --- a/data/scripts/prof_birch.inc +++ b/data/scripts/prof_birch.inc @@ -1,23 +1,14 @@ ProfBirch_EventScript_UpdateLocation:: - compare VAR_PETALBURG_GYM_STATE, 0 - goto_if_eq Common_EventScript_NopReturn + goto_if_eq VAR_PETALBURG_GYM_STATE, 0, Common_EventScript_NopReturn goto_if_set FLAG_SYS_GAME_CLEAR, ProfBirch_EventScript_MoveToLab - 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 + call_if_eq VAR_BIRCH_STATE, 0, ProfBirch_EventScript_MoveToLab + call_if_eq VAR_BIRCH_STATE, 1, ProfBirch_EventScript_MoveToLab + call_if_eq VAR_BIRCH_STATE, 2, ProfBirch_EventScript_MoveToRoute101 + call_if_eq VAR_BIRCH_STATE, 3, ProfBirch_EventScript_MoveToRoute101 + call_if_eq VAR_BIRCH_STATE, 4, ProfBirch_EventScript_MoveToRoute103 + call_if_eq VAR_BIRCH_STATE, 5, ProfBirch_EventScript_MoveToRoute103 + call_if_eq VAR_BIRCH_STATE, 6, ProfBirch_EventScript_MoveToLab + call_if_eq VAR_BIRCH_STATE, 7, ProfBirch_EventScript_MoveToLab return ProfBirch_EventScript_MoveToLab:: @@ -49,8 +40,7 @@ ProfBirch_EventScript_RatePokedexOrRegister:: ProfBirch_EventScript_AskRatePokedex:: msgbox gBirchDexRatingText_AreYouCurious, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq ProfBirch_EventScript_DeclineRating + goto_if_eq VAR_RESULT, NO, ProfBirch_EventScript_DeclineRating call ProfBirch_EventScript_RatePokedex release end @@ -73,17 +63,16 @@ ProfBirch_EventScript_RatePokedex:: 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 + buffernumberstring STR_VAR_1, VAR_0x8008 @ Num Hoenn seen + buffernumberstring STR_VAR_2, VAR_0x8009 @ Num Hoenn caught msgbox gBirchDexRatingText_SoYouveSeenAndCaught, MSGBOX_DEFAULT call ProfBirch_EventScript_ShowRatingMessage - compare VAR_0x800A, 0 - goto_if_eq Common_EventScript_NopReturn @ National dex not enabled + goto_if_eq VAR_0x800A, 0, Common_EventScript_NopReturn @ 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 + buffernumberstring STR_VAR_1, VAR_0x8008 @ Num National seen + buffernumberstring STR_VAR_2, VAR_0x8009 @ Num National caught msgbox gBirchDexRatingText_OnANationwideBasis, MSGBOX_DEFAULT return diff --git a/data/scripts/profile_man.inc b/data/scripts/profile_man.inc index 2c5b16122..4acf049bd 100644 --- a/data/scripts/profile_man.inc +++ b/data/scripts/profile_man.inc @@ -28,10 +28,8 @@ ProfileMan_EventScript_CreateProfile:: call Common_ShowEasyChatScreen lock faceplayer - compare VAR_RESULT, 0 - goto_if_eq ProfileMan_EventScript_CancelShowProfile - compare VAR_RESULT, 1 - goto_if_eq ProfileMan_EventScript_ShowProfile + goto_if_eq VAR_RESULT, 0, ProfileMan_EventScript_CancelShowProfile + goto_if_eq VAR_RESULT, 1, ProfileMan_EventScript_ShowProfile end ProfileMan_EventScript_CancelShowProfile:: @@ -80,10 +78,8 @@ ProfileMan_EventScript_CreateNewProfile:: call Common_ShowEasyChatScreen lock faceplayer - compare VAR_RESULT, 0 - goto_if_eq ProfileMan_EventScript_CancelShowProfile - compare VAR_RESULT, 1 - goto_if_eq ProfileMan_EventScript_ShowProfile + goto_if_eq VAR_RESULT, 0, ProfileMan_EventScript_CancelShowProfile + goto_if_eq VAR_RESULT, 1, ProfileMan_EventScript_ShowProfile end ProfileMan_EventScript_DeclineNewProfile:: diff --git a/data/scripts/questionnaire.inc b/data/scripts/questionnaire.inc index 62e149bb7..849b25a46 100644 --- a/data/scripts/questionnaire.inc +++ b/data/scripts/questionnaire.inc @@ -1,21 +1,16 @@ EventScript_Questionnaire:: lockall msgbox Questionnaire_Text_FillOut, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq Questionnaire_EventScript_Release + goto_if_eq VAR_RESULT, NO, Questionnaire_EventScript_Release setvar VAR_0x8004, EASY_CHAT_TYPE_QUESTIONNAIRE call Common_ShowEasyChatScreen lock faceplayer specialvar VAR_0x8008, GetMartEmployeeObjectEventId - compare VAR_0x8004, 1 - goto_if_eq Questionnaire_EventScript_PlayerInputMysteryEventPhrase - compare VAR_0x8004, 2 - goto_if_eq Questionnaire_EventScript_PlayerInputMysteryGiftPhrase - compare VAR_RESULT, 0 - goto_if_eq Questionnaire_EventScript_Release - compare VAR_RESULT, 1 - goto_if_eq Questionnaire_EventScript_ThankYou + goto_if_eq VAR_0x8004, 1, Questionnaire_EventScript_PlayerInputMysteryEventPhrase + goto_if_eq VAR_0x8004, 2, Questionnaire_EventScript_PlayerInputMysteryGiftPhrase + goto_if_eq VAR_RESULT, 0, Questionnaire_EventScript_Release + goto_if_eq VAR_RESULT, 1, Questionnaire_EventScript_ThankYou end Questionnaire_EventScript_PlayerInputMysteryEventPhrase:: diff --git a/data/scripts/record_mix.inc b/data/scripts/record_mix.inc index d1ad84d3a..109fde2a8 100644 --- a/data/scripts/record_mix.inc +++ b/data/scripts/record_mix.inc @@ -3,10 +3,8 @@ EventScript_MixRecordsPrompt:: lock faceplayer msgbox Text_WouldYouLikeToMixRecords, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq EventScript_MixRecords - compare VAR_RESULT, NO - goto_if_eq EventScript_EndMixRecords + goto_if_eq VAR_RESULT, YES, EventScript_MixRecords + goto_if_eq VAR_RESULT, NO, EventScript_EndMixRecords goto EventScript_EndMixRecords EventScript_MixRecords:: diff --git a/data/scripts/rival_graphics.inc b/data/scripts/rival_graphics.inc index a0fb15f0e..26a5c8fbc 100644 --- a/data/scripts/rival_graphics.inc +++ b/data/scripts/rival_graphics.inc @@ -1,9 +1,7 @@ Common_EventScript_SetupRivalGfxId:: checkplayergender - compare VAR_RESULT, MALE - goto_if_eq EventScript_SetupRivalGfxIdFemale - compare VAR_RESULT, FEMALE - goto_if_eq EventScript_SetupRivalGfxIdMale + goto_if_eq VAR_RESULT, MALE, EventScript_SetupRivalGfxIdFemale + goto_if_eq VAR_RESULT, FEMALE, EventScript_SetupRivalGfxIdMale end EventScript_SetupRivalGfxIdFemale:: @@ -16,10 +14,8 @@ EventScript_SetupRivalGfxIdMale:: Common_EventScript_SetupRivalOnBikeGfxId:: checkplayergender - compare VAR_RESULT, MALE - goto_if_eq EventScript_SetupRivalOnBikeGfxIdFemale - compare VAR_RESULT, FEMALE - goto_if_eq EventScript_SetupRivalOnBikeGfxIdMale + goto_if_eq VAR_RESULT, MALE, EventScript_SetupRivalOnBikeGfxIdFemale + goto_if_eq VAR_RESULT, FEMALE, EventScript_SetupRivalOnBikeGfxIdMale end EventScript_SetupRivalOnBikeGfxIdFemale:: @@ -33,10 +29,8 @@ EventScript_SetupRivalOnBikeGfxIdMale:: @ Unused Common_EventScript_SetupRivalGfxIdSameGender:: checkplayergender - compare VAR_RESULT, MALE - goto_if_eq EventScript_SetupRivalGfxIdMale2 - compare VAR_RESULT, FEMALE - goto_if_eq EventScript_SetupRivalGfxIdFemale2 + goto_if_eq VAR_RESULT, MALE, EventScript_SetupRivalGfxIdMale2 + goto_if_eq VAR_RESULT, FEMALE, EventScript_SetupRivalGfxIdFemale2 end EventScript_SetupRivalGfxIdMale2:: diff --git a/data/scripts/roulette.inc b/data/scripts/roulette.inc index 1167a765b..7163a449a 100644 --- a/data/scripts/roulette.inc +++ b/data/scripts/roulette.inc @@ -1,23 +1,19 @@ Roulette_EventScript_Table1:: - checkitem ITEM_COIN_CASE, 1 - compare VAR_RESULT, FALSE - goto_if_eq MauvilleCity_GameCorner_EventScript_NoCoinCase + checkitem ITEM_COIN_CASE + goto_if_eq VAR_RESULT, FALSE, MauvilleCity_GameCorner_EventScript_NoCoinCase setvar VAR_0x8004, 0 - getpricereduction POKENEWS_GAME_CORNER - compare VAR_RESULT, FALSE - goto_if_eq Roulette_EventScript_Play + getpokenewsactive POKENEWS_GAME_CORNER + goto_if_eq VAR_RESULT, FALSE, Roulette_EventScript_Play addvar VAR_0x8004, ROULETTE_SPECIAL_RATE goto Roulette_EventScript_Play end Roulette_EventScript_Table2:: - checkitem ITEM_COIN_CASE, 1 - compare VAR_RESULT, FALSE - goto_if_eq MauvilleCity_GameCorner_EventScript_NoCoinCase + checkitem ITEM_COIN_CASE + goto_if_eq VAR_RESULT, FALSE, MauvilleCity_GameCorner_EventScript_NoCoinCase setvar VAR_0x8004, 1 - getpricereduction POKENEWS_GAME_CORNER - compare VAR_RESULT, FALSE - goto_if_eq Roulette_EventScript_Play + getpokenewsactive POKENEWS_GAME_CORNER + goto_if_eq VAR_RESULT, FALSE, Roulette_EventScript_Play addvar VAR_0x8004, ROULETTE_SPECIAL_RATE goto Roulette_EventScript_Play end diff --git a/data/scripts/safari_zone.inc b/data/scripts/safari_zone.inc index 6dd0767f0..eb6a90abd 100644 --- a/data/scripts/safari_zone.inc +++ b/data/scripts/safari_zone.inc @@ -1,21 +1,20 @@ SafariZone_EventScript_OutOfBallsMidBattle:: setvar VAR_SAFARI_ZONE_STATE, 1 special ExitSafariMode - setwarp MAP_ROUTE121_SAFARI_ZONE_ENTRANCE, 255, 2, 5 + setwarp MAP_ROUTE121_SAFARI_ZONE_ENTRANCE, 2, 5 end SafariZone_EventScript_Exit:: setvar VAR_SAFARI_ZONE_STATE, 1 special ExitSafariMode - warp MAP_ROUTE121_SAFARI_ZONE_ENTRANCE, 255, 2, 5 + warp MAP_ROUTE121_SAFARI_ZONE_ENTRANCE, 2, 5 waitstate end SafariZone_EventScript_RetirePrompt:: lockall msgbox SafariZone_Text_WouldYouLikeToExit, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq SafariZone_EventScript_Retire + goto_if_eq VAR_RESULT, YES, SafariZone_EventScript_Retire releaseall end @@ -43,11 +42,9 @@ SafariZone_EventScript_OutOfBalls:: EventScript_PokeBlockFeeder:: lockall special GetPokeblockFeederInFront - compare VAR_RESULT, 0xFFFF - goto_if_ne SafariZone_EventScript_PokeblockPresent + goto_if_ne VAR_RESULT, 0xFFFF, SafariZone_EventScript_PokeblockPresent msgbox SafariZone_Text_PlacePokeblockOnFeeder, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq SafariZone_EventScript_ChoosePokeblock + goto_if_eq VAR_RESULT, YES, SafariZone_EventScript_ChoosePokeblock releaseall end @@ -55,8 +52,7 @@ SafariZone_EventScript_ChoosePokeblock:: fadescreen FADE_TO_BLACK special OpenPokeblockCaseOnFeeder waitstate - compare VAR_RESULT, 0xFFFF - goto_if_ne SafariZone_EventScript_PokeblockPlaced + goto_if_ne VAR_RESULT, 0xFFFF, SafariZone_EventScript_PokeblockPlaced end SafariZone_EventScript_PokeblockPlaced:: diff --git a/data/scripts/secret_base.inc b/data/scripts/secret_base.inc index ae802cdfd..d21bb9aab 100644 --- a/data/scripts/secret_base.inc +++ b/data/scripts/secret_base.inc @@ -27,33 +27,24 @@ SecretBase_Text_DiscoveredSmallEntrance: SecretBase_EventScript_CheckEntrance:: special GetSecretBaseTypeInFrontOfPlayer special CheckPlayerHasSecretBase - compare VAR_RESULT, TRUE - goto_if_eq SecretBase_EventScript_AlreadyHasSecretBase + goto_if_eq VAR_RESULT, TRUE, SecretBase_EventScript_AlreadyHasSecretBase checkpartymove MOVE_SECRET_POWER setfieldeffectargument 0, VAR_RESULT - buffermovename 1, MOVE_SECRET_POWER - compare VAR_0x8007, SECRET_BASE_RED_CAVE - goto_if_eq SecretBase_EventScript_Cave - compare VAR_0x8007, SECRET_BASE_BROWN_CAVE - goto_if_eq SecretBase_EventScript_Cave - compare VAR_0x8007, SECRET_BASE_BLUE_CAVE - goto_if_eq SecretBase_EventScript_Cave - compare VAR_0x8007, SECRET_BASE_YELLOW_CAVE - goto_if_eq SecretBase_EventScript_Cave - compare VAR_0x8007, SECRET_BASE_TREE - goto_if_eq SecretBase_EventScript_Tree - compare VAR_0x8007, SECRET_BASE_SHRUB - goto_if_eq SecretBase_EventScript_Shrub + buffermovename STR_VAR_2, MOVE_SECRET_POWER + goto_if_eq VAR_0x8007, SECRET_BASE_RED_CAVE, SecretBase_EventScript_Cave + goto_if_eq VAR_0x8007, SECRET_BASE_BROWN_CAVE, SecretBase_EventScript_Cave + goto_if_eq VAR_0x8007, SECRET_BASE_BLUE_CAVE, SecretBase_EventScript_Cave + goto_if_eq VAR_0x8007, SECRET_BASE_YELLOW_CAVE, SecretBase_EventScript_Cave + goto_if_eq VAR_0x8007, SECRET_BASE_TREE, SecretBase_EventScript_Tree + goto_if_eq VAR_0x8007, SECRET_BASE_SHRUB, SecretBase_EventScript_Shrub end SecretBase_EventScript_Cave:: lockall - compare VAR_RESULT, PARTY_SIZE - goto_if_eq SecretBase_EventScript_CaveNoSecretPower - bufferpartymonnick 0, VAR_RESULT + goto_if_eq VAR_RESULT, PARTY_SIZE, SecretBase_EventScript_CaveNoSecretPower + bufferpartymonnick STR_VAR_1, VAR_RESULT msgbox SecretBase_Text_IndentUseSecretPower, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq SecretBase_EventScript_CancelOnEntrance + goto_if_eq VAR_RESULT, NO, SecretBase_EventScript_CancelOnEntrance msgbox Text_MonUsedFieldMove, MSGBOX_DEFAULT closemessage dofieldeffect FLDEFF_USE_SECRET_POWER_CAVE @@ -80,12 +71,10 @@ SecretBase_EventScript_CaveEnter:: SecretBase_EventScript_Tree:: lockall - compare VAR_RESULT, PARTY_SIZE - goto_if_eq SecretBase_EventScript_TreeNoSecretPower - bufferpartymonnick 0, VAR_RESULT + goto_if_eq VAR_RESULT, PARTY_SIZE, SecretBase_EventScript_TreeNoSecretPower + bufferpartymonnick STR_VAR_1, VAR_RESULT msgbox SecretBase_Text_TreeUseSecretPower, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq SecretBase_EventScript_CancelOnEntrance + goto_if_eq VAR_RESULT, NO, SecretBase_EventScript_CancelOnEntrance msgbox Text_MonUsedFieldMove, MSGBOX_DEFAULT closemessage dofieldeffect FLDEFF_USE_SECRET_POWER_TREE @@ -112,12 +101,10 @@ SecretBase_EventScript_TreeEnter:: SecretBase_EventScript_Shrub:: lockall - compare VAR_RESULT, PARTY_SIZE - goto_if_eq SecretBase_EventScript_ShrubNoSecretPower - bufferpartymonnick 0, VAR_RESULT + goto_if_eq VAR_RESULT, PARTY_SIZE, SecretBase_EventScript_ShrubNoSecretPower + bufferpartymonnick STR_VAR_1, VAR_RESULT msgbox SecretBase_Text_ClumpUseSecretPower, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq SecretBase_EventScript_CancelOnEntrance + goto_if_eq VAR_RESULT, NO, SecretBase_EventScript_CancelOnEntrance msgbox Text_MonUsedFieldMove, MSGBOX_DEFAULT closemessage dofieldeffect FLDEFF_USE_SECRET_POWER_SHRUB @@ -161,8 +148,7 @@ SecretBase_EventScript_FirstEntrance:: waitmovement 0 setvar VAR_INIT_SECRET_BASE, 1 msgbox SecretBase_Text_WantToMakeYourSecretBaseHere, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq SecretBase_EventScript_SetAsBase + goto_if_eq VAR_RESULT, YES, SecretBase_EventScript_SetAsBase closemessage playse SE_EXIT special ClearAndLeaveSecretBase @@ -185,8 +171,7 @@ SecretBase_EventScript_Enter:: setvar VAR_INIT_SECRET_BASE, 1 playse SE_EXIT special IsCurSecretBaseOwnedByAnotherPlayer - compare VAR_RESULT, FALSE - goto_if_eq SecretBase_EventScript_EnterPlayersBase + goto_if_eq VAR_RESULT, FALSE, SecretBase_EventScript_EnterPlayersBase clearflag FLAG_DECORATION_0 special EnterSecretBase setvar VAR_SECRET_BASE_INITIALIZED, 0 @@ -202,59 +187,43 @@ SecretBase_EventScript_EnterPlayersBase:: SecretBase_EventScript_AlreadyHasSecretBase:: checkpartymove MOVE_SECRET_POWER - compare VAR_RESULT, PARTY_SIZE - goto_if_eq SecretBase_EventScript_NoSecretPower + goto_if_eq VAR_RESULT, PARTY_SIZE, SecretBase_EventScript_NoSecretPower setfieldeffectargument 0, VAR_RESULT setorcopyvar VAR_0x8004, VAR_RESULT lockall special GetSecretBaseNearbyMapName msgbox SecretBase_Text_WouldYouLikeToMoveBases, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq SecretBase_EventScript_CancelOnEntrance + goto_if_eq VAR_RESULT, NO, SecretBase_EventScript_CancelOnEntrance msgbox SecretBase_Text_AllDecorationsWillBeReturned, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq SecretBase_EventScript_CancelOnEntrance + goto_if_eq VAR_RESULT, NO, SecretBase_EventScript_CancelOnEntrance fadescreenswapbuffers FADE_TO_BLACK special MoveOutOfSecretBaseFromOutside closemessage fadescreenswapbuffers FADE_FROM_BLACK msgbox SecretBase_Text_MovingCompletedUseSecretPower, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq SecretBase_EventScript_CancelOnEntrance - bufferpartymonnick 0, VAR_0x8004 - buffermovename 1, MOVE_SECRET_POWER + goto_if_eq VAR_RESULT, NO, SecretBase_EventScript_CancelOnEntrance + bufferpartymonnick STR_VAR_1, VAR_0x8004 + buffermovename STR_VAR_2, MOVE_SECRET_POWER msgbox Text_MonUsedFieldMove, MSGBOX_DEFAULT closemessage closemessage - compare VAR_0x8007, SECRET_BASE_RED_CAVE - goto_if_eq SecretBase_EventScript_CaveUseSecretPower - compare VAR_0x8007, SECRET_BASE_BROWN_CAVE - goto_if_eq SecretBase_EventScript_CaveUseSecretPower - compare VAR_0x8007, SECRET_BASE_BLUE_CAVE - goto_if_eq SecretBase_EventScript_CaveUseSecretPower - compare VAR_0x8007, SECRET_BASE_YELLOW_CAVE - goto_if_eq SecretBase_EventScript_CaveUseSecretPower - compare VAR_0x8007, SECRET_BASE_TREE - goto_if_eq SecretBase_EventScript_TreeUseSecretPower - compare VAR_0x8007, SECRET_BASE_SHRUB - goto_if_eq SecretBase_EventScript_ShrubUseSecretPower + goto_if_eq VAR_0x8007, SECRET_BASE_RED_CAVE, SecretBase_EventScript_CaveUseSecretPower + goto_if_eq VAR_0x8007, SECRET_BASE_BROWN_CAVE, SecretBase_EventScript_CaveUseSecretPower + goto_if_eq VAR_0x8007, SECRET_BASE_BLUE_CAVE, SecretBase_EventScript_CaveUseSecretPower + goto_if_eq VAR_0x8007, SECRET_BASE_YELLOW_CAVE, SecretBase_EventScript_CaveUseSecretPower + goto_if_eq VAR_0x8007, SECRET_BASE_TREE, SecretBase_EventScript_TreeUseSecretPower + goto_if_eq VAR_0x8007, SECRET_BASE_SHRUB, SecretBase_EventScript_ShrubUseSecretPower releaseall end SecretBase_EventScript_NoSecretPower:: lockall - compare VAR_0x8007, SECRET_BASE_RED_CAVE - goto_if_eq SecretBase_EventScript_CaveNoSecretPower - compare VAR_0x8007, SECRET_BASE_BROWN_CAVE - goto_if_eq SecretBase_EventScript_CaveNoSecretPower - compare VAR_0x8007, SECRET_BASE_BLUE_CAVE - goto_if_eq SecretBase_EventScript_CaveNoSecretPower - compare VAR_0x8007, SECRET_BASE_YELLOW_CAVE - goto_if_eq SecretBase_EventScript_CaveNoSecretPower - compare VAR_0x8007, SECRET_BASE_TREE - goto_if_eq SecretBase_EventScript_TreeNoSecretPower - compare VAR_0x8007, SECRET_BASE_SHRUB - goto_if_eq SecretBase_EventScript_ShrubNoSecretPower + goto_if_eq VAR_0x8007, SECRET_BASE_RED_CAVE, SecretBase_EventScript_CaveNoSecretPower + goto_if_eq VAR_0x8007, SECRET_BASE_BROWN_CAVE, SecretBase_EventScript_CaveNoSecretPower + goto_if_eq VAR_0x8007, SECRET_BASE_BLUE_CAVE, SecretBase_EventScript_CaveNoSecretPower + goto_if_eq VAR_0x8007, SECRET_BASE_YELLOW_CAVE, SecretBase_EventScript_CaveNoSecretPower + goto_if_eq VAR_0x8007, SECRET_BASE_TREE, SecretBase_EventScript_TreeNoSecretPower + goto_if_eq VAR_0x8007, SECRET_BASE_SHRUB, SecretBase_EventScript_ShrubNoSecretPower end SecretBase_EventScript_CancelOnEntrance:: @@ -302,11 +271,9 @@ SecretBase_EventScript_PutAwayDecoration:: SecretBase_EventScript_PutAwayDecorationLoop:: special PutAwayDecorationIteration - compare VAR_RESULT, 1 - goto_if_eq SecretBase_EventScript_PutAwayDecorationEnd + goto_if_eq VAR_RESULT, 1, SecretBase_EventScript_PutAwayDecorationEnd addvar VAR_0x8004, 1 - compare VAR_0x8005, 0 - goto_if_eq SecretBase_EventScript_PutAwayDecorationLoop + goto_if_eq VAR_0x8005, 0, SecretBase_EventScript_PutAwayDecorationLoop removeobject VAR_0x8006 setflag VAR_0x8005 @ UB: VAR_0x8005 is set to a flag by PutAwayDecorationIteration, but ScrCmd_setflag doesn't use VarGet goto SecretBase_EventScript_PutAwayDecorationLoop @@ -317,26 +284,16 @@ SecretBase_EventScript_PutAwayDecorationEnd:: SecretBase_EventScript_RecordMixTrainer:: special GetSecretBaseOwnerAndState - compare VAR_0x8004, 0 - goto_if_eq SecretBase_EventScript_Trainer0 - compare VAR_0x8004, 1 - goto_if_eq SecretBase_EventScript_Trainer1 - compare VAR_0x8004, 2 - goto_if_eq SecretBase_EventScript_Trainer2 - compare VAR_0x8004, 3 - goto_if_eq SecretBase_EventScript_Trainer3 - compare VAR_0x8004, 4 - goto_if_eq SecretBase_EventScript_Trainer4 - compare VAR_0x8004, 5 - goto_if_eq SecretBase_EventScript_Trainer5 - compare VAR_0x8004, 6 - goto_if_eq SecretBase_EventScript_Trainer6 - compare VAR_0x8004, 7 - goto_if_eq SecretBase_EventScript_Trainer7 - compare VAR_0x8004, 8 - goto_if_eq SecretBase_EventScript_Trainer8 - compare VAR_0x8004, 9 - goto_if_eq SecretBase_EventScript_Trainer9 + goto_if_eq VAR_0x8004, 0, SecretBase_EventScript_Trainer0 + goto_if_eq VAR_0x8004, 1, SecretBase_EventScript_Trainer1 + goto_if_eq VAR_0x8004, 2, SecretBase_EventScript_Trainer2 + goto_if_eq VAR_0x8004, 3, SecretBase_EventScript_Trainer3 + goto_if_eq VAR_0x8004, 4, SecretBase_EventScript_Trainer4 + goto_if_eq VAR_0x8004, 5, SecretBase_EventScript_Trainer5 + goto_if_eq VAR_0x8004, 6, SecretBase_EventScript_Trainer6 + goto_if_eq VAR_0x8004, 7, SecretBase_EventScript_Trainer7 + goto_if_eq VAR_0x8004, 8, SecretBase_EventScript_Trainer8 + goto_if_eq VAR_0x8004, 9, SecretBase_EventScript_Trainer9 end @ VAR_RESULT is initially set by GetSecretBaseOwnerAndState @@ -344,16 +301,13 @@ SecretBase_EventScript_Trainer0:: lock faceplayer goto_if_unset FLAG_SYS_GAME_CLEAR, SecretBase_EventScript_Trainer0PreChampion - compare VAR_RESULT, 1 - goto_if_eq SecretBase_EventScript_Trainer0PostBattle + goto_if_eq VAR_RESULT, 1, SecretBase_EventScript_Trainer0PostBattle msgbox SecretBase_Text_Trainer0Intro, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq SecretBase_EventScript_Trainer0DeclineBattle + goto_if_eq VAR_RESULT, NO, SecretBase_EventScript_Trainer0DeclineBattle setvar VAR_RESULT, 1 special SetBattledOwnerFromResult call Common_EventScript_SaveGame - compare VAR_RESULT, 0 - goto_if_eq SecretBase_EventScript_Trainer0DeclineBattle + goto_if_eq VAR_RESULT, 0, SecretBase_EventScript_Trainer0DeclineBattle msgbox SecretBase_Text_Trainer0AcceptBattle, MSGBOX_DEFAULT goto SecretBase_EventScript_BattleTrainer end @@ -381,16 +335,13 @@ SecretBase_EventScript_Trainer1:: lock faceplayer goto_if_unset FLAG_SYS_GAME_CLEAR, SecretBase_EventScript_Trainer1PreChampion - compare VAR_RESULT, 1 - goto_if_eq SecretBase_EventScript_Trainer1PostBattle + goto_if_eq VAR_RESULT, 1, SecretBase_EventScript_Trainer1PostBattle msgbox SecretBase_Text_Trainer1Intro, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq SecretBase_EventScript_Trainer1DeclineBattle + goto_if_eq VAR_RESULT, NO, SecretBase_EventScript_Trainer1DeclineBattle setvar VAR_RESULT, 1 special SetBattledOwnerFromResult call Common_EventScript_SaveGame - compare VAR_RESULT, 0 - goto_if_eq SecretBase_EventScript_Trainer1DeclineBattle + goto_if_eq VAR_RESULT, 0, SecretBase_EventScript_Trainer1DeclineBattle msgbox SecretBase_Text_Trainer1AcceptBattle, MSGBOX_DEFAULT goto SecretBase_EventScript_BattleTrainer end @@ -418,16 +369,13 @@ SecretBase_EventScript_Trainer2:: lock faceplayer goto_if_unset FLAG_SYS_GAME_CLEAR, SecretBase_EventScript_Trainer2PreChampion - compare VAR_RESULT, 1 - goto_if_eq SecretBase_EventScript_Trainer2PostBattle + goto_if_eq VAR_RESULT, 1, SecretBase_EventScript_Trainer2PostBattle msgbox SecretBase_Text_Trainer2Intro, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq SecretBase_EventScript_Trainer2DeclineBattle + goto_if_eq VAR_RESULT, NO, SecretBase_EventScript_Trainer2DeclineBattle setvar VAR_RESULT, 1 special SetBattledOwnerFromResult call Common_EventScript_SaveGame - compare VAR_RESULT, 0 - goto_if_eq SecretBase_EventScript_Trainer2DeclineBattle + goto_if_eq VAR_RESULT, 0, SecretBase_EventScript_Trainer2DeclineBattle msgbox SecretBase_Text_Trainer2AcceptBattle, MSGBOX_DEFAULT goto SecretBase_EventScript_BattleTrainer end @@ -455,16 +403,13 @@ SecretBase_EventScript_Trainer3:: lock faceplayer goto_if_unset FLAG_SYS_GAME_CLEAR, SecretBase_EventScript_Trainer3PreChampion - compare VAR_RESULT, 1 - goto_if_eq SecretBase_EventScript_Trainer3PostBattle + goto_if_eq VAR_RESULT, 1, SecretBase_EventScript_Trainer3PostBattle msgbox SecretBase_Text_Trainer3Intro, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq SecretBase_EventScript_Trainer3DeclineBattle + goto_if_eq VAR_RESULT, NO, SecretBase_EventScript_Trainer3DeclineBattle setvar VAR_RESULT, 1 special SetBattledOwnerFromResult call Common_EventScript_SaveGame - compare VAR_RESULT, 0 - goto_if_eq SecretBase_EventScript_Trainer3DeclineBattle + goto_if_eq VAR_RESULT, 0, SecretBase_EventScript_Trainer3DeclineBattle msgbox SecretBase_Text_Trainer3AcceptBattle, MSGBOX_DEFAULT goto SecretBase_EventScript_BattleTrainer end @@ -492,16 +437,13 @@ SecretBase_EventScript_Trainer4:: lock faceplayer goto_if_unset FLAG_SYS_GAME_CLEAR, SecretBase_EventScript_Trainer4PreChampion - compare VAR_RESULT, 1 - goto_if_eq SecretBase_EventScript_Trainer4PostBattle + goto_if_eq VAR_RESULT, 1, SecretBase_EventScript_Trainer4PostBattle msgbox SecretBase_Text_Trainer4Intro, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq SecretBase_EventScript_Trainer4DeclineBattle + goto_if_eq VAR_RESULT, NO, SecretBase_EventScript_Trainer4DeclineBattle setvar VAR_RESULT, 1 special SetBattledOwnerFromResult call Common_EventScript_SaveGame - compare VAR_RESULT, 0 - goto_if_eq SecretBase_EventScript_Trainer4DeclineBattle + goto_if_eq VAR_RESULT, 0, SecretBase_EventScript_Trainer4DeclineBattle msgbox SecretBase_Text_Trainer4AcceptBattle, MSGBOX_DEFAULT goto SecretBase_EventScript_BattleTrainer end @@ -529,16 +471,13 @@ SecretBase_EventScript_Trainer5:: lock faceplayer goto_if_unset FLAG_SYS_GAME_CLEAR, SecretBase_EventScript_Trainer5PreChampion - compare VAR_RESULT, 1 - goto_if_eq SecretBase_EventScript_Trainer5PostBattle + goto_if_eq VAR_RESULT, 1, SecretBase_EventScript_Trainer5PostBattle msgbox SecretBase_Text_Trainer5Intro, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq SecretBase_EventScript_Trainer5DeclineBattle + goto_if_eq VAR_RESULT, NO, SecretBase_EventScript_Trainer5DeclineBattle setvar VAR_RESULT, 1 special SetBattledOwnerFromResult call Common_EventScript_SaveGame - compare VAR_RESULT, 0 - goto_if_eq SecretBase_EventScript_Trainer5DeclineBattle + goto_if_eq VAR_RESULT, 0, SecretBase_EventScript_Trainer5DeclineBattle msgbox SecretBase_Text_Trainer5AcceptBattle, MSGBOX_DEFAULT goto SecretBase_EventScript_BattleTrainer end @@ -566,16 +505,13 @@ SecretBase_EventScript_Trainer6:: lock faceplayer goto_if_unset FLAG_SYS_GAME_CLEAR, SecretBase_EventScript_Trainer6PreChampion - compare VAR_RESULT, 1 - goto_if_eq SecretBase_EventScript_Trainer6PostBattle + goto_if_eq VAR_RESULT, 1, SecretBase_EventScript_Trainer6PostBattle msgbox SecretBase_Text_Trainer6Intro, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq SecretBase_EventScript_Trainer6DeclineBattle + goto_if_eq VAR_RESULT, NO, SecretBase_EventScript_Trainer6DeclineBattle setvar VAR_RESULT, 1 special SetBattledOwnerFromResult call Common_EventScript_SaveGame - compare VAR_RESULT, 0 - goto_if_eq SecretBase_EventScript_Trainer6DeclineBattle + goto_if_eq VAR_RESULT, 0, SecretBase_EventScript_Trainer6DeclineBattle msgbox SecretBase_Text_Trainer6AcceptBattle, MSGBOX_DEFAULT goto SecretBase_EventScript_BattleTrainer end @@ -603,16 +539,13 @@ SecretBase_EventScript_Trainer7:: lock faceplayer goto_if_unset FLAG_SYS_GAME_CLEAR, SecretBase_EventScript_Trainer7PreChampion - compare VAR_RESULT, 1 - goto_if_eq SecretBase_EventScript_Trainer7PostBattle + goto_if_eq VAR_RESULT, 1, SecretBase_EventScript_Trainer7PostBattle msgbox SecretBase_Text_Trainer7Intro, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq SecretBase_EventScript_Trainer7DeclineBattle + goto_if_eq VAR_RESULT, NO, SecretBase_EventScript_Trainer7DeclineBattle setvar VAR_RESULT, 1 special SetBattledOwnerFromResult call Common_EventScript_SaveGame - compare VAR_RESULT, 0 - goto_if_eq SecretBase_EventScript_Trainer7DeclineBattle + goto_if_eq VAR_RESULT, 0, SecretBase_EventScript_Trainer7DeclineBattle msgbox SecretBase_Text_Trainer7AcceptBattle, MSGBOX_DEFAULT goto SecretBase_EventScript_BattleTrainer end @@ -640,16 +573,13 @@ SecretBase_EventScript_Trainer8:: lock faceplayer goto_if_unset FLAG_SYS_GAME_CLEAR, SecretBase_EventScript_Trainer8PreChampion - compare VAR_RESULT, 1 - goto_if_eq SecretBase_EventScript_Trainer8PostBattle + goto_if_eq VAR_RESULT, 1, SecretBase_EventScript_Trainer8PostBattle msgbox SecretBase_Text_Trainer8Intro, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq SecretBase_EventScript_Trainer8DeclineBattle + goto_if_eq VAR_RESULT, NO, SecretBase_EventScript_Trainer8DeclineBattle setvar VAR_RESULT, 1 special SetBattledOwnerFromResult call Common_EventScript_SaveGame - compare VAR_RESULT, 0 - goto_if_eq SecretBase_EventScript_Trainer8DeclineBattle + goto_if_eq VAR_RESULT, 0, SecretBase_EventScript_Trainer8DeclineBattle msgbox SecretBase_Text_Trainer8AcceptBattle, MSGBOX_DEFAULT goto SecretBase_EventScript_BattleTrainer end @@ -677,16 +607,13 @@ SecretBase_EventScript_Trainer9:: lock faceplayer goto_if_unset FLAG_SYS_GAME_CLEAR, SecretBase_EventScript_Trainer9PreChampion - compare VAR_RESULT, 1 - goto_if_eq SecretBase_EventScript_Trainer9PostBattle + goto_if_eq VAR_RESULT, 1, SecretBase_EventScript_Trainer9PostBattle msgbox SecretBase_Text_Trainer9Intro, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq SecretBase_EventScript_Trainer9DeclineBattle + goto_if_eq VAR_RESULT, NO, SecretBase_EventScript_Trainer9DeclineBattle setvar VAR_RESULT, 1 special SetBattledOwnerFromResult call Common_EventScript_SaveGame - compare VAR_RESULT, 0 - goto_if_eq SecretBase_EventScript_Trainer9DeclineBattle + goto_if_eq VAR_RESULT, 0, SecretBase_EventScript_Trainer9DeclineBattle msgbox SecretBase_Text_Trainer9AcceptBattle, MSGBOX_DEFAULT goto SecretBase_EventScript_BattleTrainer end @@ -715,12 +642,9 @@ SecretBase_EventScript_BattleTrainer:: setvar VAR_0x8005, 0 special DoSpecialTrainerBattle waitstate - compare VAR_RESULT, B_OUTCOME_DREW - call_if_eq SecretBase_EventScript_DrewSecretBaseBattle - compare VAR_RESULT, B_OUTCOME_WON - call_if_eq SecretBase_EventScript_WonSecretBaseBattle - compare VAR_RESULT, B_OUTCOME_LOST - call_if_eq SecretBase_EventScript_LostSecretBaseBattle + call_if_eq VAR_RESULT, B_OUTCOME_DREW, SecretBase_EventScript_DrewSecretBaseBattle + call_if_eq VAR_RESULT, B_OUTCOME_WON, SecretBase_EventScript_WonSecretBaseBattle + call_if_eq VAR_RESULT, B_OUTCOME_LOST, SecretBase_EventScript_LostSecretBaseBattle special HealPlayerParty release end diff --git a/data/scripts/secret_power_tm.inc b/data/scripts/secret_power_tm.inc index 41c21e100..11a5d5b66 100644 --- a/data/scripts/secret_power_tm.inc +++ b/data/scripts/secret_power_tm.inc @@ -37,26 +37,21 @@ Route111_EventScript_SecretPowerMan:: lock faceplayer msgbox Route111_Text_MakingRoomUseTMToMakeYourOwn, MSGBOX_YESNO - compare VAR_RESULT, YES - goto_if_eq Route111_EventScript_GiveSecretPower + goto_if_eq VAR_RESULT, YES, Route111_EventScript_GiveSecretPower msgbox Route111_Text_DontWantThis, MSGBOX_DEFAULT release end Route111_EventScript_GiveSecretPower:: giveitem ITEM_TM43 - compare VAR_RESULT, FALSE - goto_if_eq Route111_EventScript_NoRoomForSecretPower + goto_if_eq VAR_RESULT, FALSE, Route111_EventScript_NoRoomForSecretPower msgbox Route111_Text_ExplainSecretPower, MSGBOX_DEFAULT closemessage setflag FLAG_RECEIVED_SECRET_POWER clearflag FLAG_HIDE_SLATEPORT_CITY_TM_SALESMAN - compare VAR_FACING, DIR_WEST - call_if_eq Route111_EventScript_SecretPowerManExit - compare VAR_FACING, DIR_EAST - call_if_eq Route111_EventScript_SecretPowerManExit - compare VAR_FACING, DIR_NORTH - call_if_eq Route111_EventScript_SecretPowerManExitNorth + call_if_eq VAR_FACING, DIR_WEST, Route111_EventScript_SecretPowerManExit + call_if_eq VAR_FACING, DIR_EAST, Route111_EventScript_SecretPowerManExit + call_if_eq VAR_FACING, DIR_NORTH, Route111_EventScript_SecretPowerManExitNorth removeobject VAR_LAST_TALKED release end diff --git a/data/scripts/shared_secret_base.inc b/data/scripts/shared_secret_base.inc index ef389d3fc..576e93921 100644 --- a/data/scripts/shared_secret_base.inc +++ b/data/scripts/shared_secret_base.inc @@ -1,224 +1,215 @@ SecretBase_MapScripts:: - 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 + 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_OnWarp: - map_script_2 VAR_SECRET_BASE_INITIALIZED, 0, SecretBase_EventScript_InitDecorations - .2byte 0 + map_script_2 VAR_SECRET_BASE_INITIALIZED, 0, SecretBase_EventScript_InitDecorations + .2byte 0 SecretBase_OnTransition: - call SecretBase_EventScript_SetDecorationFlags - special SetSecretBaseOwnerGfxId - special InitSecretBaseVars - end + call SecretBase_EventScript_SetDecorationFlags + special SetSecretBaseOwnerGfxId + special InitSecretBaseVars + end SecretBase_OnFrame: - map_script_2 VAR_INIT_SECRET_BASE, 0, SecretBase_EventScript_FirstEntrance - .2byte 0 + map_script_2 VAR_INIT_SECRET_BASE, 0, SecretBase_EventScript_FirstEntrance + .2byte 0 SecretBase_OnResume: - setstepcallback STEP_CB_SECRET_BASE - end + setstepcallback STEP_CB_SECRET_BASE + end SecretBase_EventScript_PC:: - lockall - playse SE_PC_LOGIN - message SecretBase_Text_BootUpPC - dofieldeffect FLDEFF_PCTURN_ON - waitstate - waitmessage - waitbuttonpress - playse SE_SELECT - goto SecretBase_EventScript_PCShowMainMenu - end + lockall + playse SE_PC_LOGIN + message SecretBase_Text_BootUpPC + dofieldeffect FLDEFF_PCTURN_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 + message SecretBase_Text_WhatWouldYouLikeToDo + waitmessage + goto_if_set FLAG_SECRET_BASE_REGISTRY_ENABLED, SecretBase_EventScript_PCMainMenuWithRegister + goto SecretBase_EventScript_PCMainMenuWithoutRegister + end SecretBase_EventScript_PCCancel:: - lockall - goto SecretBase_EventScript_PCShowMainMenu - end + lockall + goto SecretBase_EventScript_PCShowMainMenu + end SecretBase_EventScript_PCMainMenuWithRegister:: - multichoice 0, 0, MULTI_BASE_PC_WITH_REGISTRY, FALSE - switch VAR_RESULT - case 0, SecretBase_EventScript_PCDecorationMenu - case 1, SecretBase_EventScript_PCPackUp - case 2, SecretBase_EventScript_PCRegistryMenu - case 3, SecretBase_EventScript_PCTurnOff - case MULTI_B_PRESSED, SecretBase_EventScript_PCTurnOff - end + multichoice 0, 0, MULTI_BASE_PC_WITH_REGISTRY, FALSE + switch VAR_RESULT + case 0, SecretBase_EventScript_PCDecorationMenu + case 1, SecretBase_EventScript_PCPackUp + case 2, SecretBase_EventScript_PCRegistryMenu + case 3, SecretBase_EventScript_PCTurnOff + case MULTI_B_PRESSED, SecretBase_EventScript_PCTurnOff + end SecretBase_EventScript_PCMainMenuWithoutRegister:: - multichoice 0, 0, MULTI_BASE_PC_NO_REGISTRY, FALSE - switch VAR_RESULT - case 0, SecretBase_EventScript_PCDecorationMenu - case 1, SecretBase_EventScript_PCPackUp - case 2, SecretBase_EventScript_PCTurnOff - case MULTI_B_PRESSED, SecretBase_EventScript_PCTurnOff - end + multichoice 0, 0, MULTI_BASE_PC_NO_REGISTRY, FALSE + switch VAR_RESULT + case 0, SecretBase_EventScript_PCDecorationMenu + case 1, SecretBase_EventScript_PCPackUp + case 2, SecretBase_EventScript_PCTurnOff + case MULTI_B_PRESSED, 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 + msgbox SecretBase_Text_AllDecorationsWillBeReturned, MSGBOX_YESNO + goto_if_eq VAR_RESULT, NO, SecretBase_EventScript_PCShowMainMenu + closemessage + special MoveOutOfSecretBase + releaseall + end SecretBase_EventScript_PCDecorationMenu:: - special ShowSecretBaseDecorationMenu - end + special ShowSecretBaseDecorationMenu + end SecretBase_EventScript_PCRegistryMenu:: - special ShowSecretBaseRegistryMenu - end + special ShowSecretBaseRegistryMenu + end SecretBase_EventScript_RecordMixingPC:: - lockall - message SecretBase_Text_BootUpPC - playse SE_PC_LOGIN - dofieldeffect FLDEFF_PCTURN_ON - waitstate - waitmessage - waitbuttonpress - playse SE_SELECT - goto SecretBase_EventScript_PCRegisterMenu - end + lockall + message SecretBase_Text_BootUpPC + playse SE_PC_LOGIN + dofieldeffect FLDEFF_PCTURN_ON + waitstate + waitmessage + waitbuttonpress + playse SE_SELECT + goto SecretBase_EventScript_PCRegisterMenu + end SecretBase_EventScript_PCRegisterMenu:: - message SecretBase_Text_WhatWouldYouLikeToDo - waitmessage - multichoice 0, 0, MULTI_REGISTER_MENU, FALSE - switch VAR_RESULT - case 0, SecretBase_EventScript_PCRegister - case 1, SecretBase_EventScript_PCRegistryMenu - case 2, SecretBase_EventScript_PCRegistryInfo - case 3, SecretBase_EventScript_PCTurnOff - case MULTI_B_PRESSED, SecretBase_EventScript_PCTurnOff - end + message SecretBase_Text_WhatWouldYouLikeToDo + waitmessage + multichoice 0, 0, MULTI_REGISTER_MENU, FALSE + switch VAR_RESULT + case 0, SecretBase_EventScript_PCRegister + case 1, SecretBase_EventScript_PCRegistryMenu + case 2, SecretBase_EventScript_PCRegistryInfo + case 3, SecretBase_EventScript_PCTurnOff + case MULTI_B_PRESSED, SecretBase_EventScript_PCTurnOff + end SecretBase_EventScript_ShowRegisterMenu:: - lockall - goto SecretBase_EventScript_PCRegisterMenu - end + 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 CopyCurSecretBaseOwnerName_StrVar1 - 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 + special GetCurSecretBaseRegistrationValidity + goto_if_eq VAR_RESULT, 1, SecretBase_EventScript_AlreadyRegistered + goto_if_eq VAR_RESULT, 2, SecretBase_EventScript_CantRegisterTooManyBases + special CopyCurSecretBaseOwnerName_StrVar1 + msgbox SecretBase_Text_WantToRegisterSecretBase, MSGBOX_YESNO + goto_if_eq VAR_RESULT, NO, 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 + msgbox SecretBase_Text_AlreadyRegisteredDelete, MSGBOX_YESNO + goto_if_eq VAR_RESULT, NO, 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 + msgbox SecretBase_Text_TooManyBasesDeleteSome, MSGBOX_SIGN + special DoSecretBasePCTurnOffEffect + closemessage + releaseall + end SecretBase_EventScript_PCRegistryInfo:: - msgbox SecretBase_Text_RegistryInfo, MSGBOX_DEFAULT - goto SecretBase_EventScript_PCRegisterMenu - end + msgbox SecretBase_Text_RegistryInfo, MSGBOX_DEFAULT + goto SecretBase_EventScript_PCRegisterMenu + end SecretBase_EventScript_PCTurnOff:: - special DoSecretBasePCTurnOffEffect - closemessage - releaseall - end + special DoSecretBasePCTurnOffEffect + closemessage + releaseall + end @ Unused SecretBase_EventScript_Poster:: - special CheckInteractedWithFriendsPosterDecor - end + special CheckInteractedWithFriendsPosterDecor + end @ Unused SecretBase_EventScript_FurnitureBottom:: - special CheckInteractedWithFriendsFurnitureBottom - end + special CheckInteractedWithFriendsFurnitureBottom + end @ Unused SecretBase_EventScript_FurnitureMiddle:: - special CheckInteractedWithFriendsFurnitureMiddle - end + special CheckInteractedWithFriendsFurnitureMiddle + end @ Unused SecretBase_EventScript_FurnitureTop:: - special CheckInteractedWithFriendsFurnitureTop - end + special CheckInteractedWithFriendsFurnitureTop + end SecretBase_EventScript_SandOrnament:: - special CheckInteractedWithFriendsSandOrnament - dofieldeffect FLDEFF_SAND_PILLAR - waitstate - end + special CheckInteractedWithFriendsSandOrnament + dofieldeffect FLDEFF_SAND_PILLAR + waitstate + end SecretBase_EventScript_ShieldOrToyTV:: - special InteractWithShieldOrTVDecoration - 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 + special InteractWithShieldOrTVDecoration + goto_if_eq VAR_RESULT, 0, SecretBase_EventScript_BattleTowerShield + goto_if_eq VAR_RESULT, 1, SecretBase_EventScript_ToyTV + goto_if_eq VAR_RESULT, 2, SecretBase_EventScript_SeedotTV + goto_if_eq VAR_RESULT, 3, SecretBase_EventScript_SkittyTV + end SecretBase_EventScript_BattleTowerShield:: - msgbox SecretBase_Text_BattleTowerShield, MSGBOX_SIGN - end + msgbox SecretBase_Text_BattleTowerShield, MSGBOX_SIGN + end SecretBase_EventScript_ToyTV:: - msgbox SecretBase_Text_ToyTV, MSGBOX_SIGN - end + msgbox SecretBase_Text_ToyTV, MSGBOX_SIGN + end SecretBase_EventScript_SeedotTV:: - msgbox SecretBase_Text_SeedotTV, MSGBOX_SIGN - end + msgbox SecretBase_Text_SeedotTV, MSGBOX_SIGN + end SecretBase_EventScript_SkittyTV:: - msgbox SecretBase_Text_SkittyTV, MSGBOX_SIGN - end + msgbox SecretBase_Text_SkittyTV, MSGBOX_SIGN + end SecretBase_Text_SmallIndentInWall:: - .string "There's a small indent in the wall.$" + .string "There's a small indent in the wall.$" SecretBase_Text_IndentUseSecretPower:: - .string "There's a small indent in the wall.\p" - .string "Use the SECRET POWER?$" + .string "There's a small indent in the wall.\p" + .string "Use the SECRET POWER?$" SecretBase_Text_DiscoveredSmallCavern:: - .string "Discovered a small cavern!$" + .string "Discovered a small cavern!$" SecretBase_Text_WantToMakeYourSecretBaseHere: - .string "Want to make your SECRET BASE here?$" + .string "Want to make your SECRET BASE here?$" diff --git a/data/scripts/std_msgbox.inc b/data/scripts/std_msgbox.inc index 941cc0e96..c46da56cb 100644 --- a/data/scripts/std_msgbox.inc +++ b/data/scripts/std_msgbox.inc @@ -1,7 +1,7 @@ Std_MsgboxNPC: lock faceplayer - message 0x0 + message NULL waitmessage waitbuttonpress release @@ -9,33 +9,34 @@ Std_MsgboxNPC: Std_MsgboxSign: lockall - message 0x0 + message NULL waitmessage waitbuttonpress releaseall return Std_MsgboxDefault: - message 0x0 + message NULL waitmessage waitbuttonpress return Std_MsgboxYesNo: - message 0x0 + message NULL waitmessage yesnobox 20, 8 return Std_MsgboxGetPoints: - message 0x0 + message NULL playfanfare MUS_OBTAIN_B_POINTS waitfanfare waitmessage return -Std_10: - pokenavcall 0x0 +@ Never used, pokenavcall is always used directly instead +Std_MsgboxPokenav: + pokenavcall NULL waitmessage return diff --git a/data/scripts/surf.inc b/data/scripts/surf.inc index 91580422e..edb116f99 100644 --- a/data/scripts/surf.inc +++ b/data/scripts/surf.inc @@ -1,13 +1,11 @@ EventScript_UseSurf:: checkpartymove MOVE_SURF - compare VAR_RESULT, PARTY_SIZE - goto_if_eq EventScript_EndUseSurf - bufferpartymonnick 0, VAR_RESULT + goto_if_eq VAR_RESULT, PARTY_SIZE, EventScript_EndUseSurf + bufferpartymonnick STR_VAR_1, VAR_RESULT setfieldeffectargument 0, VAR_RESULT lockall msgbox gText_WantToUseSurf, MSGBOX_YESNO - compare VAR_RESULT, NO - goto_if_eq EventScript_ReleaseUseSurf + goto_if_eq VAR_RESULT, NO, EventScript_ReleaseUseSurf msgbox gText_PlayerUsedSurf, MSGBOX_DEFAULT dofieldeffect FLDEFF_USE_SURF EventScript_ReleaseUseSurf:: diff --git a/data/scripts/trainer_battle.inc b/data/scripts/trainer_battle.inc index a59b58a6f..bbbcaf3ba 100644 --- a/data/scripts/trainer_battle.inc +++ b/data/scripts/trainer_battle.inc @@ -13,8 +13,7 @@ EventScript_TryDoNormalTrainerBattle:: applymovement VAR_LAST_TALKED, Movement_RevealTrainer waitmovement 0 specialvar VAR_RESULT, GetTrainerFlag - compare VAR_RESULT, FALSE - goto_if_ne EventScript_NoNormalTrainerBattle + goto_if_ne VAR_RESULT, FALSE, EventScript_NoNormalTrainerBattle special PlayTrainerEncounterMusic special SetTrainerFacingDirection goto EventScript_ShowTrainerIntroMsg @@ -27,11 +26,9 @@ EventScript_TryDoDoubleTrainerBattle:: faceplayer call EventScript_RevealTrainer specialvar VAR_RESULT, GetTrainerFlag - compare VAR_RESULT, FALSE - goto_if_ne EventScript_NoDoubleTrainerBattle + goto_if_ne VAR_RESULT, FALSE, EventScript_NoDoubleTrainerBattle special HasEnoughMonsForDoubleBattle - compare VAR_RESULT, PLAYER_HAS_TWO_USABLE_MONS - goto_if_ne EventScript_NotEnoughMonsForDoubleBattle + goto_if_ne VAR_RESULT, PLAYER_HAS_TWO_USABLE_MONS, EventScript_NotEnoughMonsForDoubleBattle special PlayTrainerEncounterMusic special SetTrainerFacingDirection goto EventScript_ShowTrainerIntroMsg @@ -50,14 +47,13 @@ EventScript_DoNoIntroTrainerBattle:: applymovement VAR_LAST_TALKED, Movement_RevealTrainer waitmovement 0 special PlayTrainerEncounterMusic - trainerbattlebegin + dotrainerbattle gotopostbattlescript EventScript_TryDoRematchBattle:: call EventScript_RevealTrainer specialvar VAR_RESULT, IsTrainerReadyForRematch - compare VAR_RESULT, FALSE - goto_if_eq EventScript_NoRematchTrainerBattle + goto_if_eq VAR_RESULT, FALSE, EventScript_NoRematchTrainerBattle special PlayTrainerEncounterMusic special SetTrainerFacingDirection special ShowTrainerIntroSpeech @@ -73,11 +69,9 @@ EventScript_NoRematchTrainerBattle:: EventScript_TryDoDoubleRematchBattle:: specialvar VAR_RESULT, IsTrainerReadyForRematch - compare VAR_RESULT, FALSE - goto_if_eq EventScript_NoDoubleRematchTrainerBattle + goto_if_eq VAR_RESULT, FALSE, EventScript_NoDoubleRematchTrainerBattle special HasEnoughMonsForDoubleBattle - compare VAR_RESULT, PLAYER_HAS_TWO_USABLE_MONS - goto_if_ne EventScript_NotEnoughMonsForDoubleRematchBattle + goto_if_ne VAR_RESULT, PLAYER_HAS_TWO_USABLE_MONS, EventScript_NotEnoughMonsForDoubleRematchBattle special PlayTrainerEncounterMusic special SetTrainerFacingDirection special ShowTrainerIntroSpeech @@ -112,31 +106,25 @@ EventScript_ShowTrainerIntroMsg:: waitmessage waitbuttonpress special TryPrepareSecondApproachingTrainer - compare VAR_RESULT, TRUE - goto_if_eq EventScript_TrainerApproach + goto_if_eq VAR_RESULT, TRUE, EventScript_TrainerApproach goto EventScript_DoTrainerBattle EventScript_DoTrainerBattle:: - trainerbattlebegin + dotrainerbattle @ Below battle mode check only needed in FRLG specialvar VAR_RESULT, GetTrainerBattleMode - compare VAR_RESULT, TRAINER_BATTLE_SINGLE - goto_if_eq EventScript_EndTrainerBattle - compare VAR_RESULT, TRAINER_BATTLE_CONTINUE_SCRIPT - goto_if_eq EventScript_EndTrainerBattle - compare VAR_RESULT, TRAINER_BATTLE_CONTINUE_SCRIPT_NO_MUSIC - goto_if_eq EventScript_EndTrainerBattle - compare VAR_RESULT, TRAINER_BATTLE_CONTINUE_SCRIPT_DOUBLE - goto_if_eq EventScript_EndTrainerBattle - compare VAR_RESULT, TRAINER_BATTLE_CONTINUE_SCRIPT_DOUBLE_NO_MUSIC - goto_if_eq EventScript_EndTrainerBattle + goto_if_eq VAR_RESULT, TRAINER_BATTLE_SINGLE, EventScript_EndTrainerBattle + goto_if_eq VAR_RESULT, TRAINER_BATTLE_CONTINUE_SCRIPT, EventScript_EndTrainerBattle + goto_if_eq VAR_RESULT, TRAINER_BATTLE_CONTINUE_SCRIPT_NO_MUSIC, EventScript_EndTrainerBattle + goto_if_eq VAR_RESULT, TRAINER_BATTLE_CONTINUE_SCRIPT_DOUBLE, EventScript_EndTrainerBattle + goto_if_eq VAR_RESULT, TRAINER_BATTLE_CONTINUE_SCRIPT_DOUBLE_NO_MUSIC, EventScript_EndTrainerBattle EventScript_EndTrainerBattle:: gotobeatenscript releaseall end Std_MsgboxAutoclose:: - message 0x0 + message NULL waitmessage waitbuttonpress release diff --git a/data/scripts/trainer_hill.inc b/data/scripts/trainer_hill.inc index f3ba5f035..b7f815351 100644 --- a/data/scripts/trainer_hill.inc +++ b/data/scripts/trainer_hill.inc @@ -2,12 +2,9 @@ TrainerHill_OnResume: setvar VAR_TEMP_2, 0 trainerhill_resumetimer frontier_get FRONTIER_DATA_BATTLE_OUTCOME - compare VAR_RESULT, B_OUTCOME_LOST - goto_if_eq TrainerHill_1F_EventScript_Lost - compare VAR_RESULT, B_OUTCOME_DREW - goto_if_eq TrainerHill_1F_EventScript_Lost - compare VAR_RESULT, B_OUTCOME_FORFEITED - goto_if_eq TrainerHill_1F_EventScript_Lost + goto_if_eq VAR_RESULT, B_OUTCOME_LOST, TrainerHill_1F_EventScript_Lost + goto_if_eq VAR_RESULT, B_OUTCOME_DREW, TrainerHill_1F_EventScript_Lost + goto_if_eq VAR_RESULT, B_OUTCOME_FORFEITED, TrainerHill_1F_EventScript_Lost end TrainerHill_OnWarp: @@ -35,13 +32,12 @@ EventScript_TrainerHillTimer:: TrainerHill_1F_EventScript_DummyWarpToEntranceCounter:: setvar VAR_TEMP_2, 1 trainerhill_getusingereader - compare VAR_RESULT, TRUE @ VAR_RESULT always FALSE here - goto_if_eq TrainerHill_1F_EventScript_WarpSilentToEntranceCounter + goto_if_eq VAR_RESULT, TRUE, TrainerHill_1F_EventScript_WarpSilentToEntranceCounter @ VAR_RESULT always FALSE here end @ Never reached TrainerHill_1F_EventScript_WarpSilentToEntranceCounter:: - warpsilent MAP_TRAINER_HILL_ENTRANCE, 255, 9, 6 + warpsilent MAP_TRAINER_HILL_ENTRANCE, 9, 6 waitstate end @@ -53,7 +49,7 @@ TrainerHill_1F_EventScript_Lost:: TrainerHill_EventScript_WarpToEntranceCounter:: setvar VAR_TEMP_1, 0 - warp MAP_TRAINER_HILL_ENTRANCE, 255, 9, 6 + warp MAP_TRAINER_HILL_ENTRANCE, 9, 6 waitstate end diff --git a/data/scripts/trainer_script.inc b/data/scripts/trainer_script.inc index 2a2384c66..c0998aef8 100644 --- a/data/scripts/trainer_script.inc +++ b/data/scripts/trainer_script.inc @@ -1,6 +1,6 @@ Std_RegisteredInMatchCall:: - buffertrainerclassname 0, VAR_0x8000 - buffertrainername 1, VAR_0x8000 + buffertrainerclassname STR_VAR_1, VAR_0x8000 + buffertrainername STR_VAR_2, VAR_0x8000 closemessage delay 30 playfanfare MUS_REGISTER_MATCH_CALL @@ -12,8 +12,7 @@ Std_RegisteredInMatchCall:: EventScript_TryGetTrainerScript:: special ShouldTryGetTrainerScript - compare VAR_RESULT, 1 - goto_if_eq EventScript_GotoTrainerScript + goto_if_eq VAR_RESULT, TRUE, EventScript_GotoTrainerScript releaseall end diff --git a/data/scripts/tv.inc b/data/scripts/tv.inc index 14f3ade48..a5a093226 100644 --- a/data/scripts/tv.inc +++ b/data/scripts/tv.inc @@ -3,29 +3,23 @@ EventScript_TV:: incrementgamestat GAME_STAT_WATCHED_TV special ResetTVShowState specialvar VAR_RESULT, CheckForPlayersHouseNews - compare VAR_RESULT, PLAYERS_HOUSE_TV_MOVIE - goto_if_eq EventScript_PlayersHouseMovie - compare VAR_RESULT, PLAYERS_HOUSE_TV_LATI - goto_if_eq EventScript_PlayersHouseLatiNewsFlash + goto_if_eq VAR_RESULT, PLAYERS_HOUSE_TV_MOVIE, EventScript_PlayersHouseMovie + goto_if_eq VAR_RESULT, PLAYERS_HOUSE_TV_LATI, EventScript_PlayersHouseLatiNewsFlash goto_if_unset FLAG_SYS_TV_START, EventScript_MomDadMightLikeThis1 goto_if_set FLAG_SYS_TV_WATCH, EventScript_MomDadMightLikeThis1 specialvar VAR_RESULT, IsGabbyAndTyShowOnTheAir - compare VAR_RESULT, TRUE - goto_if_eq EventScript_DoInSearchOfTrainers + goto_if_eq VAR_RESULT, TRUE, EventScript_DoInSearchOfTrainers goto EventScript_TryDoPokeNews end EventScript_TryDoTVShow:: specialvar VAR_0x8004, GetRandomActiveShowIdx - compare VAR_0x8004, 255 - goto_if_eq EventScript_MomDadMightLikeThis2 + goto_if_eq VAR_0x8004, 255, EventScript_MomDadMightLikeThis2 specialvar VAR_RESULT, GetNextActiveShowIfMassOutbreak - compare VAR_RESULT, 255 - goto_if_eq EventScript_MomDadMightLikeThis2 + goto_if_eq VAR_RESULT, 255, EventScript_MomDadMightLikeThis2 copyvar VAR_0x8004, VAR_RESULT specialvar VAR_RESULT, GetSelectedTVShow - compare VAR_RESULT, 0 - goto_if_ne EventScript_DoTVShow + goto_if_ne VAR_RESULT, 0, EventScript_DoTVShow end EventScript_MomDadMightLikeThis1:: @@ -52,12 +46,13 @@ EventScript_PlayersHouseLatiNewsFlash:: releaseall end +@ The following is a loop for the TV show messages +@ VAR_RESULT is set to TRUE when the show has printed its final message EventScript_DoTVShow:: special DoTVShow waitmessage waitbuttonpress - compare VAR_RESULT, 1 - goto_if_ne EventScript_DoTVShow + goto_if_ne VAR_RESULT, TRUE, EventScript_DoTVShow goto EventScript_TurnOffTV end @@ -75,8 +70,7 @@ EventScript_MomDadMightLikeThis2:: EventScript_TryDoPokeNews:: special DoPokeNews - compare VAR_RESULT, FALSE - goto_if_eq EventScript_TryDoTVShow + goto_if_eq VAR_RESULT, FALSE, EventScript_TryDoTVShow waitmessage waitbuttonpress goto EventScript_TurnOffTV @@ -86,7 +80,6 @@ EventScript_DoInSearchOfTrainers:: special DoTVShowInSearchOfTrainers waitmessage waitbuttonpress - compare VAR_RESULT, 0 - goto_if_eq EventScript_DoInSearchOfTrainers + goto_if_eq VAR_RESULT, 0, EventScript_DoInSearchOfTrainers goto EventScript_TurnOffTV end |