![]() |
Routines |
Prev: EECF | Up: Map | Next: EF09 |
|
||||
The player wants to pick up the urn, check if there are any issues with allowing this (if the inventory is full, or the player is already carrying it).
|
||||
Process_GetUrn | EEE9 | LD A,$1C | Call Check_PlayerInventory with item 1C: "An urn". | |
EEEB | CALL Check_PlayerInventory | |||
All is good, but check if "A bronze helmet (worn)" is present.
|
||||
EEEE | LD A,$20 | Call ValidateItemPresent with item 20: "A bronze helmet (worn)". | ||
EEF0 | CALL ValidateItemPresent | |||
Print "You cannot move it." if the player isn't wearing the helmet.
|
||||
EEF3 | JP NZ,Response_YouCannotMoveIt | Jump to Response_YouCannotMoveIt if "A bronze helmet (worn)" isn't present in the room or in the players inventory (note, it can only be in the "worn" state in the players inventory). | ||
Is this the first time the player has picked up the urn?
|
||||
EEF6 | LD HL,$A76C | Jump to GetUrn if bit 4 of *Flag_GameStates_01 is set, which relates to carrying the urn. | ||
EEF9 | BIT 4,(HL) | |||
EEFB | JR NZ,GetUrn | |||
EEFD | SET 4,(HL) | Set bit 4 of *HL to signify that the urn has been picked up. This is to prevent the points from being awarded more than one time. | ||
EEFF | LD A,$04 | Call AddToScore to add 04 points to the score. | ||
EF01 | CALL AddToScore | |||
GetUrn | EF04 | LD B,$1C | Jump to Handler_PickUpItem with item 1C: "An urn". | |
EF06 | JP Handler_PickUpItem |
Prev: EECF | Up: Map | Next: EF09 |