diff options
| author | GriffinR <griffin.g.richards@gmail.com> | 2020-02-26 01:46:21 -0500 |
|---|---|---|
| committer | GriffinR <griffin.g.richards@gmail.com> | 2020-02-26 01:46:21 -0500 |
| commit | e80ddc46758bfef075b749af2802ce5d646bd9cd (patch) | |
| tree | 560086f0cbad5a8a2a3e7cb4603d7058440d3924 /data/maps/TwoIsland_House | |
| parent | 3b558edc7906b2a75b7d65aa396c611ce1802e62 (diff) | |
Document Two Island scripts
Diffstat (limited to 'data/maps/TwoIsland_House')
| -rw-r--r-- | data/maps/TwoIsland_House/map.json | 2 | ||||
| -rw-r--r-- | data/maps/TwoIsland_House/scripts.inc | 129 | ||||
| -rw-r--r-- | data/maps/TwoIsland_House/text.inc | 20 |
3 files changed, 78 insertions, 73 deletions
diff --git a/data/maps/TwoIsland_House/map.json b/data/maps/TwoIsland_House/map.json index 2f45c143f..208519ec4 100644 --- a/data/maps/TwoIsland_House/map.json +++ b/data/maps/TwoIsland_House/map.json @@ -25,7 +25,7 @@ "movement_range_y": 1, "trainer_type": 0, "trainer_sight_or_berry_tree_id": 0, - "script": "TwoIsland_House_EventScript_171619", + "script": "TwoIsland_House_EventScript_MoveManiac", "flag": "0" } ], diff --git a/data/maps/TwoIsland_House/scripts.inc b/data/maps/TwoIsland_House/scripts.inc index 9177de9cb..692f374fd 100644 --- a/data/maps/TwoIsland_House/scripts.inc +++ b/data/maps/TwoIsland_House/scripts.inc @@ -1,122 +1,127 @@ +.equ CHECKED_MUSHROOMS, FLAG_TEMP_1 +.equ HAS_BIG_MUSHROOM, FLAG_TEMP_2 +.equ HAS_TINY_MUSHROOMS, FLAG_TEMP_3 +.equ HAS_BOTH_MUSHROOMS, FLAG_TEMP_4 + TwoIsland_House_MapScripts:: @ 8171618 .byte 0 -TwoIsland_House_EventScript_171619:: @ 8171619 +TwoIsland_House_EventScript_MoveManiac:: @ 8171619 goto_if_questlog EventScript_ReleaseEnd special sub_8112364 lock faceplayer - clearflag FLAG_TEMP_2 - clearflag FLAG_TEMP_3 - clearflag FLAG_TEMP_4 - goto_if_set FLAG_TEMP_1, EventScript_17164F - msgbox gUnknown_81A2B88 - setflag FLAG_TEMP_1 - goto EventScript_17164F + clearflag HAS_BIG_MUSHROOM + clearflag HAS_TINY_MUSHROOMS + clearflag HAS_BOTH_MUSHROOMS + goto_if_set CHECKED_MUSHROOMS, TwoIsland_House_EventScript_CheckPlayerHasMushrooms + msgbox TwoIsland_House_Text_TeachMonMoveForMushroom + setflag CHECKED_MUSHROOMS + goto TwoIsland_House_EventScript_CheckPlayerHasMushrooms end -EventScript_17164F:: @ 817164F +TwoIsland_House_EventScript_CheckPlayerHasMushrooms:: @ 817164F checkitem ITEM_BIG_MUSHROOM, 1 compare VAR_RESULT, TRUE - call_if_eq EventScript_1717A8 + call_if_eq TwoIsland_House_EventScript_SetHasBigMushroom checkitem ITEM_TINY_MUSHROOM, 2 compare VAR_RESULT, TRUE - call_if_eq EventScript_1717AC - goto_if_set FLAG_TEMP_2, EventScript_171687 - goto_if_set FLAG_TEMP_3, EventScript_171696 - goto EventScript_17179E + call_if_eq TwoIsland_House_EventScript_SetHasTinyMushrooms + goto_if_set HAS_BIG_MUSHROOM, TwoIsland_House_EventScript_CheckAlsoHasTinyMushrooms + goto_if_set HAS_TINY_MUSHROOMS, TwoIsland_House_EventScript_CheckAlsoHasBigMushroom + goto TwoIsland_House_EventScript_EndTutorMove end -EventScript_171687:: @ 8171687 - call_if_set FLAG_TEMP_3, EventScript_1717B0 - goto EventScript_1716A5 +TwoIsland_House_EventScript_CheckAlsoHasTinyMushrooms:: @ 8171687 + call_if_set HAS_TINY_MUSHROOMS, TwoIsland_House_EventScript_SetHasBothMushrooms + goto TwoIsland_House_EventScript_AskTutorMon end -EventScript_171696:: @ 8171696 - call_if_set FLAG_TEMP_2, EventScript_1717B0 - goto EventScript_1716A5 +TwoIsland_House_EventScript_CheckAlsoHasBigMushroom:: @ 8171696 + call_if_set HAS_BIG_MUSHROOM, TwoIsland_House_EventScript_SetHasBothMushrooms + goto TwoIsland_House_EventScript_AskTutorMon end -EventScript_1716A5:: @ 81716A5 - msgbox gUnknown_81A2C63, MSGBOX_YESNO +TwoIsland_House_EventScript_AskTutorMon:: @ 81716A5 + msgbox TwoIsland_House_Text_WantMeToTeachMove, MSGBOX_YESNO compare VAR_RESULT, NO - goto_if_eq EventScript_17179E - goto EventScript_1716BE + goto_if_eq TwoIsland_House_EventScript_EndTutorMove + goto TwoIsland_House_EventScript_ChooseMonToTutor end -EventScript_1716BE:: @ 81716BE - msgbox gUnknown_81A2CC3 +TwoIsland_House_EventScript_ChooseMonToTutor:: @ 81716BE + msgbox TwoIsland_House_Text_TutorWhichMon special Special_SelectMoveTutorMon waitstate - compare VAR_0x8004, 6 - goto_if_ge EventScript_17179E + compare VAR_0x8004, PARTY_SIZE + goto_if_ge TwoIsland_House_EventScript_EndTutorMove special Special_IsSelectedMonEgg - compare VAR_RESULT, 1 - goto_if_eq EventScript_171790 + compare VAR_RESULT, TRUE + goto_if_eq TwoIsland_House_EventScript_CantTutorEgg compare VAR_0x8005, 0 - goto_if_eq EventScript_171782 - goto EventScript_1716F4 + goto_if_eq TwoIsland_House_EventScript_NoMoveToTutorMon + goto TwoIsland_House_EventScript_ChooseMoveToTeach end -EventScript_1716F4:: @ 81716F4 - msgbox gUnknown_81A2CE1 +TwoIsland_House_EventScript_ChooseMoveToTeach:: @ 81716F4 + msgbox TwoIsland_House_Text_TeachWhichMove special DisplayMoveTutorMenu waitstate compare VAR_0x8004, 0 - goto_if_eq EventScript_1716BE - goto_if_set FLAG_TEMP_4, EventScript_17175B - goto_if_set FLAG_TEMP_2, EventScript_171727 - goto_if_set FLAG_TEMP_3, EventScript_171741 + goto_if_eq TwoIsland_House_EventScript_ChooseMonToTutor + goto_if_set HAS_BOTH_MUSHROOMS, TwoIsland_House_EventScript_ChooseMushroom + goto_if_set HAS_BIG_MUSHROOM, TwoIsland_House_EventScript_GiveBigMushroom + goto_if_set HAS_TINY_MUSHROOMS, TwoIsland_House_EventScript_GiveTinyMushrooms end -EventScript_171727:: @ 8171727 +TwoIsland_House_EventScript_GiveBigMushroom:: @ 8171727 removeitem ITEM_BIG_MUSHROOM, 1 textcolor 3 - msgbox gUnknown_81A2DB3 + msgbox TwoIsland_House_Text_HandedOverOneBigMushroom call EventScript_1A6675 - goto EventScript_17179E + goto TwoIsland_House_EventScript_EndTutorMove end -EventScript_171741:: @ 8171741 +TwoIsland_House_EventScript_GiveTinyMushrooms:: @ 8171741 removeitem ITEM_TINY_MUSHROOM, 2 textcolor 3 - msgbox gUnknown_81A2D85 + msgbox TwoIsland_House_Text_HandedOverTwoTinyMushrooms call EventScript_1A6675 - goto EventScript_17179E + goto TwoIsland_House_EventScript_EndTutorMove end -EventScript_17175B:: @ 817175B - message Text_1A2D43 +TwoIsland_House_EventScript_ChooseMushroom:: @ 817175B + message TwoIsland_House_Text_IllNeedMushroomOrTwo waitmessage multichoice 0, 0, MULTICHOICE_MUSHROOMS, TRUE switch VAR_RESULT - case 0, EventScript_171741 - case 1, EventScript_171727 + case 0, TwoIsland_House_EventScript_GiveTinyMushrooms + case 1, TwoIsland_House_EventScript_GiveBigMushroom end -EventScript_171782:: @ 8171782 - msgbox gUnknown_81A2CFC - goto EventScript_1716BE +TwoIsland_House_EventScript_NoMoveToTutorMon:: @ 8171782 + msgbox TwoIsland_House_Text_NoMoveICanTeachThatMon + goto TwoIsland_House_EventScript_ChooseMonToTutor end -EventScript_171790:: @ 8171790 - msgbox gUnknown_81A2E20 - goto EventScript_1716BE +TwoIsland_House_EventScript_CantTutorEgg:: @ 8171790 + msgbox TwoIsland_House_Text_CantTeachAnEgg + goto TwoIsland_House_EventScript_ChooseMonToTutor end -EventScript_17179E:: @ 817179E - msgbox gUnknown_81A2DE0 +TwoIsland_House_EventScript_EndTutorMove:: @ 817179E + msgbox TwoIsland_House_Text_NeedMushroomOrTwoToLearnMove release end -EventScript_1717A8:: @ 81717A8 - setflag FLAG_TEMP_2 +TwoIsland_House_EventScript_SetHasBigMushroom:: @ 81717A8 + setflag HAS_BIG_MUSHROOM return -EventScript_1717AC:: @ 81717AC - setflag FLAG_TEMP_3 +TwoIsland_House_EventScript_SetHasTinyMushrooms:: @ 81717AC + setflag HAS_TINY_MUSHROOMS return -EventScript_1717B0:: @ 81717B0 - setflag FLAG_TEMP_4 +TwoIsland_House_EventScript_SetHasBothMushrooms:: @ 81717B0 + setflag HAS_BOTH_MUSHROOMS return diff --git a/data/maps/TwoIsland_House/text.inc b/data/maps/TwoIsland_House/text.inc index 0f0aeda5e..6f8a37f97 100644 --- a/data/maps/TwoIsland_House/text.inc +++ b/data/maps/TwoIsland_House/text.inc @@ -1,4 +1,4 @@ -gUnknown_81A2B88:: @ 81A2B88 +TwoIsland_House_Text_TeachMonMoveForMushroom:: @ 81A2B88 .string "I'm the POKéMON MOVE MANIAC.\p" .string "I know every single move that\n" .string "POKéMON learn growing up.\p" @@ -8,40 +8,40 @@ gUnknown_81A2B88:: @ 81A2B88 .string "If you do that for me, I'll teach\n" .string "a move to one POKéMON.$" -gUnknown_81A2C63:: @ 81A2C63 +TwoIsland_House_Text_WantMeToTeachMove:: @ 81A2C63 .string "Sniff, sniff…\n" .string "Hm! You smell of MUSHROOMS!\p" .string "Do you want me to teach a move\n" .string "to a POKéMON of yours?$" -gUnknown_81A2CC3:: @ 81A2CC3 +TwoIsland_House_Text_TutorWhichMon:: @ 81A2CC3 .string "Which POKéMON needs tutoring?$" -gUnknown_81A2CE1:: @ 81A2CE1 +TwoIsland_House_Text_TeachWhichMove:: @ 81A2CE1 .string "Which move should I teach?$" -gUnknown_81A2CFC:: @ 81A2CFC +TwoIsland_House_Text_NoMoveICanTeachThatMon:: @ 81A2CFC .string "Sorry…\p" .string "It doesn't appear as if I have a\n" .string "move I can teach that POKéMON.$" -Text_1A2D43:: @ 81A2D43 +TwoIsland_House_Text_IllNeedMushroomOrTwo:: @ 81A2D43 .string "Then, I'll need a MUSHROOM or two.\n" .string "What are you going to give me?$" -gUnknown_81A2D85:: @ 81A2D85 +TwoIsland_House_Text_HandedOverTwoTinyMushrooms:: @ 81A2D85 .string "{PLAYER} handed over two\n" .string "TINYMUSHROOMS in exchange.$" -gUnknown_81A2DB3:: @ 81A2DB3 +TwoIsland_House_Text_HandedOverOneBigMushroom:: @ 81A2DB3 .string "{PLAYER} handed over one\n" .string "BIG MUSHROOM in exchange.$" -gUnknown_81A2DE0:: @ 81A2DE0 +TwoIsland_House_Text_NeedMushroomOrTwoToLearnMove:: @ 81A2DE0 .string "If your POKéMON need to learn a\n" .string "move, I need a MUSHROOM or two.$" -gUnknown_81A2E20:: @ 81A2E20 +TwoIsland_House_Text_CantTeachAnEgg:: @ 81A2E20 .string "Hunh? There isn't a single move\n" .string "that I can teach an EGG.$" |
