Prev: 42023 Up: Map Next: 42053
42040: Sounds: Fireball
Used by the routine at ThrowFireball.
Plays 8 clicks, one straight after the other. The half period of each click is the counter flipped and rotated left once.
SoundsFireball 42040 LD D,8 D=8 (the counter).
SoundsFireball_Loop 42042 LD A,D Fetch the click counter.
42043 CPL Flip the bits.
42044 RLCA Rotate left once.
42045 LD B,A Keep the half period in B.
42046 CALL SoundsClick Play a click with SoundsClick.
42049 DEC D Decrease the counter by one and loop back to SoundsFireball_Loop until all of the clicks have been played.
42050 JR NZ,SoundsFireball_Loop
42052 RET Return.
Prev: 42023 Up: Map Next: 42053