![]() |
Routines |
| Prev: 46566 | Up: Map | Next: 46596 |
|
Used by the routines at HandleValve and HandleSparkle.
Plays a burst of noise for a sparkle, using bytes of the ROM from 4660 as the pitches of beeps. The number of beeps is taken from the sprite number, so it changes as the sparkle goes through its frames.
|
||||||||
|
Play a beep for each remaining frame.
|
||||||||
| PlaySparkleSound | 46574 | LD A,(IX+0) | Fetch the sprite number. | |||||
| 46577 | CPL | Invert it. | ||||||
| 46578 | AND %00011111 | Keep bits 0 to 4. | ||||||
| 46580 | LD E,A | Keep the number of beeps in E. | ||||||
| 46581 | LD HL,4660 | Point HL at 4660. | ||||||
| PlaySparkleSound_NextBeep | 46584 | LD A,(HL) | Fetch a ROM byte as the pitch. | |||||
| 46585 | INC HL | |||||||
| 46586 | LD B,A | |||||||
| 46587 | LD C,2 | Set the number of beeps to 2. | ||||||
| 46589 | CALL PlayWaveSequence | Call PlayWaveSequence. | ||||||
| 46592 | DEC E | Jump to PlaySparkleSound_NextBeep until all of the beeps have been played. | ||||||
| 46593 | JR NZ,PlaySparkleSound_NextBeep | |||||||
| 46595 | RET | Return. | ||||||
|
View the equivalent code in;
|
||||||||
| Prev: 46566 | Up: Map | Next: 46596 |