![]() |
Routines |
| Prev: 29285 | Up: Map | Next: 29373 |
|
Handles room 3 logic. The current level in B controls which objects are initialised or updated on each pass.
|
||||||||||||||||||||
| Handler_Room03 | 29318 | LD A,B | Copy the current level into A. | |||||||||||||||||
|
Add a helicopter for every level other than level 2.
|
||||||||||||||||||||
| 29319 | LD IX,56008 | IX=Sprite02_3Wide_X_Position. | ||||||||||||||||||
| 29323 | PUSH AF | Stash the current level on the stack. | ||||||||||||||||||
| 29324 | CP 2 | Call Handler_Helicopter if this is not level 2. | ||||||||||||||||||
| 29326 | CALL NZ,Handler_Helicopter | |||||||||||||||||||
|
Add a cat to this room for any level other than level 1.
|
||||||||||||||||||||
| 29329 | POP AF | Restore the current level from the stack. | ||||||||||||||||||
| 29330 | LD IX,56012 | IX=Sprite03_3Wide_X_Position. | ||||||||||||||||||
| 29334 | CP 1 | Is this level 1? | ||||||||||||||||||
| 29336 | PUSH AF | Stash the current level on the stack. | ||||||||||||||||||
| 29337 | CALL NZ,Handler_Cat | Call Handler_Cat if this is not level 1. | ||||||||||||||||||
|
Add a dog to this room for any level other than level 1.
|
||||||||||||||||||||
| 29340 | POP AF | Restore the current level from the stack. | ||||||||||||||||||
| 29341 | LD IX,56016 | IX=Sprite04_3Wide_X_Position. | ||||||||||||||||||
| 29345 | PUSH AF | Stash the current level on the stack. | ||||||||||||||||||
| 29346 | CP 1 | Call Handler_Dog if this is not level 1. | ||||||||||||||||||
| 29348 | CALL NZ,Handler_Dog | |||||||||||||||||||
|
Add the plane if this is level 4 or higher.
|
||||||||||||||||||||
| 29351 | POP AF | Restore the current level from the stack. | ||||||||||||||||||
| 29352 | LD IX,56024 | IX=Sprite06_3Wide_X_Position. | ||||||||||||||||||
| 29356 | CP 4 | Is this level 4? | ||||||||||||||||||
| 29358 | PUSH AF | Stash the current level on the stack. | ||||||||||||||||||
| 29359 | CALL NC,Handler_Plane | Call Handler_Plane if this is level 5 or higher. | ||||||||||||||||||
|
Add a UFO if this is level 5.
|
||||||||||||||||||||
| 29362 | POP AF | Restore the current level from the stack. | ||||||||||||||||||
| 29363 | LD IX,56028 | IX=Sprite07_3Wide_X_Position. | ||||||||||||||||||
| 29367 | CP 5 | Call Handler_UFO if this is level 5. | ||||||||||||||||||
| 29369 | CALL Z,Handler_UFO | |||||||||||||||||||
| 29372 | RET | Return. | ||||||||||||||||||
| Prev: 29285 | Up: Map | Next: 29373 |