![]() |
Routines |
| Prev: 9A36 | Up: Map | Next: 9ACD |
|
Use the named object on the named target.
|
||||
| ActionUse | 9A41 | CALL Parser_ValidateDirectObject | Return if the command does not name a single object. | |
| 9A44 | RET C | |||
| 9A45 | JR ActionUse_Step1 | Continue at ActionUse_Step1 to match what the player wants to use. | ||
| ActionUse_Loop1 | 9A47 | LD HL,$7D50 | Print "It has no apparent effect." and start a new line. | |
| ActionUse_Loop2 | 9A4A | CALL PrintStringAndANewline | ||
| 9A4D | RET | Return. | ||
| ActionUse_Step1 | 9A4E | LD HL,$8B48 | Jump to ActionUse_Step8 unless the command matches the phrase at 8B48. | |
| 9A51 | CALL Parser_AdvanceToSeparator | |||
| 9A54 | JR NZ,ActionUse_Step8 | |||
| 9A56 | LD A,($6223) | Fetch the current room. | ||
| 9A59 | CP $3E | The detonator is being used from Inside a Teleport.. | ||
| 9A5B | JR Z,ActionUse_Step5 | |||
| 9A5D | LD A,$04 | Jump to ActionUse_Step2 when the player is carrying A detonator. (04). | ||
| 9A5F | CALL IsObjectCarried | |||
| 9A62 | JR Z,ActionUse_Step2 | |||
| 9A64 | LD HL,$8310 | Print "You're not carrying the detonator." and start a new line. | ||
| 9A67 | JP ActionUse_Loop2 | |||
| ActionUse_Step2 | 9A6A | LD A,$0B | Jump to ActionUse_Step4 when Some explosives. (0B) is not here or being carried. | |
| 9A6C | CALL IsObjectInCurrentRoom | |||
| 9A6F | JR NZ,ActionUse_Step4 | |||
| ActionUse_Step3 | 9A71 | LD HL,$8DB3 | Return to Game Over (GameOver) after the message. | |
| 9A74 | EX (SP),HL | |||
| 9A75 | LD HL,$8237 | Print "You were standing too close and were caught in the explosion." and start a new line. | ||
| 9A78 | JP ActionUse_Loop2 | |||
| ActionUse_Step4 | 9A7B | LD A,$0B | See where Some explosives. has been left. | |
| 9A7D | CALL GetObjectLocation | Call GetObjectLocation to read the object's location. | ||
| 9A80 | CP $19 | The explosives are not lying in The eastern end of a Long Cavern.. | ||
| 9A82 | JP NZ,ActionUse_Loop1 | |||
| 9A85 | LD A,($6223) | Fetch the current room. | ||
| 9A88 | CP $3F | The player is not in The western end of a Long Cavern.. | ||
| 9A8A | JP NZ,ActionUse_Loop1 | |||
| 9A8D | LD BC,$0B00 | Move Some explosives. (0B) to nowhere (00). | ||
| 9A90 | CALL UpdateObjectLocation | |||
| 9A93 | LD BC,$1900 | Move A pile of rocks at the eastern end. (19) to nowhere (00). | ||
| 9A96 | CALL UpdateObjectLocation | |||
| 9A99 | LD BC,$3800 | Move A pile of rocks. (38) to nowhere (00). | ||
| 9A9C | CALL UpdateObjectLocation | |||
| 9A9F | LD BC,$1A19 | Move Some shattered rocks to one side of the eastern exit. (1A) to The eastern end of a Long Cavern. (19). | ||
| 9AA2 | CALL UpdateObjectLocation | |||
| 9AA5 | LD A,$1A | Open the east exit of The eastern end of a Long Cavern. onto The Hall of the Ancients.. | ||
| 9AA7 | LD ($8BF2),A | |||
| 9AAA | LD HL,$8275 | Print "There is an explosion. The rocks are shattered, revealing an exit east." and start a new line. | ||
| 9AAD | JP ActionUse_Loop2 | |||
| ActionUse_Step5 | 9AB0 | LD A,$31 | See where A strange alien device in one corner. has been left. | |
| 9AB2 | CALL GetObjectLocation | Call GetObjectLocation to read the object's location. | ||
| 9AB5 | CP $35 | A strange alien device in one corner. is in The Alien Commander's Chamber.. | ||
| 9AB7 | JR Z,ActionUse_Step6 | |||
| 9AB9 | LD BC,$3135 | Send A strange alien device in one corner. to The Alien Commander's Chamber.. | ||
| 9ABC | JR ActionUse_Step7 | Continue at ActionUse_Step7 to move the alien device. | ||
| ActionUse_Step6 | 9ABE | LD BC,$3115 | Send A strange alien device in one corner. to The Control Room.. | |
| ActionUse_Step7 | 9AC1 | CALL UpdateObjectLocation | Call UpdateObjectLocation to move the object. | |
| 9AC4 | LD HL,$82BD | Print "There is a momentary sense of disorientation. The teleport is at another location." and start a new line. | ||
| 9AC7 | JP ActionUse_Loop2 | |||
| ActionUse_Step8 | 9ACA | JP ActionUse_Loop1 | Continue at ActionUse_Loop1 to say it has no effect. | |
| Prev: 9A36 | Up: Map | Next: 9ACD |