![]() |
Routines |
| Prev: 56944 | Up: Map | Next: 57050 |
|
Used by the routine at Move_Thrown_Weapon.
Makes a puff of dust at the position of an object, by copying the object to the record at Dust_Record and changing the type of the copy to 74. Nothing happens if that record is already in use. The puff lasts for four frames (see Handle_Dust). The routine finishes by playing a deep tone.
|
||||||||
| Make_Dust_Puff | 57016 | LD A,(36682) | Fetch the type of the dust record. | |||||
| 57019 | AND A | Return if the record is already in use. | ||||||
| 57020 | RET NZ | |||||||
| 57021 | PUSH IX | Copy the address of the object record to HL. | ||||||
| 57023 | POP HL | |||||||
| 57024 | LD DE,36682 | Point DE at Dust_Record. | ||||||
| 57027 | LD BC,15 | Set a counter of 15 bytes. | ||||||
| 57030 | LDIR | Copy the object to the dust record, except for its redraw flags. | ||||||
| 57032 | LD A,74 | Set the type of the new object to 74 which is a puff of dust. | ||||||
| 57034 | LD (36682),A | |||||||
| 57037 | LD A,4 | Set the counter in byte 8 to 4. | ||||||
| 57039 | LD (36690),A | |||||||
| 57042 | LD A,1 | Set the redraw flags to 1 so that the puff is drawn without being erased first. | ||||||
| 57044 | LD (36697),A | |||||||
| 57047 | JP SoundsBounce | Jump to SoundsBounce. | ||||||
| Prev: 56944 | Up: Map | Next: 57050 |