diff options
author | dannye <33dannye@gmail.com> | 2020-05-20 19:40:33 -0500 |
---|---|---|
committer | dannye <33dannye@gmail.com> | 2020-05-20 20:02:53 -0500 |
commit | 10f9559eab8c93b94abb8ae8d1083704ad4e169a (patch) | |
tree | 7dbe7b152dde8a6e9b56664b5b8cdfc0d6be1253 /scripts/BluesHouse.asm | |
parent | b8954732a3eaa3a784a6e3eaaa68977a9ccd9816 (diff) |
Sync with pokered
Diffstat (limited to 'scripts/BluesHouse.asm')
-rwxr-xr-x | scripts/BluesHouse.asm | 85 |
1 files changed, 85 insertions, 0 deletions
diff --git a/scripts/BluesHouse.asm b/scripts/BluesHouse.asm new file mode 100755 index 00000000..471e6989 --- /dev/null +++ b/scripts/BluesHouse.asm @@ -0,0 +1,85 @@ +BluesHouse_Script: + call EnableAutoTextBoxDrawing + ld hl, BluesHouse_ScriptPointers + xor a + call CallFunctionInTable + ret + +BluesHouse_ScriptPointers: + dw BluesHouseScript0 + dw BluesHouseScript1 + +BluesHouseScript0: + SetEvent EVENT_ENTERED_BLUES_HOUSE + + ; trigger the next script + ld a, 1 + ld [wBluesHouseCurScript], a +BluesHouseScript1: + ret + +BluesHouse_TextPointers: + dw BluesHouseText1 + dw BluesHouseText2 + dw BluesHouseText3 + +BluesHouseText1: + TX_ASM + CheckEvent EVENT_GOT_TOWN_MAP + jr nz, .GotMap + CheckEvent EVENT_GOT_POKEDEX + jr nz, .GiveMap + ld hl, DaisyInitialText + call PrintText + jr .done +.GiveMap + ld hl, DaisyOfferMapText + call PrintText + lb bc, TOWN_MAP, 1 + call GiveItem + jr nc, .BagFull + ld a, HS_TOWN_MAP + ld [wMissableObjectIndex], a + predef HideObject ; hide table map object + ld hl, GotMapText + call PrintText + SetEvent EVENT_GOT_TOWN_MAP + jr .done +.GotMap + ld hl, DaisyUseMapText + call PrintText + jr .done +.BagFull + ld hl, DaisyBagFullText + call PrintText +.done + jp TextScriptEnd + +DaisyInitialText: + TX_FAR _DaisyInitialText + db "@" + +DaisyOfferMapText: + TX_FAR _DaisyOfferMapText + db "@" + +GotMapText: + TX_FAR _GotMapText + TX_SFX_KEY_ITEM + db "@" + +DaisyBagFullText: + TX_FAR _DaisyBagFullText + db "@" + +DaisyUseMapText: + TX_FAR _DaisyUseMapText + db "@" + +BluesHouseText2: ; Daisy, walking around + TX_FAR _BluesHouseText2 + db "@" + +BluesHouseText3: ; map on table + TX_FAR _BluesHouseText3 + db "@" |