Prev: AA5F Up: Map Next: AA8A
AA6E: Handler: Pick Up Item
Handler_PickUpItem AA6E JP NZ,Handler_RunScript_10 The item stays where it is.
AA71 LD A,(IX+$01) A=*IX+01.
AA74 CALL Handler_RunScript_15 Call Handler_RunScript_15.
Call Handler_UpdateItemLocation using the item ID, to change the location to 01 (to the players inventory).
AA77 LD B,A B=A.
AA78 LD C,$01 C=01.
AA7A CALL Handler_UpdateItemLocation Call Handler_UpdateItemLocation.
Player has picked up an item so handle the inventory count.
AA7D LD HL,$A0D2 Increment *Count_InventoryItems by one.
AA80 INC (HL)
Print "O.K.".
AA81 LD HL,$001A HL=Messaging_OK.
AA84 CALL PrintCompressedStringAndNewline Call PrintCompressedStringAndNewline.
AA87 JP Handler_RunScript_10 Jump to Handler_RunScript_10.
View the equivalent code in;
Prev: AA5F Up: Map Next: AA8A