.SOFLUSH LDY #3 ; We need to zero the first 3 bytes of the sound buffer ; at SOCNT, so set a counter in Y LDA #1 ; Set A to 1 so we can reset the sound buffer to contain ; values of 1 .SOUL2 STA SOCNT-1,Y ; Zero the Y-1th byte of SOCNT DEY ; Decrement the loop counter BNE SOUL2 ; Loop back to zero the next byte until we have done all ; three from SOFLG+2 down to SOFLG .SOUR1 RTS ; Return from the subroutineName: SOFLUSH [Show more] Type: Subroutine Category: Sound Summary: Reset the sound buffers and turn off all sound channelsContext: See this subroutine in context in the source code References: This subroutine is called as follows: * stopbd calls SOFLUSH * NOISE calls via SOUR1 * NOISE2 calls via SOUR1 * NOISEOFF calls via SOUR1
Other entry points: SOUR1 Contains an RTS
[X]
Variable SOCNT in workspace Sound variables
Sound buffer for sound effect counters
[X]
Label SOUL2 is local to this routine