![]() |
Routines |
| Prev: DEE8 | Up: Map | Next: DF42 |
|
Handler for the object types 4C to 4F (an explosion). It works like Handle_Dust, but the explosion starts with a counter of 09 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 | DF15 | CALL StoreEntity | Save the state of the explosion. | |||||
| DF18 | LD A,($8F1C) | Fetch the room x of Sabreman. | ||||||
| DF1B | CP (IX+$02) | Jump to Remove_Unseen_Weapon to remove the explosion if it is in a different room x. | ||||||
| DF1E | JP NZ,Remove_Unseen_Weapon | |||||||
| DF21 | LD A,($8F1E) | Fetch the room y of Sabreman. | ||||||
| DF24 | CP (IX+$04) | Jump to Remove_Unseen_Weapon to remove the explosion if it is in a different room y. | ||||||
| DF27 | JP NZ,Remove_Unseen_Weapon | |||||||
| DF2A | DEC (IX+$08) | Decrease the counter and jump to Remove_Thrown_Weapon to remove the explosion when it reaches zero. | ||||||
| DF2D | JP Z,Remove_Thrown_Weapon | |||||||
| DF30 | LD A,(IX+$08) | Fetch the counter. | ||||||
| DF33 | AND %00000011 | Keep only the two low bits. | ||||||
| DF35 | LD B,A | Store them in B. | ||||||
| DF36 | LD A,(IX+$00) | Fetch the type. | ||||||
| DF39 | AND %11111100 | Reset the two low bits. | ||||||
| DF3B | ADD A,B | Add the two low bits of the counter. | ||||||
| DF3C | LD (IX+$00),A | Store the type. | ||||||
| DF3F | JP Update_Object_Sprite | Jump to Update_Object_Sprite. | ||||||
| Prev: DEE8 | Up: Map | Next: DF42 |