aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/CinnabarLabFossilRoom.asm
diff options
context:
space:
mode:
authordannye <33dannye@gmail.com>2023-11-20 00:33:27 -0600
committerdannye <33dannye@gmail.com>2023-11-20 20:23:27 -0600
commit298e99d3776580585c3f434e5d93137ae431bdd3 (patch)
treea808c4ffd0fd0f9bd28972bae5236e0d3345c8e5 /scripts/CinnabarLabFossilRoom.asm
parentAdd sound bits documentation for wOptions (#110) (diff)
parentName 2 unnamed labels I missed in SeafoamIslandsB4F and PokemonMansion3F (#437) (diff)
downloadpokeyellow-298e99d3776580585c3f434e5d93137ae431bdd3.tar.gz
pokeyellow-298e99d3776580585c3f434e5d93137ae431bdd3.tar.xz
pokeyellow-298e99d3776580585c3f434e5d93137ae431bdd3.zip
Merge branch 'master' of https://github.com/pret/pokered
Diffstat (limited to 'scripts/CinnabarLabFossilRoom.asm')
-rw-r--r--scripts/CinnabarLabFossilRoom.asm55
1 files changed, 28 insertions, 27 deletions
diff --git a/scripts/CinnabarLabFossilRoom.asm b/scripts/CinnabarLabFossilRoom.asm
index 7ed9b1a9..7e1f57f0 100644
--- a/scripts/CinnabarLabFossilRoom.asm
+++ b/scripts/CinnabarLabFossilRoom.asm
@@ -2,8 +2,9 @@ CinnabarLabFossilRoom_Script:
jp EnableAutoTextBoxDrawing
CinnabarLabFossilRoom_TextPointers:
- dw Lab4Text1
- dw Lab4Text2
+ def_text_pointers
+ dw_const CinnabarLabFossilRoomScientist1Text, TEXT_CINNABARLABFOSSILROOM_SCIENTIST1
+ dw_const CinnabarLabFossilRoomScientist2Text, TEXT_CINNABARLABFOSSILROOM_SCIENTIST2
Lab4Script_GetFossilsInBag:
; construct a list of all fossils in the player's bag
@@ -46,59 +47,59 @@ FossilsList:
db OLD_AMBER
db 0 ; end
-Lab4Text1:
+CinnabarLabFossilRoomScientist1Text:
text_asm
CheckEvent EVENT_GAVE_FOSSIL_TO_LAB
- jr nz, .asm_75d96
- ld hl, Lab4Text_75dc6
+ jr nz, .check_done_reviving
+ ld hl, .Text
call PrintText
call Lab4Script_GetFossilsInBag
ld a, [wFilteredBagItemsCount]
and a
- jr z, .asm_75d8d
+ jr z, .no_fossils
farcall GiveFossilToCinnabarLab
- jr .asm_75d93
-.asm_75d8d
- ld hl, Lab4Text_75dcb
+ jr .done
+.no_fossils
+ ld hl, .NoFossilsText
call PrintText
-.asm_75d93
+.done
jp TextScriptEnd
-.asm_75d96
+.check_done_reviving
CheckEventAfterBranchReuseA EVENT_LAB_STILL_REVIVING_FOSSIL, EVENT_GAVE_FOSSIL_TO_LAB
- jr z, .asm_75da2
- ld hl, Lab4Text_75dd0
+ jr z, .done_reviving
+ ld hl, .GoForAWalkText
call PrintText
- jr .asm_75d93
-.asm_75da2
+ jr .done
+.done_reviving
call LoadFossilItemAndMonNameBank1D
- ld hl, Lab4Text_75dd5
+ ld hl, .FossilIsBackToLifeText
call PrintText
SetEvent EVENT_LAB_HANDING_OVER_FOSSIL_MON
ld a, [wFossilMon]
ld b, a
ld c, 30
call GivePokemon
- jr nc, .asm_75d93
+ jr nc, .done
ResetEvents EVENT_GAVE_FOSSIL_TO_LAB, EVENT_LAB_STILL_REVIVING_FOSSIL, EVENT_LAB_HANDING_OVER_FOSSIL_MON
- jr .asm_75d93
+ jr .done
-Lab4Text_75dc6:
- text_far _Lab4Text_75dc6
+.Text:
+ text_far _CinnabarLabFossilRoomScientist1Text
text_end
-Lab4Text_75dcb:
- text_far _Lab4Text_75dcb
+.NoFossilsText:
+ text_far _CinnabarLabFossilRoomScientist1NoFossilsText
text_end
-Lab4Text_75dd0:
- text_far _Lab4Text_75dd0
+.GoForAWalkText:
+ text_far _CinnabarLabFossilRoomScientist1GoForAWalkText
text_end
-Lab4Text_75dd5:
- text_far _Lab4Text_75dd5
+.FossilIsBackToLifeText:
+ text_far _CinnabarLabFossilRoomScientist1FossilIsBackToLifeText
text_end
-Lab4Text2:
+CinnabarLabFossilRoomScientist2Text:
text_asm
ld a, TRADE_FOR_STICKY
ld [wWhichTrade], a