Prev: B42E Up: Map Next: B451
B441: Play Jump Sound
Used by the routine at HandleJump.
Plays the sound of the player jumping, which goes through a series of pitches.
Play 20 beeps of falling pitch.
PlayJumpSound B441 LD C,$20 Set the number of cycles.
PlayJumpSound_NextBeep B443 LD A,C Fetch the cycle counter.
B444 RRCA Rotate it to get the pitch.
B445 RRCA
B446 RRCA
B447 RRCA
B448 RRCA
B449 LD B,A Set B to the pitch.
B44A CALL PlaySquareWave Play a single cycle of the tone.
Decrease the cycle counter and loop back to PlayJumpSound_NextBeep until it is zero.
B44D DEC C Count down.
B44E JR NZ,PlayJumpSound_NextBeep Jump to PlayJumpSound_NextBeep until all of the beeps have been played.
B450 RET Return.
View the equivalent code in;
Prev: B42E Up: Map Next: B451