![]() |
Routines |
| Prev: 57064 | Up: Map | Next: 57154 |
|
Handler for the object types 76 to 79 (an explosion). It works like Handle_Dust, but the explosion starts with a counter of 9 and the two low bits of the type follow the two low bits of the counter, so the explosion goes through four frames.
|
||||||||
| Handle_Explosion | 57109 | CALL StoreEntity | Save the state of the explosion. | |||||
| 57112 | LD A,(36636) | Fetch the room x of Sabreman. | ||||||
| 57115 | CP (IX+2) | Jump to Remove_Unseen_Weapon to remove the explosion if it is in a different room x. | ||||||
| 57118 | JP NZ,Remove_Unseen_Weapon | |||||||
| 57121 | LD A,(36638) | Fetch the room y of Sabreman. | ||||||
| 57124 | CP (IX+4) | Jump to Remove_Unseen_Weapon to remove the explosion if it is in a different room y. | ||||||
| 57127 | JP NZ,Remove_Unseen_Weapon | |||||||
| 57130 | DEC (IX+8) | Decrease the counter and jump to Remove_Thrown_Weapon to remove the explosion when it reaches zero. | ||||||
| 57133 | JP Z,Remove_Thrown_Weapon | |||||||
| 57136 | LD A,(IX+8) | Fetch the counter. | ||||||
| 57139 | AND %00000011 | Keep only the two low bits. | ||||||
| 57141 | LD B,A | Store them in B. | ||||||
| 57142 | LD A,(IX+0) | Fetch the type. | ||||||
| 57145 | AND %11111100 | Reset the two low bits. | ||||||
| 57147 | ADD A,B | Add the two low bits of the counter. | ||||||
| 57148 | LD (IX+0),A | Store the type. | ||||||
| 57151 | JP Update_Object_Sprite | Jump to Update_Object_Sprite. | ||||||
| Prev: 57064 | Up: Map | Next: 57154 |