| Prev: 724C | Up: Map | Next: 728B |
7259: Animate helicopter rotor
|
Renders the helicopter rotor sprite based on orientation. Uses left-facing (sprite_helicopter_rotor_left) or right-facing (sprite_helicopter_rotor_right) rotor sprite.
|
||||
| animate_helicopter | 7259 | LD HL,($5F60) | Load current_slot_ptr, extract [D, B, C] from current slot. | |
| 725C | DEC HL | |||
| 725D | LD D,(HL) | |||
| 725E | DEC HL | |||
| 725F | LD B,(HL) | |||
| 7260 | DEC HL | |||
| 7261 | LD C,(HL) | |||
| 7262 | LD HL,$8AB8 | Load left rotor sprite sprite_helicopter_rotor_left. If right-facing (bit 6 clear), load sprite_helicopter_rotor_right. | ||
| 7265 | BIT 6,D | |||
| 7267 | CALL Z,ld_sprite_helicopter_rotor_right | |||
| 726A | LD ($8B0C),BC | Store positions to object_coordinates and previous_object_coordinates. Push rotor sprite, get main sprite pointer. | ||
| 726E | LD ($8B0A),BC | |||
| 7272 | PUSH HL | |||
| 7273 | CALL ld_enemy_sprites | |||
| 7276 | LD HL,$82C5 | Store erase sprite all_ff to render_sprite_ptr. Pop rotor sprite. | ||
| 7279 | LD ($8B0E),HL | |||
| 727C | POP HL | |||
| 727D | LD DE,$020E | Render rotor: height=2, attributes=$0E, frame size=4, width=2. | ||
| 7280 | LD BC,$0004 | |||
| 7283 | LD A,$02 | |||
| 7285 | CALL render_object | |||
| 7288 | JP operate_viewport_slots | |||
| Prev: 724C | Up: Map | Next: 728B |