Prev: 27202 Up: Map Next: 27288
27251: Explode Robbie
Used by the routines at UpdateLeech, UpdateMidges and UpdateSlug.
A bug has touched Robbie. The bug explodes, and then so does Robbie: the position and state of Robbie are copied to the explosion object, and Robbie and the spray can are made inactive.
Input
IX Bug object
ExplodeRobbie 27251 CALL ExplodeBug Explode the bug using ExplodeBug.
This entry point is used by the routine at SinkFlower.
ExplodeRobbie_Flower 27254 PUSH IX Stash IX on the stack.
27256 LD IX,24292 IX=State_Explosion (the explosion object).
27260 LD HL,24172 C=the state of Robbie from State_Robbie_Active.
27263 LD C,(HL)
27264 INC HL A=the X position of Robbie.
27265 LD A,(HL)
27266 LD (IX+1),A Write it to the explosion object.
27269 INC HL A=the Y position of Robbie.
27270 LD A,(HL)
27271 LD (IX+2),A Write it to the explosion object.
27274 LD A,C A=the old state of Robbie.
27275 CALL StartExplosion Start the explosion using StartExplosion.
27278 POP IX Restore IX from the stack.
27280 XOR A Write 0 to State_Robbie_Active and State_SprayCan to make Robbie and the spray can inactive.
27281 LD (24172),A
27284 LD (24180),A
27287 RET Return.
Prev: 27202 Up: Map Next: 27288