![]() |
Routines |
Prev: F1D9 | Up: Map | Next: F1FE |
|
||||
The player wants to take the sword from the stone slab, check which version of the sword is in the current room.
|
||||
Process_TakeSwordFromSlab | F1DF | LD HL,$E392 | Call CheckItemGroupPresent with Data_ItemGroup_Sword. | |
F1E2 | CALL CheckItemGroupPresent | |||
This entry point is used by the routine at Process_GetSword.
Handle checking if the player is already carrying the sword.
|
||||
GetSword | F1E5 | CALL Check_PlayerInventory | Call Check_PlayerInventory. | |
Check if the sword item in the room is the one where the sword is laying on the stone slab.
|
||||
F1E8 | LD A,B | Jump to NoSwordOnSlab if the version of the sword is not "A shimmering stone slab with a sword laying upon it". | ||
F1E9 | CP $59 | |||
F1EB | JR NZ,NoSwordOnSlab | |||
Let the player pick up the sword.
Change the sword state!
|
||||
F1ED | LD BC,$5958 | Call TransformItem to transform item 59 ("A shimmering stone slab with a sword laying upon it") into item 58 ("A stone slab"). | ||
F1F0 | CALL TransformItem | |||
F1F3 | LD B,$39 | Jump to Handler_PickUpItem with item 39: "A sword". | ||
F1F5 | JP Handler_PickUpItem | |||
The sword isn't on the slab! Respond with this.
Print "It is not on the slab.".
|
||||
NoSwordOnSlab | F1F8 | LD HL,$D51A | HL=Messaging_ItIsNotOnTheSlab. | |
F1FB | JP PrintStringAndNewline_Duplicate | Jump to PrintStringAndNewline_Duplicate. |
Prev: F1D9 | Up: Map | Next: F1FE |