Routines |
Prev: 40247 | Up: Map | Next: 40343 |
Used by the routines at Action_Look, Action_Putdown, Action_Pickup, Action_Dir, Action_Talkto, Action_Shoot, Action_Inventory, 37134, Action_Attack, Action_Give, Action_Examine, ActionTie, ActionUntie, ActionBurn, ActionCapture and ActionClimbOut.
|
||||
40260 | LD A,(46842) | If 46842 is $01 then return. | ||
40263 | CP 1 | |||
40265 | RET Z | |||
40266 | INC A | Increase TODO by one and write it to 46843. | ||
40267 | LD (46843),A | |||
40270 | POP BC | |||
40271 | RET | Return. | ||
This entry point is used by the routines at Action_Attack and Action_Examine.
|
||||
40272 | LD A,(46824) | A=CurrentObject. | ||
This entry point is used by the routines at 38579 and ActionClimbOut.
|
||||
40275 | PUSH IY | Stash IY, IX and HL on the stack. | ||
40277 | PUSH IX | |||
40279 | PUSH HL | |||
40280 | CALL LocateObject | Call LocateObject. | ||
40283 | LD B,(IX+1) | B=Mother object. | ||
40286 | LD IX,49248 | Set IX to $C060 which is 3 bytes less than the start of the object table due to the following line adding $0003 and moving us on to the first record. | ||
40290 | CALL Step3ByteTable_Next | Call Step3ByteTable_Next. | ||
40293 | JR Z,40337 | Jump to 40337 if TODO. | ||
40295 | CP (IY+1) | Compare TODO, jump back to 40290 if so. | ||
40298 | JR NZ,40290 | |||
40300 | BIT 1,(IY+7) | |||
40304 | JR Z,40331 | |||
40306 | PUSH AF | |||
40307 | LD (IY+16),0 | |||
40311 | LD (IY+1),255 | |||
40315 | RES 7,(IY+7) | |||
40319 | CALL 40647 | Call 40647. | ||
40322 | LD HL,45379 | HL="evaporate(s|d|ing|es)[0x15]". | ||
40325 | CALL PrintMsg | Call PrintMsg. | ||
40328 | POP AF | |||
40329 | JR 40290 | Jump to 40290. | ||
40331 | LD (IY+1),B | |||
40334 | JP 40290 | Jump to 40290. | ||
40337 | POP HL | Restore HL, IX and IY from the stack. | ||
40338 | POP IX | |||
40340 | POP IY | |||
40342 | RET | Return. |
Prev: 40247 | Up: Map | Next: 40343 |