Prev: 50289 Up: Map Next: 50313
50305: Pick Up Special Item
Used by the routine at PickUpItem.
Works out the number of an item from the type of the object that has been picked up (an object of type 48 or above).
Input
A Type of the object
HL Address of the free place in the inventory
IX Object
PickUpItem_Special 50305 RRA Divide the type by four, keep the lowest two bits and add five, to make the number of the item. Jump to PickUpItem_Store to put it in the inventory.
50306 RRA
50307 AND 3
50309 ADD A,5
50311 JR PickUpItem_Store
Prev: 50289 Up: Map Next: 50313