![]() |
Routines |
| Prev: 36133 | Up: Map | Next: 36206 |
|
Used by the routine at ActionTie.
Picks the current object up, when it is here and can be carried. Reached through the action table at ActionTable, dispatched by Turn_RunTheHandlerIfPresent.
|
||||
|
Test whether the object is being carried.
|
||||
| Action_Pickup | 36147 | CALL ConditionIsTheObjectCarried | Call ConditionIsTheObjectCarried to test whether the object is carried. | |
| 36150 | LD HL,44561 | Point at the message "You are already carrying[0x07][0x15]" (44561). | ||
| 36153 | JP C,PrintMessage | Jump back to PrintMessage if ConditionIsTheObjectCarried found the object carried, to print "You are already carrying[0x07]". | ||
|
This entry point is used by the routine at Action_Putdown.
|
||||
| Action_Pickup_0 | 36156 | CALL Action_AddTheObjectMass | Call Action_AddTheObjectMass to add the object's mass. | |
| 36159 | LD A,(46826) | Read *CurrentCharacter. | ||
|
Find the object's record.
|
||||
| Action_Pickup_Loop | 36162 | CALL LocateObject | Call LocateObject to locate object. | |
| 36165 | LD A,(46824) | Read *CurrentObject. | ||
| 36168 | CP (IX+1) | Jump to ResponseThatWillNotWork if the character is inside the current object. | ||
| 36171 | JP Z,ResponseThatWillNotWork | |||
| 36174 | LD A,(IX+1) | Read where this object is from the object record. | ||
| 36177 | CP 255 | Jump back to Action_Pickup_Loop if where this object is is not 255. | ||
| 36179 | JR NZ,Action_Pickup_Loop | |||
| 36181 | LD IX,(46856) | Read *46856. | ||
|
If the message is held back, the object is not picked up.
|
||||
| 36185 | CALL ConditionSuppressTheMessage | Call ConditionSuppressTheMessage. If the message is held back, the object is not picked up. | ||
| 36188 | LD A,(IX+1) | Read where this object is from the object record. | ||
| 36191 | CP 18 | Compare where this object is with 18. | ||
| 36193 | LD A,(46826) | Read *CurrentCharacter. | ||
| 36196 | JR Z,Action_Pickup_TakeTheRopeInstead | Jump to Action_Pickup_TakeTheRopeInstead if where this object is is 18. | ||
| 36198 | LD (IX+1),A | Update where this object is. | ||
| 36201 | RET | Return. | ||
| Action_Pickup_TakeTheRopeInstead | 36202 | LD (50023),A | The object is tied to the rope, so give the rope (18) to the character instead. | |
| 36205 | RET | Return. | ||
| Prev: 36133 | Up: Map | Next: 36206 |