![]() |
Routines |
| Prev: 47093 | Up: Map | Next: 47146 |
|
Used by the routine at GameOver.
Places the objects of an ending scene in the table of objects, starting at PlayerBottomObject. Each is described by five bytes: the sprite number, the flags, the colour, the pixel x position and the pixel y position. The list ends with a sprite number of zero.
|
||||||||
|
Start at the first object.
|
||||||||
| PlaceSceneObjects | 47108 | LD IY,23432 | Point IY at PlayerBottomObject. | |||||
| 47112 | LD BC,32 | Set the size of an object record to 32. | ||||||
|
Copy the next object, or return at the terminator.
|
||||||||
| PlaceSceneObjects_NextObject | 47115 | LD A,(DE) | Fetch the sprite number. | |||||
| 47116 | INC DE | Move on. | ||||||
| 47117 | AND A | Return if the list has ended. | ||||||
| 47118 | RET Z | |||||||
| 47119 | LD (IY+0),A | Set the sprite number of the object. | ||||||
| 47122 | LD A,(DE) | Fetch the flags. | ||||||
| 47123 | INC DE | Move on. | ||||||
| 47124 | LD (IY+7),A | Set the flags of the object. | ||||||
| 47127 | LD A,(DE) | Fetch the colour. | ||||||
| 47128 | INC DE | Move on. | ||||||
| 47129 | LD (IY+16),A | Set the colour of the object. | ||||||
| 47132 | LD A,(DE) | Fetch the pixel x position. | ||||||
| 47133 | INC DE | Move on. | ||||||
| 47134 | LD (IY+26),A | Set the pixel x position of the object. | ||||||
| 47137 | LD A,(DE) | Fetch the pixel y position. | ||||||
| 47138 | INC DE | Move on. | ||||||
| 47139 | LD (IY+27),A | Set the pixel y position of the object. | ||||||
| 47142 | ADD IY,BC | Move on to the next object. | ||||||
| 47144 | JR PlaceSceneObjects_NextObject | Jump to PlaceSceneObjects_NextObject. | ||||||
| Prev: 47093 | Up: Map | Next: 47146 |