Actions

SCHG How-to

Difference between revisions of "Port Sonic 3's Sound Driver to Sonic 1"

From Sonic Retro

(fixing the sound test)
(Made it a bit more "up-to-date" and macro-ized pointers to make it understandable enough. Also corrected more than half of the bad spelling.)
Line 2: Line 2:
 
'''Updated by''' [[User:Kram1024]]
 
'''Updated by''' [[User:Kram1024]]
  
You probably saw a quick and dirty way to do this on SSRG, but lets do it the proper way, the way that sonic team would do it.
+
You probably saw a quick and dirty way to do this on SSRG, but lets do it the proper way, the way that Sonic Team would do it.
  
 
==Overview==
 
==Overview==
First off, Sonic 3's sound driver has the V_Int reloader built into it so it is not needed, some routines need replacement, sounds need fixing, and we need to replace the sounds and music.  We will be using the hivebrain version, if you wish to do it via svn version, I am sure you can come up with a way that works by seeing what changes I made in the hivebrain version.
+
First off, Sonic 3's sound driver has the V_Int reloader built into it so it is not needed. Some routines need replacement, sounds need fixing, and we need to replace the sounds and music.  We will be using the commonly used Hivebrain disasm. If you wish to do it via the up-to-date Github version, you would need to get the Hivebrain labels used in this guide and replace them with their Git equivalents. S1 Git also has a different alignment macro too, so copy and paste the Hivebrain disasm's align macro to "Macros.asm" and change it's macro label to "align2", then replace every single "align" used in this guide with "align2".
 +
 
 +
AS Users: change "incbin" to "binclude".
 +
 
 +
==Macros==
 +
Before going on with this guide, add these macros to the start of your disassembly:
 +
 
 +
<asm>
 +
; (since the DAC banks are incbin'd, this macro isn't in use)
 +
; for DAC pointers
 +
zPtrDAC: macro addr
 +
    dc.w ((((addr&$7FFF)+$8000)<<8)&$FF00)+(((addr&$7FFF)+$8000)>>8)
 +
    endm
 +
 
 +
; for special pointers in the driver itself
 +
zPtrSpec: macro addr
 +
    dc.w (((addr&$1FFF)>>$08)|((addr&$1FFF)<<$08))&$FFFF
 +
    endm
 +
 
 +
; for pointers to things that the 68k will interact with in the Z80 Driver
 +
z68kPtr: macro addr
 +
    dc.w (((addr&$FFFF)|$8000>>$08)|((addr&$FFFF)|$8000<<$08))&$FFFF
 +
    endm
 +
</asm>
  
 
==Preparing to use Sonic 3/K/3K sound system==
 
==Preparing to use Sonic 3/K/3K sound system==
The Vertical Interrupt and Horizontal Interrupt need to be fixed, since the sonic 1/2 system uses them but the Sonic 3/K/3K system doesn't.
+
The Vertical Interrupt and Horizontal Interrupt need to be fixed, Since the Sonic 1/2 system uses them but the Sonic 3/K/3K system doesn't.
  
===Removal of master V_Int branch to s1driver point===
+
===Removal of Master V_Int branch to S1's driver pointer===
 
first we will fix the vertical interrupt, by changing:
 
first we will fix the vertical interrupt, by changing:
 
<asm>
 
<asm>
Line 52: Line 75:
 
; End of function PalToCRAM
 
; End of function PalToCRAM
 
</asm>
 
</asm>
That effectively disables the sonic1 style v_int and h_int driver reloading that we will not need and prevents a nasty error down the road.
+
That effectively disables the Sonic 1/2 style V_int and H_int driver reloading that we will not need and prevents a nasty error down the road.
  
 
==Upgrading the Load Driver Routine==
 
==Upgrading the Load Driver Routine==
Okay, we disabled the sonic1 driver junk, wouldn't we want now to use the sonic3 driver instead?  Here is where we start installing it.  Locate:
+
Okay, we disabled the driver's V_Int/H_Int system, wouldn't we want now to use the sonic3 driver instead?  Here is where we start installing it.  Locate:
 
<asm>
 
<asm>
 
; ---------------------------------------------------------------------------
 
; ---------------------------------------------------------------------------
Line 208: Line 231:
 
bpl.s SkipPlaySound_Special
 
bpl.s SkipPlaySound_Special
 
</asm>
 
</asm>
Do not be alarmed about the new sound routine that was added, it is equivalent to the PlaySound_Local routine (as a matter of fact, it is identical, why sonic1 does not already have it is beyond me, since it indeed does work in sonic 1)
+
Do not be alarmed about the new sound routine that was added, it is equivalent to the PlaySound_Local routine (as a matter of fact, it is identical, why sonic1 does not already have it is beyond me, since it indeed does work in Sonic 1)
  
 
===sound playback routines===
 
===sound playback routines===
Line 2,909: Line 2,932:
 
dc.b $00,$06,$00,$09,$08,$7E
 
dc.b $00,$06,$00,$09,$08,$7E
 
dc.b $23,$66,$6F,$08,$C9
 
dc.b $23,$66,$6F,$08,$C9
dc.w ((($1300&$1FFF)>>$08)|(($1300&$1FFF)<<$08))&$FFFF
+
zPtrSpec  $1300
 
dc.b $00,$4F,$06,$00,$09,$09,$00,$00,$00
 
dc.b $00,$4F,$06,$00,$09,$09,$00,$00,$00
 
dc.b $7E,$23,$66,$6F,$C9,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00
 
dc.b $7E,$23,$66,$6F,$C9,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00
Line 2,956: Line 2,979:
 
dc.b $FE,$00
 
dc.b $FE,$00
 
dc.b $C2
 
dc.b $C2
dc.w (((Z80DefaultBankSwitch&$1FFF)>>$08)|((Z80DefaultBankSwitch&$1FFF)<<$08))&$FFFF
+
zPtrSpec Z80DefaultBankSwitch
 
dc.b $CD
 
dc.b $CD
dc.w (((Z80BankSwitch0&$1FFF)>>$08)|((Z80BankSwitch0&$1FFF)<<$08))&$FFFF
+
zPtrSpec Z80BankSwitch0
 
dc.b $18,$03
 
dc.b $18,$03
 
Z80DefaultBankSwitch:
 
Z80DefaultBankSwitch:
 
dc.b $CD
 
dc.b $CD
dc.w (((Z80BankSwitch&$1FFF)>>$08)|((Z80BankSwitch&$1FFF)<<$08))&$FFFF
+
zPtrSpec  Z80BankSwitch
 
dc.b $00,$00,$00,$00,$00
 
dc.b $00,$00,$00,$00,$00
 
Z80_0x0183:
 
Z80_0x0183:
Line 2,971: Line 2,994:
 
dc.b $3E, ((SndBank>>$0F))
 
dc.b $3E, ((SndBank>>$0F))
 
dc.b $CD
 
dc.b $CD
dc.w (((Z80BankSwitch&$1FFF)>>$08)|((Z80BankSwitch&$1FFF)<<$08))&$FFFF
+
zPtrSpec  Z80BankSwitch
 
dc.b $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
 
dc.b $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
 
dc.b $DD,$21,$F0,$1D,$06,$07,$C5,$DD,$CB,$00
 
dc.b $DD,$21,$F0,$1D,$06,$07,$C5,$DD,$CB,$00
Line 3,046: Line 3,069:
 
Z80_0x05E3:
 
Z80_0x05E3:
 
dc.b $CD
 
dc.b $CD
dc.w (((Z80BankSwitch&$1FFF)>>$08)|((Z80BankSwitch&$1FFF)<<$08))&$FFFF
+
zPtrSpec  Z80BankSwitch
 
dc.b $00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00
 
dc.b $00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00
 
dc.b $3E,$B6,$32,$02,$40,$00,$3E,$C0,$32,$03,$40
 
dc.b $3E,$B6,$32,$02,$40,$00,$3E,$C0,$32,$03,$40
Line 3,063: Line 3,086:
 
dc.b $3E, ((SndBank>>$0F))
 
dc.b $3E, ((SndBank>>$0F))
 
dc.b $CD
 
dc.b $CD
dc.w (((Z80BankSwitch&$1FFF)>>$08)|((Z80BankSwitch&$1FFF)<<$08))&$FFFF
+
zPtrSpec  Z80BankSwitch
 
dc.b $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
 
dc.b $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
 
Z80_0x06B7:
 
Z80_0x06B7:
Line 3,106: Line 3,129:
 
Z80_0x08CE:
 
Z80_0x08CE:
 
dc.b $CD
 
dc.b $CD
dc.w (((Z80BankSwitch&$1FFF)>>$08)|((Z80BankSwitch&$1FFF)<<$08))&$FFFF
+
zPtrSpec  Z80BankSwitch
 
dc.b $00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00
 
dc.b $00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00
 
Z80_0x08E0:
 
Z80_0x08E0:
Line 3,132: Line 3,155:
 
dc.b $3A,$2D,$1C,$32,$3E,$1C
 
dc.b $3A,$2D,$1C,$32,$3E,$1C
 
dc.b $CD
 
dc.b $CD
dc.w (((Z80BankSwitch&$1FFF)>>$08)|((Z80BankSwitch&$1FFF)<<$08))&$FFFF
+
zPtrSpec  Z80BankSwitch
 
dc.b $00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00
 
dc.b $00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00
 
Z80_0x0A33:
 
Z80_0x0A33:
Line 3,207: Line 3,230:
 
dc.b $3A,$3E,$1C
 
dc.b $3A,$3E,$1C
 
dc.b $CD
 
dc.b $CD
dc.w (((Z80BankSwitch&$1FFF)>>$08)|((Z80BankSwitch&$1FFF)<<$08))&$FFFF
+
zPtrSpec  Z80BankSwitch
 
dc.b $00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00
 
dc.b $00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00
 
Z80_0x0DD4:
 
Z80_0x0DD4:
Line 3,214: Line 3,237:
 
dc.b $3E,((SndBank>>$0F))
 
dc.b $3E,((SndBank>>$0F))
 
dc.b $CD
 
dc.b $CD
dc.w (((Z80BankSwitch&$1FFF)>>$08)|((Z80BankSwitch&$1FFF)<<$08))&$FFFF
+
zPtrSpec  Z80BankSwitch
 
dc.b $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
 
dc.b $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
 
dc.b $DD,$7E,$18,$B7,$F2,$FA
 
dc.b $DD,$7E,$18,$B7,$F2,$FA
Line 3,270: Line 3,293:
 
dc.b $3E,((SegaPCMBank>>$0F))
 
dc.b $3E,((SegaPCMBank>>$0F))
 
dc.b $CD
 
dc.b $CD
dc.w (((Z80BankSwitch&$1FFF)>>$08)|((Z80BankSwitch&$1FFF)<<$08))&$FFFF
+
zPtrSpec  Z80BankSwitch
 
dc.b $00,$00,$00,$00,$00,$00,$00,$00,$00
 
dc.b $00,$00,$00,$00,$00,$00,$00,$00,$00
 
dc.b $21
 
dc.b $21
dc.w (((SegaSnd&$FFFF)|$8000>>$08)|((SegaSnd&$FFFF)|$8000<<$08))&$FFFF
+
z68kPtr  SegaPCM
 
dc.b $11,$2F,$5E
 
dc.b $11,$2F,$5E
 
dc.b $3E,$2A,$32,$00,$40,$00,$7E,$32,$01,$40,$3A,$0A,$1C,$FE,$FE
 
dc.b $3E,$2A,$32,$00,$40,$00,$7E,$32,$01,$40,$3A,$0A,$1C,$FE,$FE
Line 3,349: Line 3,372:
 
dc.b 0,0,0,0,0
 
dc.b 0,0,0,0,0
 
DriverPointers:
 
DriverPointers:
dc.w (((MusicPointers&$1FFF)>>$08)|((MusicPointers&$1FFF)<<$08))&$FFFF
+
zPtrSpec MusicPointers
dc.w (((UniversalVoiceBank&$1FFF)>>$08)|((UniversalVoiceBank&$1FFF)<<$08))&$FFFF
+
zPtrSpec UniversalVoiceBank
dc.w (((MusicPointers&$1FFF)>>$08)|((MusicPointers&$1FFF)<<$08))&$FFFF
+
zPtrSpec MusicPointers
dc.w (((SndPointers&$1FFF)>>$08)|((SndPointers&$1FFF)<<$08))&$FFFF
+
zPtrSpec SndPointers
dc.w (((PSGNoisePointers&$1FFF)>>$08)|((PSGNoisePointers&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGNoisePointers
dc.w (((PSGTonePointers&$1FFF)>>$08)|((PSGTonePointers&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGTonePointers
 
dc.w $3300
 
dc.w $3300
  
 
;credit goes to Varion Icaria for finding this index
 
;credit goes to Varion Icaria for finding this index
 
PSGNoisePointers:
 
PSGNoisePointers:
dc.w (((PSGN_0&$1FFF)>>$08)|((PSGN_0&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGN_0
dc.w (((PSGN_1&$1FFF)>>$08)|((PSGN_1&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGN_1
dc.w (((PSGN_2&$1FFF)>>$08)|((PSGN_2&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGN_2
dc.w (((PSGN_3&$1FFF)>>$08)|((PSGN_3&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGN_3
dc.w (((PSGN_4&$1FFF)>>$08)|((PSGN_4&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGN_4
dc.w (((PSGN_5&$1FFF)>>$08)|((PSGN_5&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGN_5
dc.w (((PSGN_6&$1FFF)>>$08)|((PSGN_6&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGN_6
dc.w (((PSGN_7&$1FFF)>>$08)|((PSGN_7&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGN_7
  
PSGN_1: binclude sound/PSGN1.bin
+
PSGN_1: incbin sound/PSGN1.bin
PSGN_0: binclude sound/PSGN0.bin
+
PSGN_0: incbin sound/PSGN0.bin
PSGN_2: binclude sound/PSGN2.bin
+
PSGN_2: incbin sound/PSGN2.bin
PSGN_3: binclude sound/PSGN3.bin
+
PSGN_3: incbin sound/PSGN3.bin
PSGN_4: binclude sound/PSGN4.bin
+
PSGN_4: incbin sound/PSGN4.bin
PSGN_5: binclude sound/PSGN5.bin
+
PSGN_5: incbin sound/PSGN5.bin
PSGN_6: binclude sound/PSGN6.bin
+
PSGN_6: incbin sound/PSGN6.bin
PSGN_7: binclude sound/PSGN7.bin
+
PSGN_7: incbin sound/PSGN7.bin
  
 
;credit goes to Varion Icaria for finding this index
 
;credit goes to Varion Icaria for finding this index
 
PSGTonePointers:
 
PSGTonePointers:
dc.w (((PSGT_00&$1FFF)>>$08)|((PSGT_00&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_00
dc.w (((PSGT_01&$1FFF)>>$08)|((PSGT_01&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_01
dc.w (((PSGT_02&$1FFF)>>$08)|((PSGT_02&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_02
dc.w (((PSGT_03&$1FFF)>>$08)|((PSGT_03&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_03
dc.w (((PSGT_04&$1FFF)>>$08)|((PSGT_04&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_04
dc.w (((PSGT_05&$1FFF)>>$08)|((PSGT_05&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_05
dc.w (((PSGT_06&$1FFF)>>$08)|((PSGT_06&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_06
dc.w (((PSGT_07&$1FFF)>>$08)|((PSGT_07&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_07
dc.w (((PSGT_08&$1FFF)>>$08)|((PSGT_08&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_08
dc.w (((PSGT_09&$1FFF)>>$08)|((PSGT_09&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_09
dc.w (((PSGT_0A&$1FFF)>>$08)|((PSGT_0A&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_0A
dc.w (((PSGT_0B&$1FFF)>>$08)|((PSGT_0B&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_0B
dc.w (((PSGT_0C&$1FFF)>>$08)|((PSGT_0C&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_0C
dc.w (((PSGT_0D&$1FFF)>>$08)|((PSGT_0D&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_0D
dc.w (((PSGT_0E&$1FFF)>>$08)|((PSGT_0E&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_0E
dc.w (((PSGT_0F&$1FFF)>>$08)|((PSGT_0F&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_0F
dc.w (((PSGT_10&$1FFF)>>$08)|((PSGT_10&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_10
dc.w (((PSGT_11&$1FFF)>>$08)|((PSGT_11&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_11
dc.w (((PSGT_12&$1FFF)>>$08)|((PSGT_12&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_12
dc.w (((PSGT_13&$1FFF)>>$08)|((PSGT_13&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_13
dc.w (((PSGT_14&$1FFF)>>$08)|((PSGT_14&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_14
dc.w (((PSGT_15&$1FFF)>>$08)|((PSGT_15&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_15
dc.w (((PSGT_16&$1FFF)>>$08)|((PSGT_16&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_16
dc.w (((PSGT_17&$1FFF)>>$08)|((PSGT_17&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_17
dc.w (((PSGT_18&$1FFF)>>$08)|((PSGT_18&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_18
dc.w (((PSGT_19&$1FFF)>>$08)|((PSGT_19&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_19
dc.w (((PSGT_1A&$1FFF)>>$08)|((PSGT_1A&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_1A
dc.w (((PSGT_1B&$1FFF)>>$08)|((PSGT_1B&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_1B
dc.w (((PSGT_1C&$1FFF)>>$08)|((PSGT_1C&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_1C
dc.w (((PSGT_1D&$1FFF)>>$08)|((PSGT_1D&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_1D
dc.w (((PSGT_1E&$1FFF)>>$08)|((PSGT_1E&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_1E
dc.w (((PSGT_1F&$1FFF)>>$08)|((PSGT_1F&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_1F
dc.w (((PSGT_20&$1FFF)>>$08)|((PSGT_20&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_20
dc.w (((PSGT_21&$1FFF)>>$08)|((PSGT_21&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_21
dc.w (((PSGT_22&$1FFF)>>$08)|((PSGT_22&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_22
dc.w (((PSGT_23&$1FFF)>>$08)|((PSGT_23&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_23
dc.w (((PSGT_24&$1FFF)>>$08)|((PSGT_24&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_24
dc.w (((PSGT_25&$1FFF)>>$08)|((PSGT_25&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_25
dc.w (((PSGT_26&$1FFF)>>$08)|((PSGT_26&$1FFF)<<$08))&$FFFF
+
zPtrSpec PSGT_26
  
PSGT_00: binclude sound/PSGT00.bin
+
PSGT_00: incbin sound/PSGT00.bin
PSGT_01: binclude sound/PSGT01.bin
+
PSGT_01: incbin sound/PSGT01.bin
PSGT_02: binclude sound/PSGT02.bin
+
PSGT_02: incbin sound/PSGT02.bin
PSGT_03: binclude sound/PSGT03.bin
+
PSGT_03: incbin sound/PSGT03.bin
PSGT_04: binclude sound/PSGT04.bin
+
PSGT_04: incbin sound/PSGT04.bin
PSGT_05: binclude sound/PSGT05.bin
+
PSGT_05: incbin sound/PSGT05.bin
PSGT_06: binclude sound/PSGT06.bin
+
PSGT_06: incbin sound/PSGT06.bin
PSGT_07: binclude sound/PSGT07.bin
+
PSGT_07: incbin sound/PSGT07.bin
PSGT_08: binclude sound/PSGT08.bin
+
PSGT_08: incbin sound/PSGT08.bin
PSGT_09: binclude sound/PSGT09.bin
+
PSGT_09: incbin sound/PSGT09.bin
PSGT_0A: binclude sound/PSGT0A.bin
+
PSGT_0A: incbin sound/PSGT0A.bin
PSGT_0B: binclude sound/PSGT0B.bin
+
PSGT_0B: incbin sound/PSGT0B.bin
PSGT_0C: binclude sound/PSGT0C.bin
+
PSGT_0C: incbin sound/PSGT0C.bin
PSGT_0D: binclude sound/PSGT0D.bin
+
PSGT_0D: incbin sound/PSGT0D.bin
PSGT_0E: binclude sound/PSGT0E.bin
+
PSGT_0E: incbin sound/PSGT0E.bin
PSGT_0F: binclude sound/PSGT0F.bin
+
PSGT_0F: incbin sound/PSGT0F.bin
PSGT_10: binclude sound/PSGT10.bin
+
PSGT_10: incbin sound/PSGT10.bin
PSGT_11: binclude sound/PSGT11.bin
+
PSGT_11: incbin sound/PSGT11.bin
PSGT_12: binclude sound/PSGT12.bin
+
PSGT_12: incbin sound/PSGT12.bin
PSGT_13: binclude sound/PSGT13.bin
+
PSGT_13: incbin sound/PSGT13.bin
PSGT_14: binclude sound/PSGT14.bin
+
PSGT_14: incbin sound/PSGT14.bin
PSGT_15: binclude sound/PSGT15.bin
+
PSGT_15: incbin sound/PSGT15.bin
PSGT_16: binclude sound/PSGT16.bin
+
PSGT_16: incbin sound/PSGT16.bin
PSGT_17: binclude sound/PSGT17.bin
+
PSGT_17: incbin sound/PSGT17.bin
PSGT_18: binclude sound/PSGT18.bin
+
PSGT_18: incbin sound/PSGT18.bin
PSGT_19: binclude sound/PSGT19.bin
+
PSGT_19: incbin sound/PSGT19.bin
PSGT_1A: binclude sound/PSGT1A.bin
+
PSGT_1A: incbin sound/PSGT1A.bin
PSGT_1B: binclude sound/PSGT1B.bin
+
PSGT_1B: incbin sound/PSGT1B.bin
PSGT_1C: binclude sound/PSGT1C.bin
+
PSGT_1C: incbin sound/PSGT1C.bin
PSGT_1D: binclude sound/PSGT1D.bin
+
PSGT_1D: incbin sound/PSGT1D.bin
PSGT_1E: binclude sound/PSGT1E.bin
+
PSGT_1E: incbin sound/PSGT1E.bin
PSGT_1F: binclude sound/PSGT1F.bin
+
PSGT_1F: incbin sound/PSGT1F.bin
PSGT_20: binclude sound/PSGT20.bin
+
PSGT_20: incbin sound/PSGT20.bin
PSGT_21: binclude sound/PSGT21.bin
+
PSGT_21: incbin sound/PSGT21.bin
PSGT_22: binclude sound/PSGT22.bin
+
PSGT_22: incbin sound/PSGT22.bin
PSGT_23: binclude sound/PSGT23.bin
+
PSGT_23: incbin sound/PSGT23.bin
PSGT_24: binclude sound/PSGT24.bin
+
PSGT_24: incbin sound/PSGT24.bin
PSGT_25: binclude sound/PSGT25.bin
+
PSGT_25: incbin sound/PSGT25.bin
PSGT_26: binclude sound/PSGT26.bin
+
PSGT_26: incbin sound/PSGT26.bin
 
 
MB_Ptr equ (Mini_Boss_Snd&$FFFF)|$8000 ; $C71A0
 
FB_Ptr equ (Final_Boss_Snd&$FFFF)|$8000 ; $C7A61
 
AIz1_Ptr equ (Angel_Island_1_Snd&$FFFF)|$8000 ; $C8000
 
AIz2_Ptr equ (Angel_Island_2_Snd&$FFFF)|$8000 ; $C9B6D
 
HCz1_Ptr equ (Hidrocity_1_Snd&$FFFF)|$8000 ; $CB0BC
 
HCz2_Ptr equ (Hidrocity_2_Snd&$FFFF)|$8000 ; $CC0C6
 
MGz1_Ptr equ (Marble_Garden_1_Snd&$FFFF)|$8000 ; $CD364
 
MGz2_Ptr equ (Marble_Garden_2_Snd&$FFFF)|$8000 ; $CD97B
 
CNz2_Ptr equ (Carnival_Night_2_Snd&$FFFF)|$8000 ; $CDDA9
 
CNz1_Ptr equ (Carnival_Night_1_Snd&$FFFF)|$8000 ; $CE48F
 
FBz1_Ptr equ (Flying_Battery_1_Snd&$FFFF)|$8000 ; $CEBF1
 
FBz2_Ptr equ (Flying_Battery_2_Snd&$FFFF)|$8000 ; $CF189
 
TDz_Ptr equ (The_Doomsday_Snd&$FFFF)|$8000 ; $CF6F0
 
Iz2_Ptr equ (Icecap_2_Snd&$FFFF)|$8000 ; $D0000
 
Iz1_Ptr equ (Icecap_1_Snd&$FFFF)|$8000 ; $D06AA
 
LBz2_Ptr equ (Launch_Base_2_Snd&$FFFF)|$8000 ; $D0DC8
 
LBz1_Ptr equ (Launch_Base_1_Snd&$FFFF)|$8000 ; $D1345
 
MHz1_Ptr equ (Mushroom_Hill_1_Snd&$FFFF)|$8000 ; $D17A7
 
MHz2_Ptr equ (Mushroom_Hill_2_Snd&$FFFF)|$8000 ; $D1DAF
 
Sz1_Ptr equ (Sandopolis_1_Snd&$FFFF)|$8000 ; $D2331
 
Sz2_Ptr equ (Sandopolis_2_Snd&$FFFF)|$8000 ; $D299B
 
LRz1_Ptr equ (Lava_Reef_1_Snd&$FFFF)|$8000 ; $D2F8E
 
LRz2_Ptr equ (Lava_Reef_2_Snd&$FFFF)|$8000 ; $D399C
 
SCz_Ptr equ (Sky_Sanctuary_Snd&$FFFF)|$8000 ; $D4B29
 
DEz1_Ptr equ (Death_Egg_1_Snd&$FFFF)|$8000 ; $D4F4F
 
DEz2_Ptr equ (Death_Egg_2_Snd&$FFFF)|$8000 ; $D543A
 
MB_SK_Ptr equ (Mini_Boss_SK_Snd&$FFFF)|$8000 ; $D584C
 
Boss_Ptr equ (Boss_Snd&$FFFF)|$8000 ; $D5B7C
 
GS_BS_Ptr equ (Glowing_Spheres_Bonus_Stage_snd&$FFFF)|$8000 ; $D6078
 
SS_Ptr equ (Special_Stage_Snd&$FFFF)|$8000 ; $D65DB
 
LR_Ptr equ (Level_Results_Snd&$FFFF)|$8000 ; $D6E73
 
Menu_Ptr equ (Menu_Snd&$FFFF)|$8000 ; $D7027
 
SM_BS_Ptr equ (Slot_Machine_Bonus_Stage_snd&$FFFF)|$8000 ; $D8000
 
GBM_BS_Ptr equ (Gum_Ball_Machine_Bonus_Stage_snd&$FFFF)|$8000 ; $D8AE8
 
KTE_Ptr equ (Knuckles_Theme_Snd&$FFFF)|$8000 ; $D97FD
 
ALz_Ptr equ (Azure_Lake_Snd&$FFFF)|$8000 ; $D99F7
 
BPz_Ptr equ (Balloon_Park_Snd&$FFFF)|$8000 ; $DA4FD
 
DPz_Ptr equ (Desert_Palace_Snd&$FFFF)|$8000 ; $DB0EC
 
CGz_Ptr equ (Chrome_Gadget_Snd&$FFFF)|$8000 ; $DC324
 
EMz_Ptr equ (Endless_Mine_Snd&$FFFF)|$8000 ; $DDA47
 
TS_Ptr equ (Title_Screen_Snd&$FFFF)|$8000 ; $DE18F
 
Credits_Ptr equ (Credits_Snd&$FFFF)|$8000 ; $DE587
 
TGOvr_Ptr equ (Time_Game_Over_Snd&$FFFF)|$8000 ; $DEA20
 
Continue_Ptr equ (Continue_Snd&$FFFF)|$8000 ; $DEC7B
 
_1_Up_Ptr equ (Extra_Life_Snd&$FFFF)|$8000 ; $DF095
 
Emerald_Ptr equ (Emerald_Snd&$FFFF)|$8000 ; $DF298
 
Invcblty_Ptr equ (Invencibility_Snd&$FFFF)|$8000 ; $DF364
 
_2p_Menu_Ptr equ (Competition_Menu_Snd&$FFFF)|$8000 ; $DF5E4
 
UT_Ptr equ (Underwater_Timming_Snd&$FFFF)|$8000 ; $DFABE
 
PbS_Ptr equ (Presented_by_SEGA_Snd&$FFFF)|$8000 ; $DFBFE
 
 
 
Sfx_34_Ptr equ (Sfx_34_Snd&$FFFF)|$8000 ; $FDE30
 
Sfx_35_Ptr equ (Sfx_35_Snd&$FFFF)|$8000 ; $FDE5E
 
Sfx_36_Ptr equ (Sfx_36_Snd&$FFFF)|$8000 ; $FDE6F
 
Sfx_37_Ptr equ (Sfx_37_Snd&$FFFF)|$8000 ; $FDEA1
 
Sfx_38_Ptr equ (Sfx_38_Snd&$FFFF)|$8000 ; $FDEC5
 
Sfx_39_Ptr equ (Sfx_39_Snd&$FFFF)|$8000 ; $FDEF4
 
Sfx_3A_Ptr equ (Sfx_3A_Snd&$FFFF)|$8000 ; $FDF2A
 
Sfx_3B_Ptr equ (Sfx_3B_Snd&$FFFF)|$8000 ; $FDF6B
 
Sfx_3C_Ptr equ (Sfx_3C_Snd&$FFFF)|$8000 ; $FDF96
 
Sfx_3D_Ptr equ (Sfx_3D_Snd&$FFFF)|$8000 ; $FDFE5
 
Sfx_3E_Ptr equ (Sfx_3E_Snd&$FFFF)|$8000 ; $FE023
 
Sfx_3F_Ptr equ (Sfx_3F_Snd&$FFFF)|$8000 ; $FE05D
 
Sfx_40_Ptr equ (Sfx_40_Snd&$FFFF)|$8000 ; $FE088
 
Sfx_41_Ptr equ (Sfx_41_Snd&$FFFF)|$8000 ; $FE0AB
 
Sfx_42_Ptr equ (Sfx_42_Snd&$FFFF)|$8000 ; $FE0CE
 
Sfx_43_Ptr equ (Sfx_43_Snd&$FFFF)|$8000 ; $FE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B_Ptr equ (Sfx_DB_Snd&$FFFF)|$8000 ; $FFD62
 
Sfx_DC_Ptr equ (Sfx_DC_Snd&$FFFF)|$8000 ; $FFD94
 
  
 
MusicPointers:
 
MusicPointers:
dc.w ((AIz1_Ptr>>$08)|(AIz1_Ptr<<$08))&$FFFF
+
z68kPtr Angel_Island_1_Snd
dc.w ((AIz2_Ptr>>$08)|(AIz2_Ptr<<$08))&$FFFF
+
z68kPtr Angel_Island_2_Snd
dc.w ((HCz1_Ptr>>$08)|(HCz1_Ptr<<$08))&$FFFF
+
z68kPtr Hydrocity_1_Snd
dc.w ((HCz2_Ptr>>$08)|(HCz2_Ptr<<$08))&$FFFF
+
z68kPtr Hydrocity_2_Snd
dc.w ((MGz1_Ptr>>$08)|(MGz1_Ptr<<$08))&$FFFF
+
z68kPtr Marble_Garden_1_Snd
dc.w ((MGz2_Ptr>>$08)|(MGz2_Ptr<<$08))&$FFFF
+
z68kPtr Marble_Garden_2_Snd
dc.w ((CNz1_Ptr>>$08)|(CNz1_Ptr<<$08))&$FFFF
+
z68kPtr Carnival_Night_1_Snd
dc.w ((CNz2_Ptr>>$08)|(CNz2_Ptr<<$08))&$FFFF
+
z68kPtr Carnival_Night_2_Snd
dc.w ((FBz1_Ptr>>$08)|(FBz1_Ptr<<$08))&$FFFF
+
z68kPtr Flying_Battery_1_Snd
dc.w ((FBz2_Ptr>>$08)|(FBz2_Ptr<<$08))&$FFFF
+
z68kPtr Flying_Battery_2_Snd
dc.w ((Iz1_Ptr>>$08)|(Iz1_Ptr<<$08))&$FFFF
+
z68kPtr Icecap_1_Snd
dc.w ((Iz2_Ptr>>$08)|(Iz2_Ptr<<$08))&$FFFF
+
z68kPtr Icecap_2_Snd
dc.w ((LBz1_Ptr>>$08)|(LBz1_Ptr<<$08))&$FFFF
+
z68kPtr Launch_Base_1_Snd
dc.w ((LBz2_Ptr>>$08)|(LBz2_Ptr<<$08))&$FFFF
+
z68kPtr Launch_Base_2_Snd
dc.w ((MHz1_Ptr>>$08)|(MHz1_Ptr<<$08))&$FFFF
+
z68kPtr Mushroom_Hill_1_Snd
dc.w ((MHz2_Ptr>>$08)|(MHz2_Ptr<<$08))&$FFFF
+
z68kPtr Mushroom_Hill_2_Snd
dc.w ((Sz1_Ptr>>$08)|(Sz1_Ptr<<$08))&$FFFF
+
z68kPtr Sandopolis_1_Snd
dc.w ((Sz2_Ptr>>$08)|(Sz2_Ptr<<$08))&$FFFF
+
z68kPtr Sandopolis_2_Snd
dc.w ((LRz1_Ptr>>$08)|(LRz1_Ptr<<$08))&$FFFF
+
z68kPtr Lava_Reef_1_Snd
dc.w ((LRz2_Ptr>>$08)|(LRz2_Ptr<<$08))&$FFFF
+
z68kPtr Lava_Reef_2_Snd
dc.w ((SCz_Ptr>>$08)|(SCz_Ptr<<$08))&$FFFF
+
z68kPtr Sky_Sanctuary_Snd
dc.w ((DEz1_Ptr>>$08)|(DEz1_Ptr<<$08))&$FFFF
+
z68kPtr Death_Egg_1_Snd
dc.w ((DEz2_Ptr>>$08)|(DEz2_Ptr<<$08))&$FFFF
+
z68kPtr Death_Egg_2_Snd
dc.w ((MB_SK_Ptr>>$08)|(MB_SK_Ptr<<$08))&$FFFF
+
z68kPtr Mini_Boss_SK_Snd
dc.w ((Boss_Ptr>>$08)|(Boss_Ptr<<$08))&$FFFF
+
z68kPtr Boss_Snd
dc.w ((TDz_Ptr>>$08)|(TDz_Ptr<<$08))&$FFFF
+
z68kPtr The_Doomsday_Snd
dc.w ((GS_BS_Ptr>>$08)|(GS_BS_Ptr<<$08))&$FFFF
+
z68kPtr Glowing_Spheres_Bonus_Stage_snd
dc.w ((SS_Ptr>>$08)|(SS_Ptr<<$08))&$FFFF
+
z68kPtr Special_Stage_Snd
dc.w ((SM_BS_Ptr>>$08)|(SM_BS_Ptr<<$08))&$FFFF
+
z68kPtr Slot_Machine_Bonus_Stage_snd
dc.w ((GBM_BS_Ptr>>$08)|(GBM_BS_Ptr<<$08))&$FFFF
+
z68kPtr Gum_Ball_Machine_Bonus_Stage_snd
dc.w ((KTE_Ptr>>$08)|(KTE_Ptr<<$08))&$FFFF
+
z68kPtr Knuckles_Theme_Snd
dc.w ((ALz_Ptr>>$08)|(ALz_Ptr<<$08))&$FFFF
+
z68kPtr Azure_Lake_Snd
dc.w ((BPz_Ptr>>$08)|(BPz_Ptr<<$08))&$FFFF
+
z68kPtr Balloon_Park_Snd
dc.w ((DPz_Ptr>>$08)|(DPz_Ptr<<$08))&$FFFF
+
z68kPtr Desert_Palace_Snd
dc.w ((CGz_Ptr>>$08)|(CGz_Ptr<<$08))&$FFFF
+
z68kPtr Chrome_Gadget_Snd
dc.w ((EMz_Ptr>>$08)|(EMz_Ptr<<$08))&$FFFF
+
z68kPtr Endless_Mine_Snd
dc.w ((TS_Ptr>>$08)|(TS_Ptr<<$08))&$FFFF
+
z68kPtr Title_Screen_Snd
dc.w ((Credits_Ptr>>$08)|(Credits_Ptr<<$08))&$FFFF
+
z68kPtr Credits_Snd
dc.w ((TGOvr_Ptr>>$08)|(TGOvr_Ptr<<$08))&$FFFF
+
z68kPtr Time_Game_Over_Snd
dc.w ((Continue_Ptr>>$08)|(Continue_Ptr<<$08))&$FFFF
+
z68kPtr Continue_Sound
dc.w ((LR_Ptr>>$08)|(LR_Ptr<<$08))&$FFFF
+
z68kPtr Level_Results_Snd
dc.w ((_1_Up_Ptr>>$08)|(_1_Up_Ptr<<$08))&$FFFF
+
z68kPtr Extra_Life_Snd
dc.w ((Emerald_Ptr>>$08)|(Emerald_Ptr<<$08))&$FFFF
+
z68kPtr Emerald_Snd
dc.w ((Invcblty_Ptr>>$08)|(Invcblty_Ptr<<$08))&$FFFF
+
z68kPtr Invincibility_Snd
dc.w ((_2p_Menu_Ptr>>$08)|(_2p_Menu_Ptr<<$08))&$FFFF
+
z68kPtr Competition_Menu_Snd
dc.w ((MB_Ptr>>$08)|(MB_Ptr<<$08))&$FFFF
+
z68kPtr Mini_Boss_Snd
dc.w ((Menu_Ptr>>$08)|(Menu_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68kPtr Sfx_D6_Snd
dc.w ((Sfx_D7_Ptr>>$08)|(Sfx_D7_Ptr<<$08))&$FFFF
+
z68kPtr Sfx_D7_Snd
dc.w ((Sfx_D8_Ptr>>$08)|(Sfx_D8_Ptr<<$08))&$FFFF
+
z68kPtr Sfx_D8_Snd
dc.w ((Sfx_D9_Ptr>>$08)|(Sfx_D9_Ptr<<$08))&$FFFF
+
z68kPtr Sfx_D9_Snd
dc.w ((Sfx_DA_Ptr>>$08)|(Sfx_DA_Ptr<<$08))&$FFFF
+
z68kPtr Sfx_DA_Snd
dc.w ((Sfx_DB_Ptr>>$08)|(Sfx_DB_Ptr<<$08))&$FFFF
+
z68kPtr Sfx_DB_Snd
dc.w ((Sfx_DC_Ptr>>$08)|(Sfx_DC_Ptr<<$08))&$FFFF
+
z68kPtr Sfx_DC_Snd
dc.w ((Sfx_DC_Ptr>>$08)|(Sfx_DC_Ptr<<$08))&$FFFF
+
z68kPtr Sfx_DC_Snd
dc.w ((Sfx_DC_Ptr>>$08)|(Sfx_DC_Ptr<<$08))&$FFFF
+
z68kPtr Sfx_DC_Snd
dc.w ((Sfx_DC_Ptr>>$08)|(Sfx_DC_Ptr<<$08))&$FFFF
+
z68kPtr Sfx_DC_Snd
dc.w ((Sfx_DC_Ptr>>$08)|(Sfx_DC_Ptr<<$08))&$FFFF
+
z68kPtr Sfx_DC_Snd
 
DriverPointersEnd:
 
DriverPointersEnd:
  
 
UniversalVoiceBank:
 
UniversalVoiceBank:
binclude "sound/uvb.bin"
+
incbin "sound/uvb.bin"
 
UniversalVoiceBankEnd:
 
UniversalVoiceBankEnd:
 
align $8000
 
align $8000
  
 
DacBank0:
 
DacBank0:
binclude "sound/dac_0.bin"
+
incbin "sound/dac_0.bin"
  
 
align $8000
 
align $8000
 
DacBank1:
 
DacBank1:
binclude "sound/dac_1.bin"
+
incbin "sound/dac_1.bin"
 
align $8000
 
align $8000
  
 
DacBank2:
 
DacBank2:
binclude "sound/dac_2.bin"
+
incbin "sound/dac_2.bin"
 
align $8000
 
align $8000
  
 
Bank0:
 
Bank0:
binclude "sound/filler.bin"
+
incbin "sound/filler.bin"
 
Mini_Boss_Snd:
 
Mini_Boss_Snd:
binclude "sound/miniboss.snd"
+
incbin "sound/miniboss.snd"
 
Final_Boss_Snd:
 
Final_Boss_Snd:
binclude "sound/f_boss.snd"
+
incbin "sound/f_boss.snd"
 
align $8000
 
align $8000
  
 
Bank1:
 
Bank1:
 
Angel_Island_1_Snd:
 
Angel_Island_1_Snd:
binclude "sound/aiz1.snd"
+
incbin "sound/aiz1.snd"
 
Angel_Island_2_Snd:
 
Angel_Island_2_Snd:
binclude "sound/aiz2.snd"
+
incbin "sound/aiz2.snd"
Hidrocity_1_Snd:
+
Hydrocity_1_Snd:
binclude "sound/hcz1.snd"
+
incbin "sound/hcz1.snd"
Hidrocity_2_Snd:
+
Hydrocity_2_Snd:
binclude "sound/hcz2.snd"
+
incbin "sound/hcz2.snd"
 
Marble_Garden_1_Snd:
 
Marble_Garden_1_Snd:
binclude "sound/mgz1.snd"
+
incbin "sound/mgz1.snd"
 
Marble_Garden_2_Snd:
 
Marble_Garden_2_Snd:
binclude "sound/mgz2.snd"
+
incbin "sound/mgz2.snd"
 
Carnival_Night_2_Snd:
 
Carnival_Night_2_Snd:
binclude "sound/cnz2.snd"
+
incbin "sound/cnz2.snd"
 
Carnival_Night_1_Snd:
 
Carnival_Night_1_Snd:
binclude "sound/cnz1.snd"
+
incbin "sound/cnz1.snd"
 
Flying_Battery_1_Snd:
 
Flying_Battery_1_Snd:
binclude "sound/fbz1.snd"
+
incbin "sound/fbz1.snd"
 
Flying_Battery_2_Snd:
 
Flying_Battery_2_Snd:
binclude "sound/fbz2.snd"
+
incbin "sound/fbz2.snd"
 
The_Doomsday_Snd:
 
The_Doomsday_Snd:
binclude "sound/tdz.snd"
+
incbin "sound/tdz.snd"
 
align $8000
 
align $8000
  
 
Bank2:
 
Bank2:
 
Icecap_2_Snd:
 
Icecap_2_Snd:
binclude "sound/iz2.snd"
+
incbin "sound/iz2.snd"
 
Icecap_1_Snd:
 
Icecap_1_Snd:
binclude "sound/iz1.snd"
+
incbin "sound/iz1.snd"
 
Launch_Base_2_Snd:
 
Launch_Base_2_Snd:
binclude "sound/lbz2.snd"
+
incbin "sound/lbz2.snd"
 
Launch_Base_1_Snd:
 
Launch_Base_1_Snd:
binclude "sound/lbz1.snd"
+
incbin "sound/lbz1.snd"
 
Mushroom_Hill_1_Snd:
 
Mushroom_Hill_1_Snd:
binclude "sound/mhz1.snd"
+
incbin "sound/mhz1.snd"
 
Mushroom_Hill_2_Snd:
 
Mushroom_Hill_2_Snd:
binclude "sound/mhz2.snd"
+
incbin "sound/mhz2.snd"
 
Sandopolis_1_Snd:
 
Sandopolis_1_Snd:
binclude "sound/sz1.snd"
+
incbin "sound/sz1.snd"
 
Sandopolis_2_Snd:
 
Sandopolis_2_Snd:
binclude "sound/sz2.snd"
+
incbin "sound/sz2.snd"
 
Lava_Reef_1_Snd:
 
Lava_Reef_1_Snd:
binclude "sound/lrz1.snd"
+
incbin "sound/lrz1.snd"
 
Lava_Reef_2_Snd:
 
Lava_Reef_2_Snd:
binclude "sound/lrz2.snd"
+
incbin "sound/lrz2.snd"
 
Sky_Sanctuary_Snd:
 
Sky_Sanctuary_Snd:
binclude "sound/scz.snd"
+
incbin "sound/scz.snd"
 
Death_Egg_1_Snd:
 
Death_Egg_1_Snd:
binclude "sound/dez1.snd"
+
incbin "sound/dez1.snd"
 
Death_Egg_2_Snd:
 
Death_Egg_2_Snd:
binclude "sound/dez2.snd"
+
incbin "sound/dez2.snd"
 
Mini_Boss_SK_Snd:
 
Mini_Boss_SK_Snd:
binclude "sound/mb_sk.snd"
+
incbin "sound/mb_sk.snd"
 
Boss_Snd:
 
Boss_Snd:
binclude "sound/boss.snd"
+
incbin "sound/boss.snd"
 
Glowing_Spheres_Bonus_Stage_snd:
 
Glowing_Spheres_Bonus_Stage_snd:
binclude "sound/gs_bs.snd"
+
incbin "sound/gs_bs.snd"
 
Special_Stage_Snd:
 
Special_Stage_Snd:
binclude "sound/ss.snd"
+
incbin "sound/ss.snd"
 
Level_Results_Snd:
 
Level_Results_Snd:
binclude "sound/lr.snd"
+
incbin "sound/lr.snd"
 
Menu_Snd:
 
Menu_Snd:
binclude "sound/menu.snd"
+
incbin "sound/menu.snd"
 
align $8000
 
align $8000
  
 
Bank3:
 
Bank3:
 
Slot_Machine_Bonus_Stage_snd:
 
Slot_Machine_Bonus_Stage_snd:
binclude "sound/sm_bs.snd"
+
incbin "sound/sm_bs.snd"
 
Gum_Ball_Machine_Bonus_Stage_snd:
 
Gum_Ball_Machine_Bonus_Stage_snd:
binclude "sound/gbm_bs.snd"
+
incbin "sound/gbm_bs.snd"
 
Knuckles_Theme_Snd:
 
Knuckles_Theme_Snd:
binclude "sound/kte.snd"
+
incbin "sound/kte.snd"
 
Azure_Lake_Snd:
 
Azure_Lake_Snd:
binclude "sound/alz.snd"
+
incbin "sound/alz.snd"
 
Balloon_Park_Snd:
 
Balloon_Park_Snd:
binclude "sound/bpz.snd"
+
incbin "sound/bpz.snd"
 
Desert_Palace_Snd:
 
Desert_Palace_Snd:
binclude "sound/dpz.snd"
+
incbin "sound/dpz.snd"
 
Chrome_Gadget_Snd:
 
Chrome_Gadget_Snd:
binclude "sound/cgz.snd"
+
incbin "sound/cgz.snd"
 
Endless_Mine_Snd:
 
Endless_Mine_Snd:
binclude "sound/emz.snd"
+
incbin "sound/emz.snd"
 
Title_Screen_Snd:
 
Title_Screen_Snd:
binclude "sound/ts.snd"
+
incbin "sound/ts.snd"
 
Credits_Snd:
 
Credits_Snd:
binclude "sound/credits.snd"
+
incbin "sound/credits.snd"
 
Time_Game_Over_Snd:
 
Time_Game_Over_Snd:
binclude "sound/tgovr.snd"
+
incbin "sound/tgovr.snd"
 
Continue_Snd:
 
Continue_Snd:
binclude "sound/continue.snd"
+
incbin "sound/continue.snd"
 
Extra_Life_Snd:
 
Extra_Life_Snd:
binclude "sound/1up.snd"
+
incbin "sound/1up.snd"
 
Emerald_Snd:
 
Emerald_Snd:
binclude "sound/emerald.snd"
+
incbin "sound/emerald.snd"
Invencibility_Snd:
+
Invincibility_Snd:
binclude "sound/invcblty.snd"
+
incbin "sound/invcblty.snd"
 
Competition_Menu_Snd:
 
Competition_Menu_Snd:
binclude "sound/2p_menu.snd"
+
incbin "sound/2p_menu.snd"
 
Underwater_Timming_Snd:
 
Underwater_Timming_Snd:
binclude "sound/panic.snd"
+
incbin "sound/panic.snd"
 
Presented_by_SEGA_Snd:
 
Presented_by_SEGA_Snd:
binclude "sound/p_sega.snd"
+
incbin "sound/p_sega.snd"
 
align $8000
 
align $8000
  
Line 4,041: Line 3,843:
 
SegaPCMBank:
 
SegaPCMBank:
 
SegaSnd:
 
SegaSnd:
binclude "sound/sega.snd"
+
incbin "sound/sega.snd"
 
Sfx_34_Snd:
 
Sfx_34_Snd:
binclude "sound/sfx_34.snd"
+
incbin "sound/sfx_34.snd"
 
Sfx_35_Snd:
 
Sfx_35_Snd:
binclude "sound/sfx_35.snd"
+
incbin "sound/sfx_35.snd"
 
Sfx_36_Snd:
 
Sfx_36_Snd:
binclude "sound/sfx_36.snd"
+
incbin "sound/sfx_36.snd"
 
Sfx_37_Snd:
 
Sfx_37_Snd:
binclude "sound/sfx_37.snd"
+
incbin "sound/sfx_37.snd"
 
Sfx_38_Snd:
 
Sfx_38_Snd:
binclude "sound/sfx_38.snd"
+
incbin "sound/sfx_38.snd"
 
Sfx_39_Snd:
 
Sfx_39_Snd:
binclude "sound/sfx_39.snd"
+
incbin "sound/sfx_39.snd"
 
Sfx_3A_Snd:
 
Sfx_3A_Snd:
binclude "sound/sfx_3A.snd"
+
incbin "sound/sfx_3A.snd"
 
Sfx_3B_Snd:
 
Sfx_3B_Snd:
binclude "sound/sfx_3B.snd"
+
incbin "sound/sfx_3B.snd"
 
Sfx_3C_Snd:
 
Sfx_3C_Snd:
binclude "sound/sfx_3C.snd"
+
incbin "sound/sfx_3C.snd"
 
Sfx_3D_Snd:
 
Sfx_3D_Snd:
binclude "sound/sfx_3D.snd"
+
incbin "sound/sfx_3D.snd"
 
Sfx_3E_Snd:
 
Sfx_3E_Snd:
binclude "sound/sfx_3E.snd"
+
incbin "sound/sfx_3E.snd"
 
Sfx_3F_Snd:
 
Sfx_3F_Snd:
binclude "sound/sfx_3F.snd"
+
incbin "sound/sfx_3F.snd"
 
Sfx_40_Snd:
 
Sfx_40_Snd:
binclude "sound/sfx_40.snd"
+
incbin "sound/sfx_40.snd"
 
Sfx_41_Snd:
 
Sfx_41_Snd:
binclude "sound/sfx_41.snd"
+
incbin "sound/sfx_41.snd"
 
Sfx_42_Snd:
 
Sfx_42_Snd:
binclude "sound/sfx_42.snd"
+
incbin "sound/sfx_42.snd"
 
Sfx_43_Snd:
 
Sfx_43_Snd:
binclude "sound/sfx_43.snd"
+
incbin "sound/sfx_43.snd"
 
Sfx_44_Snd:
 
Sfx_44_Snd:
binclude "sound/sfx_44.snd"
+
incbin "sound/sfx_44.snd"
 
Sfx_45_Snd:
 
Sfx_45_Snd:
binclude "sound/sfx_45.snd"
+
incbin "sound/sfx_45.snd"
 
Sfx_46_Snd:
 
Sfx_46_Snd:
binclude "sound/sfx_46.snd"
+
incbin "sound/sfx_46.snd"
 
Sfx_47_Snd:
 
Sfx_47_Snd:
binclude "sound/sfx_47.snd"
+
incbin "sound/sfx_47.snd"
 
Sfx_48_Snd:
 
Sfx_48_Snd:
binclude "sound/sfx_48.snd"
+
incbin "sound/sfx_48.snd"
 
Sfx_49_Snd:
 
Sfx_49_Snd:
binclude "sound/sfx_49.snd"
+
incbin "sound/sfx_49.snd"
 
Sfx_4A_Snd:
 
Sfx_4A_Snd:
binclude "sound/sfx_4A.snd"
+
incbin "sound/sfx_4A.snd"
 
Sfx_4B_Snd:
 
Sfx_4B_Snd:
binclude "sound/sfx_4B.snd"
+
incbin "sound/sfx_4B.snd"
 
Sfx_4C_Snd:
 
Sfx_4C_Snd:
binclude "sound/sfx_4C.snd"
+
incbin "sound/sfx_4C.snd"
 
Sfx_4D_Snd:
 
Sfx_4D_Snd:
binclude "sound/sfx_4D.snd"
+
incbin "sound/sfx_4D.snd"
 
Sfx_4E_Snd:
 
Sfx_4E_Snd:
binclude "sound/sfx_4E.snd"
+
incbin "sound/sfx_4E.snd"
 
Sfx_4F_Snd:
 
Sfx_4F_Snd:
binclude "sound/sfx_4F.snd"
+
incbin "sound/sfx_4F.snd"
 
Sfx_50_Snd:
 
Sfx_50_Snd:
binclude "sound/sfx_50.snd"
+
incbin "sound/sfx_50.snd"
 
Sfx_51_Snd:
 
Sfx_51_Snd:
binclude "sound/sfx_51.snd"
+
incbin "sound/sfx_51.snd"
 
Sfx_52_Snd:
 
Sfx_52_Snd:
binclude "sound/sfx_52.snd"
+
incbin "sound/sfx_52.snd"
 
Sfx_53_Snd:
 
Sfx_53_Snd:
binclude "sound/sfx_53.snd"
+
incbin "sound/sfx_53.snd"
 
Sfx_54_Snd:
 
Sfx_54_Snd:
binclude "sound/sfx_54.snd"
+
incbin "sound/sfx_54.snd"
 
Sfx_55_Snd:
 
Sfx_55_Snd:
binclude "sound/sfx_55.snd"
+
incbin "sound/sfx_55.snd"
 
Sfx_56_Snd:
 
Sfx_56_Snd:
binclude "sound/sfx_56.snd"
+
incbin "sound/sfx_56.snd"
 
Sfx_57_Snd:
 
Sfx_57_Snd:
binclude "sound/sfx_57.snd"
+
incbin "sound/sfx_57.snd"
 
Sfx_58_Snd:
 
Sfx_58_Snd:
binclude "sound/sfx_58.snd"
+
incbin "sound/sfx_58.snd"
 
Sfx_59_Snd:
 
Sfx_59_Snd:
binclude "sound/sfx_59.snd"
+
incbin "sound/sfx_59.snd"
 
Sfx_5A_Snd:
 
Sfx_5A_Snd:
binclude "sound/sfx_5A.snd"
+
incbin "sound/sfx_5A.snd"
 
Sfx_5B_Snd:
 
Sfx_5B_Snd:
binclude "sound/sfx_5B.snd"
+
incbin "sound/sfx_5B.snd"
 
Sfx_5C_Snd:
 
Sfx_5C_Snd:
binclude "sound/sfx_5C.snd"
+
incbin "sound/sfx_5C.snd"
 
Sfx_5D_Snd:
 
Sfx_5D_Snd:
binclude "sound/sfx_5D.snd"
+
incbin "sound/sfx_5D.snd"
 
Sfx_5E_Snd:
 
Sfx_5E_Snd:
binclude "sound/sfx_5E.snd"
+
incbin "sound/sfx_5E.snd"
 
Sfx_5F_Snd:
 
Sfx_5F_Snd:
binclude "sound/sfx_5F.snd"
+
incbin "sound/sfx_5F.snd"
 
Sfx_60_Snd:
 
Sfx_60_Snd:
binclude "sound/sfx_60.snd"
+
incbin "sound/sfx_60.snd"
 
Sfx_61_Snd:
 
Sfx_61_Snd:
binclude "sound/sfx_61.snd"
+
incbin "sound/sfx_61.snd"
 
Sfx_62_Snd:
 
Sfx_62_Snd:
binclude "sound/sfx_62.snd"
+
incbin "sound/sfx_62.snd"
 
Sfx_63_Snd:
 
Sfx_63_Snd:
binclude "sound/sfx_63.snd"
+
incbin "sound/sfx_63.snd"
 
Sfx_64_Snd:
 
Sfx_64_Snd:
binclude "sound/sfx_64.snd"
+
incbin "sound/sfx_64.snd"
 
Sfx_65_Snd:
 
Sfx_65_Snd:
binclude "sound/sfx_65.snd"
+
incbin "sound/sfx_65.snd"
 
Sfx_66_Snd:
 
Sfx_66_Snd:
binclude "sound/sfx_66.snd"
+
incbin "sound/sfx_66.snd"
 
Sfx_67_Snd:
 
Sfx_67_Snd:
binclude "sound/sfx_67.snd"
+
incbin "sound/sfx_67.snd"
 
Sfx_68_Snd:
 
Sfx_68_Snd:
binclude "sound/sfx_68.snd"
+
incbin "sound/sfx_68.snd"
 
Sfx_69_Snd:
 
Sfx_69_Snd:
binclude "sound/sfx_69.snd"
+
incbin "sound/sfx_69.snd"
 
Sfx_6A_Snd:
 
Sfx_6A_Snd:
binclude "sound/sfx_6A.snd"
+
incbin "sound/sfx_6A.snd"
 
Sfx_6B_Snd:
 
Sfx_6B_Snd:
binclude "sound/sfx_6B.snd"
+
incbin "sound/sfx_6B.snd"
 
Sfx_6C_Snd:
 
Sfx_6C_Snd:
binclude "sound/sfx_6C.snd"
+
incbin "sound/sfx_6C.snd"
 
Sfx_6D_Snd:
 
Sfx_6D_Snd:
binclude "sound/sfx_6D.snd"
+
incbin "sound/sfx_6D.snd"
 
Sfx_6E_Snd:
 
Sfx_6E_Snd:
binclude "sound/sfx_6E.snd"
+
incbin "sound/sfx_6E.snd"
 
Sfx_6F_Snd:
 
Sfx_6F_Snd:
binclude "sound/sfx_6F.snd"
+
incbin "sound/sfx_6F.snd"
 
Sfx_70_Snd:
 
Sfx_70_Snd:
binclude "sound/sfx_70.snd"
+
incbin "sound/sfx_70.snd"
 
Sfx_71_Snd:
 
Sfx_71_Snd:
binclude "sound/sfx_71.snd"
+
incbin "sound/sfx_71.snd"
 
Sfx_72_Snd:
 
Sfx_72_Snd:
binclude "sound/sfx_72.snd"
+
incbin "sound/sfx_72.snd"
 
Sfx_73_Snd:
 
Sfx_73_Snd:
binclude "sound/sfx_73.snd"
+
incbin "sound/sfx_73.snd"
 
Sfx_74_Snd:
 
Sfx_74_Snd:
binclude "sound/sfx_74.snd"
+
incbin "sound/sfx_74.snd"
 
Sfx_75_Snd:
 
Sfx_75_Snd:
binclude "sound/sfx_75.snd"
+
incbin "sound/sfx_75.snd"
 
Sfx_76_Snd:
 
Sfx_76_Snd:
binclude "sound/sfx_76.snd"
+
incbin "sound/sfx_76.snd"
 
Sfx_77_Snd:
 
Sfx_77_Snd:
binclude "sound/sfx_77.snd"
+
incbin "sound/sfx_77.snd"
 
Sfx_78_Snd:
 
Sfx_78_Snd:
binclude "sound/sfx_78.snd"
+
incbin "sound/sfx_78.snd"
 
Sfx_79_Snd:
 
Sfx_79_Snd:
binclude "sound/sfx_79.snd"
+
incbin "sound/sfx_79.snd"
 
Sfx_7A_Snd:
 
Sfx_7A_Snd:
binclude "sound/sfx_7A.snd"
+
incbin "sound/sfx_7A.snd"
 
Sfx_7B_Snd:
 
Sfx_7B_Snd:
binclude "sound/sfx_7B.snd"
+
incbin "sound/sfx_7B.snd"
 
Sfx_7C_Snd:
 
Sfx_7C_Snd:
binclude "sound/sfx_7C.snd"
+
incbin "sound/sfx_7C.snd"
 
Sfx_7D_Snd:
 
Sfx_7D_Snd:
binclude "sound/sfx_7D.snd"
+
incbin "sound/sfx_7D.snd"
 
Sfx_7E_Snd:
 
Sfx_7E_Snd:
binclude "sound/sfx_7E.snd"
+
incbin "sound/sfx_7E.snd"
 
Sfx_7F_Snd:
 
Sfx_7F_Snd:
binclude "sound/sfx_7F.snd"
+
incbin "sound/sfx_7F.snd"
 
Sfx_80_Snd:
 
Sfx_80_Snd:
binclude "sound/sfx_80.snd"
+
incbin "sound/sfx_80.snd"
 
Sfx_81_Snd:
 
Sfx_81_Snd:
binclude "sound/sfx_81.snd"
+
incbin "sound/sfx_81.snd"
 
Sfx_82_Snd:
 
Sfx_82_Snd:
binclude "sound/sfx_82.snd"
+
incbin "sound/sfx_82.snd"
 
Sfx_83_Snd:
 
Sfx_83_Snd:
binclude "sound/sfx_83.snd"
+
incbin "sound/sfx_83.snd"
 
Sfx_84_Snd:
 
Sfx_84_Snd:
binclude "sound/sfx_84.snd"
+
incbin "sound/sfx_84.snd"
 
Sfx_85_Snd:
 
Sfx_85_Snd:
binclude "sound/sfx_85.snd"
+
incbin "sound/sfx_85.snd"
 
Sfx_86_Snd:
 
Sfx_86_Snd:
binclude "sound/sfx_86.snd"
+
incbin "sound/sfx_86.snd"
 
Sfx_87_Snd:
 
Sfx_87_Snd:
binclude "sound/sfx_87.snd"
+
incbin "sound/sfx_87.snd"
 
Sfx_88_Snd:
 
Sfx_88_Snd:
binclude "sound/sfx_88.snd"
+
incbin "sound/sfx_88.snd"
 
Sfx_89_Snd:
 
Sfx_89_Snd:
binclude "sound/sfx_89.snd"
+
incbin "sound/sfx_89.snd"
 
Sfx_8A_Snd:
 
Sfx_8A_Snd:
binclude "sound/sfx_8A.snd"
+
incbin "sound/sfx_8A.snd"
 
Sfx_8B_Snd:
 
Sfx_8B_Snd:
binclude "sound/sfx_8B.snd"
+
incbin "sound/sfx_8B.snd"
 
Sfx_8C_Snd:
 
Sfx_8C_Snd:
binclude "sound/sfx_8C.snd"
+
incbin "sound/sfx_8C.snd"
 
Sfx_8D_Snd:
 
Sfx_8D_Snd:
binclude "sound/sfx_8D.snd"
+
incbin "sound/sfx_8D.snd"
 
Sfx_8E_Snd:
 
Sfx_8E_Snd:
binclude "sound/sfx_8E.snd"
+
incbin "sound/sfx_8E.snd"
 
Sfx_8F_Snd:
 
Sfx_8F_Snd:
binclude "sound/sfx_8F.snd"
+
incbin "sound/sfx_8F.snd"
 
Sfx_90_Snd:
 
Sfx_90_Snd:
binclude "sound/sfx_90.snd"
+
incbin "sound/sfx_90.snd"
 
Sfx_91_Snd:
 
Sfx_91_Snd:
binclude "sound/sfx_91.snd"
+
incbin "sound/sfx_91.snd"
 
Sfx_92_Snd:
 
Sfx_92_Snd:
binclude "sound/sfx_92.snd"
+
incbin "sound/sfx_92.snd"
 
Sfx_93_Snd:
 
Sfx_93_Snd:
binclude "sound/sfx_93.snd"
+
incbin "sound/sfx_93.snd"
 
Sfx_94_Snd:
 
Sfx_94_Snd:
binclude "sound/sfx_94.snd"
+
incbin "sound/sfx_94.snd"
 
Sfx_95_Snd:
 
Sfx_95_Snd:
binclude "sound/sfx_95.snd"
+
incbin "sound/sfx_95.snd"
 
Sfx_96_Snd:
 
Sfx_96_Snd:
binclude "sound/sfx_96.snd"
+
incbin "sound/sfx_96.snd"
 
Sfx_97_Snd:
 
Sfx_97_Snd:
binclude "sound/sfx_97.snd"
+
incbin "sound/sfx_97.snd"
 
Sfx_98_Snd:
 
Sfx_98_Snd:
binclude "sound/sfx_98.snd"
+
incbin "sound/sfx_98.snd"
 
Sfx_99_Snd:
 
Sfx_99_Snd:
binclude "sound/sfx_99.snd"
+
incbin "sound/sfx_99.snd"
 
Sfx_9A_Snd:
 
Sfx_9A_Snd:
binclude "sound/sfx_9A.snd"
+
incbin "sound/sfx_9A.snd"
 
Sfx_9B_Snd:
 
Sfx_9B_Snd:
binclude "sound/sfx_9B.snd"
+
incbin "sound/sfx_9B.snd"
 
Sfx_9C_Snd:
 
Sfx_9C_Snd:
binclude "sound/sfx_9C.snd"
+
incbin "sound/sfx_9C.snd"
 
Sfx_9D_Snd:
 
Sfx_9D_Snd:
binclude "sound/sfx_9D.snd"
+
incbin "sound/sfx_9D.snd"
 
Sfx_9E_Snd:
 
Sfx_9E_Snd:
binclude "sound/sfx_9E.snd"
+
incbin "sound/sfx_9E.snd"
 
Sfx_9F_Snd:
 
Sfx_9F_Snd:
binclude "sound/sfx_9F.snd"
+
incbin "sound/sfx_9F.snd"
 
Sfx_A0_Snd:
 
Sfx_A0_Snd:
binclude "sound/sfx_A0.snd"
+
incbin "sound/sfx_A0.snd"
 
Sfx_A1_Snd:
 
Sfx_A1_Snd:
binclude "sound/sfx_A1.snd"
+
incbin "sound/sfx_A1.snd"
 
Sfx_A2_Snd:
 
Sfx_A2_Snd:
binclude "sound/sfx_A2.snd"
+
incbin "sound/sfx_A2.snd"
 
Sfx_A3_Snd:
 
Sfx_A3_Snd:
binclude "sound/sfx_A3.snd"
+
incbin "sound/sfx_A3.snd"
 
Sfx_A4_Snd:
 
Sfx_A4_Snd:
binclude "sound/sfx_A4.snd"
+
incbin "sound/sfx_A4.snd"
 
Sfx_A5_Snd:
 
Sfx_A5_Snd:
binclude "sound/sfx_A5.snd"
+
incbin "sound/sfx_A5.snd"
 
Sfx_A6_Snd:
 
Sfx_A6_Snd:
binclude "sound/sfx_A6.snd"
+
incbin "sound/sfx_A6.snd"
 
Sfx_A7_Snd:
 
Sfx_A7_Snd:
binclude "sound/sfx_A7.snd"
+
incbin "sound/sfx_A7.snd"
 
Sfx_A8_Snd:
 
Sfx_A8_Snd:
binclude "sound/sfx_A8.snd"
+
incbin "sound/sfx_A8.snd"
 
Sfx_A9_Snd:
 
Sfx_A9_Snd:
binclude "sound/sfx_A9.snd"
+
incbin "sound/sfx_A9.snd"
 
Sfx_AA_Snd:
 
Sfx_AA_Snd:
binclude "sound/sfx_AA.snd"
+
incbin "sound/sfx_AA.snd"
 
Sfx_AB_Snd:
 
Sfx_AB_Snd:
binclude "sound/sfx_AB.snd"
+
incbin "sound/sfx_AB.snd"
 
Sfx_AC_Snd:
 
Sfx_AC_Snd:
binclude "sound/sfx_AC.snd"
+
incbin "sound/sfx_AC.snd"
 
Sfx_AD_Snd:
 
Sfx_AD_Snd:
binclude "sound/sfx_AD.snd"
+
incbin "sound/sfx_AD.snd"
 
Sfx_AE_Snd:
 
Sfx_AE_Snd:
binclude "sound/sfx_AE.snd"
+
incbin "sound/sfx_AE.snd"
 
Sfx_AF_Snd:
 
Sfx_AF_Snd:
binclude "sound/sfx_AF.snd"
+
incbin "sound/sfx_AF.snd"
 
Sfx_B0_Snd:
 
Sfx_B0_Snd:
binclude "sound/sfx_B0.snd"
+
incbin "sound/sfx_B0.snd"
 
Sfx_B1_Snd:
 
Sfx_B1_Snd:
binclude "sound/sfx_B1.snd"
+
incbin "sound/sfx_B1.snd"
 
Sfx_B2_Snd:
 
Sfx_B2_Snd:
binclude "sound/sfx_B2.snd"
+
incbin "sound/sfx_B2.snd"
 
Sfx_B3_Snd:
 
Sfx_B3_Snd:
binclude "sound/sfx_B3.snd"
+
incbin "sound/sfx_B3.snd"
 
Sfx_B4_Snd:
 
Sfx_B4_Snd:
binclude "sound/sfx_B4.snd"
+
incbin "sound/sfx_B4.snd"
 
Sfx_B5_Snd:
 
Sfx_B5_Snd:
binclude "sound/sfx_B5.snd"
+
incbin "sound/sfx_B5.snd"
 
Sfx_B6_Snd:
 
Sfx_B6_Snd:
binclude "sound/sfx_B6.snd"
+
incbin "sound/sfx_B6.snd"
 
Sfx_B7_Snd:
 
Sfx_B7_Snd:
binclude "sound/sfx_B7.snd"
+
incbin "sound/sfx_B7.snd"
 
Sfx_B8_Snd:
 
Sfx_B8_Snd:
binclude "sound/sfx_B8.snd"
+
incbin "sound/sfx_B8.snd"
 
Sfx_B9_Snd:
 
Sfx_B9_Snd:
binclude "sound/sfx_B9.snd"
+
incbin "sound/sfx_B9.snd"
 
Sfx_BA_Snd:
 
Sfx_BA_Snd:
binclude "sound/sfx_BA.snd"
+
incbin "sound/sfx_BA.snd"
 
Sfx_BB_Snd:
 
Sfx_BB_Snd:
binclude "sound/sfx_BB.snd"
+
incbin "sound/sfx_BB.snd"
 
Sfx_BC_Snd:
 
Sfx_BC_Snd:
binclude "sound/sfx_BC.snd"
+
incbin "sound/sfx_BC.snd"
 
Sfx_BD_Snd:
 
Sfx_BD_Snd:
binclude "sound/sfx_BD.snd"
+
incbin "sound/sfx_BD.snd"
 
Sfx_BE_Snd:
 
Sfx_BE_Snd:
binclude "sound/sfx_BE.snd"
+
incbin "sound/sfx_BE.snd"
 
Sfx_BF_Snd:
 
Sfx_BF_Snd:
binclude "sound/sfx_BF.snd"
+
incbin "sound/sfx_BF.snd"
 
Sfx_C0_Snd:
 
Sfx_C0_Snd:
binclude "sound/sfx_C0.snd"
+
incbin "sound/sfx_C0.snd"
 
Sfx_C1_Snd:
 
Sfx_C1_Snd:
binclude "sound/sfx_C1.snd"
+
incbin "sound/sfx_C1.snd"
 
Sfx_C2_Snd:
 
Sfx_C2_Snd:
binclude "sound/sfx_C2.snd"
+
incbin "sound/sfx_C2.snd"
 
Sfx_C3_Snd:
 
Sfx_C3_Snd:
binclude "sound/sfx_C3.snd"
+
incbin "sound/sfx_C3.snd"
 
Sfx_C4_Snd:
 
Sfx_C4_Snd:
binclude "sound/sfx_C4.snd"
+
incbin "sound/sfx_C4.snd"
 
Sfx_C5_Snd:
 
Sfx_C5_Snd:
binclude "sound/sfx_C5.snd"
+
incbin "sound/sfx_C5.snd"
 
Sfx_C6_Snd:
 
Sfx_C6_Snd:
binclude "sound/sfx_C6.snd"
+
incbin "sound/sfx_C6.snd"
 
Sfx_C7_Snd:
 
Sfx_C7_Snd:
binclude "sound/sfx_C7.snd"
+
incbin "sound/sfx_C7.snd"
 
Sfx_C8_Snd:
 
Sfx_C8_Snd:
binclude "sound/sfx_C8.snd"
+
incbin "sound/sfx_C8.snd"
 
Sfx_C9_Snd:
 
Sfx_C9_Snd:
binclude "sound/sfx_C9.snd"
+
incbin "sound/sfx_C9.snd"
 
Sfx_CA_Snd:
 
Sfx_CA_Snd:
binclude "sound/sfx_CA.snd"
+
incbin "sound/sfx_CA.snd"
 
Sfx_CB_Snd:
 
Sfx_CB_Snd:
binclude "sound/sfx_CB.snd"
+
incbin "sound/sfx_CB.snd"
 
Sfx_CC_Snd:
 
Sfx_CC_Snd:
binclude "sound/sfx_CC.snd"
+
incbin "sound/sfx_CC.snd"
 
Sfx_CD_Snd:
 
Sfx_CD_Snd:
binclude "sound/sfx_CD.snd"
+
incbin "sound/sfx_CD.snd"
 
Sfx_CE_Snd:
 
Sfx_CE_Snd:
binclude "sound/sfx_CE.snd"
+
incbin "sound/sfx_CE.snd"
 
Sfx_CF_Snd:
 
Sfx_CF_Snd:
binclude "sound/sfx_CF.snd"
+
incbin "sound/sfx_CF.snd"
 
Sfx_D0_Snd:
 
Sfx_D0_Snd:
binclude "sound/sfx_D0.snd"
+
incbin "sound/sfx_D0.snd"
 
Sfx_D1_Snd:
 
Sfx_D1_Snd:
binclude "sound/sfx_D1.snd"
+
incbin "sound/sfx_D1.snd"
 
Sfx_D2_Snd:
 
Sfx_D2_Snd:
binclude "sound/sfx_D2.snd"
+
incbin "sound/sfx_D2.snd"
 
Sfx_D3_Snd:
 
Sfx_D3_Snd:
binclude "sound/sfx_D3.snd"
+
incbin "sound/sfx_D3.snd"
 
Sfx_D4_Snd:
 
Sfx_D4_Snd:
binclude "sound/sfx_D4.snd"
+
incbin "sound/sfx_D4.snd"
 
Sfx_D5_Snd:
 
Sfx_D5_Snd:
binclude "sound/sfx_D5.snd"
+
incbin "sound/sfx_D5.snd"
 
Sfx_D6_Snd:
 
Sfx_D6_Snd:
binclude "sound/sfx_D6.snd"
+
incbin "sound/sfx_D6.snd"
 
Sfx_D7_Snd:
 
Sfx_D7_Snd:
binclude "sound/sfx_D7.snd"
+
incbin "sound/sfx_D7.snd"
 
Sfx_D8_Snd:
 
Sfx_D8_Snd:
binclude "sound/sfx_D8.snd"
+
incbin "sound/sfx_D8.snd"
 
Sfx_D9_Snd:
 
Sfx_D9_Snd:
binclude "sound/sfx_D9.snd"
+
incbin "sound/sfx_D9.snd"
 
Sfx_DA_Snd:
 
Sfx_DA_Snd:
binclude "sound/sfx_DA.snd"
+
incbin "sound/sfx_DA.snd"
 
Sfx_DB_Snd:
 
Sfx_DB_Snd:
binclude "sound/sfx_DB.snd"
+
incbin "sound/sfx_DB.snd"
 
Sfx_DC_Snd:
 
Sfx_DC_Snd:
binclude "sound/sfx_DC.snd"
+
incbin "sound/sfx_DC.snd"
 
</asm>
 
</asm>
  
 
===Driver data files===
 
===Driver data files===
then unpack this into the sound folder and optionally remove the original files since we no longer need them anymore:
+
Then unpack this into the sound folder, and remove the original files since we no longer need them anymore:
 
{{Download|file=s3driverdata.7z|filesize=131kb|title=The Sonic 3 Driver data files|plural=1}}
 
{{Download|file=s3driverdata.7z|filesize=131kb|title=The Sonic 3 Driver data files|plural=1}}
  
 
==Enabling Sonic 2 / 3 Level Music Memory==
 
==Enabling Sonic 2 / 3 Level Music Memory==
Doing this is optional as it has little to do with the driver itself, but is a very useful and quick hack that makes life a lot easier for the more painful phase of using a massively different sound system than before, fixing the freaken sound.  Sonic1 uses a second index for restoring music as opposed to actually memorizing it like later sonic games do.
+
Doing this is optional as it has little to do with the driver itself, but is a very useful and quick hack that makes life a lot easier for the more painful phase of using a massively different sound system than before, fixing the freaken sound.  Sonic 1 uses a second index for restoring music as opposed to actually memorizing it like later sonic games do.
  
 
First we will locate:
 
First we will locate:
Line 4,466: Line 4,268:
  
 
==Fixing the Music Playlist==
 
==Fixing the Music Playlist==
Okay, so we now have a working sonic3 driver, but we have yet to fix the music playlist it is still pointing to sound effects.
+
Okay, so we now have working Sound/Music, but we have yet to fix the music playlist it is still pointing to sound effects.
 
Open ''misc\muslist1.bin'' in your favorite hex editor.<p>
 
Open ''misc\muslist1.bin'' in your favorite hex editor.<p>
 
You will find that it reads:
 
You will find that it reads:
Line 4,483: Line 4,285:
 
| '''01 04 13 0D 07 16 30 00'''
 
| '''01 04 13 0D 07 16 30 00'''
 
|}
 
|}
Once you rebuild your rom, you will have some music on the levels, but sound effects and some other musics unrelated to the playlist will need fixing.  This part is much easier fixing if you applied the sonic2 memory fix to your hack, otherwise edit ''misc/muslist2.bin'' and make the exact same changes.
+
Once you rebuild your rom, you will have some music on the levels, but sound effects and some other musics unrelated to the playlist will need fixing.  This part is much easier fixing if you applied the Sonic 2 memory fix to your hack, otherwise edit ''misc/muslist2.bin'' and make the exact same changes.
  
 
==Fixing the Sneaker==
 
==Fixing the Sneaker==
Line 4,613: Line 4,415:
  
 
===Music fade out on demo exit ala Sonic 3===
 
===Music fade out on demo exit ala Sonic 3===
that fixes a spot in the level select, which we will work on later. For now locate:
+
That fixes a spot in the level select, which we will work on later. For now locate:
 
<asm>
 
<asm>
 
loc_33E4: ; XREF: Demo
 
loc_33E4: ; XREF: Demo
Line 4,677: Line 4,479:
 
bsr.w PlaySound_Special ; fade out music
 
bsr.w PlaySound_Special ; fade out music
 
</asm>
 
</asm>
okay, that should fix all the music fades between screens, but still there are yet more fixes to be made.
+
Okay, that should fix all the music fades between screens, but still there are yet more fixes to be made.
  
==Fixing the SEGA! sound==
+
==Fixing the SEGA sound==
Want to hear the SEGA! pcm when you should?  Well this section is for you then.  Go find:
+
Want to hear the SEGA PCM when you should?  Well this section is for you then.  Go find:
 
<asm>
 
<asm>
 
Sega_WaitPallet:
 
Sega_WaitPallet:
Line 4,737: Line 4,539:
 
</asm>
 
</asm>
  
that fixes the title screen's music so that it plays sonic 3 title screen music, or you can pick another music if you so choose.
+
That fixes the title screen's music so that it plays Sonic 3 Title Screen music, or you can pick another music if you so choose.
  
 
==Fixing the Special Stage music==
 
==Fixing the Special Stage music==
now that the title screen plays the right music, lets fix the special stage music.  We simply want to locate:
+
Now that the title screen plays the right music, lets fix the Special Stage music.  We simply want to locate:
 
<asm>
 
<asm>
 
SS_ClrNemRam:
 
SS_ClrNemRam:
Line 4,812: Line 4,614:
 
move.b #1,($FFFFFFFA).w ; enable debug mode
 
move.b #1,($FFFFFFFA).w ; enable debug mode
 
</asm>
 
</asm>
now we have sonic 3 special stage music on the sonic 1 special stage.  Or you could choose a different song of your choice.
+
Now we have Sonic 3 Special Stage music on the special stage.  Or you could choose a different song of your choice.
  
 
==Fixing the Ending Sequence music==
 
==Fixing the Ending Sequence music==
now time to fix the music for the ending sequence.  Find:
+
Now it's time to fix the music for the ending sequence.  Find:
 
<asm>
 
<asm>
 
End_LoadData:
 
End_LoadData:
Line 4,863: Line 4,665:
 
move.b #1,($FFFFFFFA).w ; enable debug mode
 
move.b #1,($FFFFFFFA).w ; enable debug mode
 
</asm>
 
</asm>
that makes it so that sonic 3 ending sequence music plays.  Or you could choose a different music.
+
That makes it so that Sonic 3 ending sequence music plays.  Or you could choose a different music.
  
 
==Fixing the Credits music==
 
==Fixing the Credits music==
time to fix the credits music, this time it needs to be fixed in multiple places.  First we find:
+
Time to fix the credits music, but it needs to be fixed in multiple places.  First we find:
 
<asm>
 
<asm>
 
LevSel_Credits: ; XREF: LevelSelect
 
LevSel_Credits: ; XREF: LevelSelect
Line 4,931: Line 4,733:
 
</asm>
 
</asm>
  
That fixes the credits music with sonic 3 credits music, otherwise you could use a different song if you choose.
+
That fixes the credits music with Sonic 3 credits music, otherwise you could use a different song if you choose.
  
 
==Fixing Special Event sound==
 
==Fixing Special Event sound==
 
===Chaos Emerald===
 
===Chaos Emerald===
time to fix sound for events that only happen in certain situations, i.e. end of level, game over / time over, extra life and such.  first we will start with the chaos emerald collection sound, go and find:
+
Time to fix sound for events that only happen in certain situations, i.e. end of level, game over / time over, extra life and such.  first we will start with the Chaos Emerald Collection SFX. Go and find:
 
<asm>
 
<asm>
 
Obj09_NoEmer:
 
Obj09_NoEmer:
Line 4,953: Line 4,755:
  
 
===Game Over / Time Over===
 
===Game Over / Time Over===
next we will start with Game Over / Time Over, go and find:
+
Next, we will start with Game Over / Time Over, go and find:
 
<asm>
 
<asm>
 
loc_138C2:
 
loc_138C2:
Line 4,969: Line 4,771:
 
jmp (LoadPLC).l ; load game over patterns
 
jmp (LoadPLC).l ; load game over patterns
 
</asm>
 
</asm>
===Sonic has passed Music===
+
==="Sonic has Passed" Music===
that causes the Game Over and Time Over screens to use its sonic 3 version or you could choose a different song if you wish.  Now we will go on to End of level Results.  Find:
+
That causes the Game Over and Time Over screens to use its Sonic 3 version or you could choose a different song if you wish.  Now we will go on to End of level Results.  Find:
 
<asm>
 
<asm>
 
move.w ($FFFFFE20).w,d0
 
move.w ($FFFFFE20).w,d0
Line 5,019: Line 4,821:
 
</asm>
 
</asm>
 
===1up Sound===
 
===1up Sound===
that fixes the end of level and end of special stage results music by using modern version, but you could use a different song if you wish.  Next we will fix the extra life sound, so find:
+
That fixes the End of Level and end of Special Stage results music by using modern version, but you could use a different song if you wish.  Next we will fix the Extra Life sound, so find:
 
<asm>
 
<asm>
 
loc_9CA4:
 
loc_9CA4:
Line 5,070: Line 4,872:
 
</asm>
 
</asm>
 
===Stars Monitor===
 
===Stars Monitor===
That fixes the extra life sound with the sonic3 version, though I am sure you could use a different one in a different slot if such thing exists.  Time to fix the invincibinity music, so find:
+
That fixes the extra life sound with the Sonic 3 version, though I am sure you could use a different one in a different slot if such thing exists.  Time to fix the invincibility music, so find:
 
<asm>
 
<asm>
 
Obj2E_ChkInvinc:
 
Obj2E_ChkInvinc:
Line 5,111: Line 4,913:
 
</asm>
 
</asm>
 
===Extra Continue sound===
 
===Extra Continue sound===
that fixes the invincibility sound with the sonic3 version, but you could choose a different one if you wish.  Next we will fix the get a continue sound, so find:
+
That fixes the invincibility sound with the Sonic 3 version, but you could choose a different one if you wish.  Next we will fix the get a continue sound, so find:
 
<asm>
 
<asm>
 
Obj7E_Continue: ; XREF: Obj7E_Index
 
Obj7E_Continue: ; XREF: Obj7E_Index
Line 5,158: Line 4,960:
 
</asm>
 
</asm>
 
===Continue screen music===
 
===Continue screen music===
that fixes the extra continue sound that plays on both the end result screen and in the special stage.  How about fixing the music for the continue screen itself?  That is what we are doing next, so find:
+
That fixes the extra continue sound that plays on both the End Result screen and in the Special Stage.  How about fixing the music for the continue screen itself?  That is what we are doing next, so find:
 
<asm>
 
<asm>
 
jsr (ContScrCounter).l ; run countdown (start from 10)
 
jsr (ContScrCounter).l ; run countdown (start from 10)
Line 5,175: Line 4,977:
 
</asm>
 
</asm>
 
===Special Stage entrance/exit===
 
===Special Stage entrance/exit===
that fixes the continue screen music.  Though you could choose a different song if you wish.  Time to fix the special stage entry sound, so find:
+
That fixes the Continue Screen music.  Though you could choose a different song if you wish.  Time to fix the special stage entry sound, so find:
 
<asm>
 
<asm>
 
SpecialStage: ; XREF: GameModeArray
 
SpecialStage: ; XREF: GameModeArray
Line 5,224: Line 5,026:
 
</asm>
 
</asm>
 
===Boss music===
 
===Boss music===
on entry and exit, the special stage should now play the correct sound.  Time to fix the boss music, so find:
+
On entry and exit, the Special Stage should now play the correct sound.  Time to fix the boss music, so find:
 
<asm>
 
<asm>
 
loc_6ED0:
 
loc_6ED0:
Line 5,286: Line 5,088:
  
 
===GHZ3 music restore, the modern way===
 
===GHZ3 music restore, the modern way===
I not that long ago remembered that since sonic1 does not have music memory support, the game's way of playing the previous song is hard coded, so we need to fix that since we added memory support earlier, so find:
+
I not that long ago remembered that since Sonic 1 does not have music memory support, the game's way of playing the previous song is hard coded, so we need to fix that since we added Memory Support earlier, so find:
 
<asm>
 
<asm>
 
loc_179E0:
 
loc_179E0:
Line 5,302: Line 5,104:
  
 
===LZ3 music restore, the modern way===
 
===LZ3 music restore, the modern way===
now find:
+
Now find:
 
<asm>
 
<asm>
 
loc_18112:
 
loc_18112:
Line 5,316: Line 5,118:
  
 
===MZ3 music restore, the modern way===
 
===MZ3 music restore, the modern way===
now find:
+
Now find:
 
<asm>
 
<asm>
 
loc_1856C:
 
loc_1856C:
Line 5,332: Line 5,134:
  
 
===SLZ3 music restore, the modern way===
 
===SLZ3 music restore, the modern way===
now find:
+
Now find:
 
<asm>
 
<asm>
 
loc_18BB4:
 
loc_18BB4:
Line 5,348: Line 5,150:
  
 
===SYZ3 music restore, the modern way===
 
===SYZ3 music restore, the modern way===
find:
+
Find:
 
<asm>
 
<asm>
 
loc_194E0:
 
loc_194E0:
Line 5,363: Line 5,165:
 
</asm>
 
</asm>
  
===SBZ2 Cut scene, Sonic & Knuckles style===
+
===SBZ2 cutscene, Sonic & Knuckles style===
that fixes the boss music, though you could choose different music per-level if you wish within this part of the how-to.  Next we will fix the cut scene just before SBZ3, and I would choose to have that music be SBZ music, to have an effect like the cut scenes in s&k.  So find:
+
That fixes the boss music, though you could choose different music per-level if you wish within this part of the how-to.  Next we will fix the cutscene just before SBZ3, and I would choose to have that music be SBZ music, to have an effect like the cut scenes in S&K.  So find:
 
<asm>
 
<asm>
 
Obj3A_SBZ2: ; XREF: Obj3A_ChkPos2
 
Obj3A_SBZ2: ; XREF: Obj3A_ChkPos2
Line 5,374: Line 5,176:
 
jmp (PlaySound).l ; play FZ music
 
jmp (PlaySound).l ; play FZ music
 
</asm>
 
</asm>
and change it to
+
and change it to:
 
<asm>
 
<asm>
 
Obj3A_SBZ2: ; XREF: Obj3A_ChkPos2
 
Obj3A_SBZ2: ; XREF: Obj3A_ChkPos2
Line 5,386: Line 5,188:
  
 
===Air countdown music===
 
===Air countdown music===
that causes the game to use whatever music the level started with, but now we need to fix the air counter music, so find:
+
That causes the game to use whatever music the level started with, but now we need to fix the air counter music, so find:
 
<asm>
 
<asm>
 
move.w #$92,d0
 
move.w #$92,d0
Line 5,400: Line 5,202:
 
loc_13F02:
 
loc_13F02:
 
</asm>
 
</asm>
this uses the sonic 3 version of the underwater counter music, or you can use a custom one in a location of your own choice.  Now lets fix the sound effects.
+
This uses the sonic 3 version of the underwater counter music, or you can use a custom one in a location of your own choice.  Now lets fix the sound effects.
  
 
==Fixing the sound effects so that they sound right, or at least close to right==
 
==Fixing the sound effects so that they sound right, or at least close to right==
Line 5,639: Line 5,441:
 
</asm>
 
</asm>
 
===Sound $A1===
 
===Sound $A1===
the jump sound should now be what it is supposed to be, so we fix the lamp post next, so find:
+
The jump sound should now be what it is supposed to be, so we fix the lamp post next, so find:
 
<asm>
 
<asm>
 
Obj79_HitLamp:
 
Obj79_HitLamp:
Line 5,672: Line 5,474:
 
</asm>
 
</asm>
 
===Sound $A2===
 
===Sound $A2===
Sound $A2 is not used in sonic 1, so it will be skipped.
+
Sound $A2 is not used in Sonic 1, so it will be skipped.
 
===Sound $A3===
 
===Sound $A3===
 
that makes the lamp post sound correct, so lets fix the normal damage sound.  Find:
 
that makes the lamp post sound correct, so lets fix the normal damage sound.  Find:
Line 5,710: Line 5,512:
  
 
===Sound $A4===
 
===Sound $A4===
seems we have the hurt sound working, but now we fix the skid and stop sound, so find:
+
Seems we have the hurt sound working, but now we fix the skid and stop sound, so find:
 
<asm>
 
<asm>
 
move.w #$A4,d0
 
move.w #$A4,d0
Line 5,739: Line 5,541:
 
</asm>
 
</asm>
 
===Sound $A5===
 
===Sound $A5===
now sonic skids right, but we need to fix another sound.  Find:
+
Now Sonic skids right, but we need to fix another sound.  Find:
 
<asm>
 
<asm>
 
move.w #$A5,d0
 
move.w #$A5,d0
Line 5,754: Line 5,556:
 
</asm>
 
</asm>
 
===Sound $A6===
 
===Sound $A6===
now find:
+
Now find:
 
<asm>
 
<asm>
 
move.w #$A6,d0 ; load spikes damage sound
 
move.w #$A6,d0 ; load spikes damage sound
Line 5,772: Line 5,574:
 
rts
 
rts
 
</asm>
 
</asm>
now find:
+
Now find:
 
<asm>
 
<asm>
 
move.w #$A3,d0 ; play normal death sound
 
move.w #$A3,d0 ; play normal death sound
Line 5,793: Line 5,595:
 
</asm>
 
</asm>
 
===Sound $A7===
 
===Sound $A7===
now find:
+
Now find:
 
<asm>
 
<asm>
 
loc_C294:
 
loc_C294:
Line 5,816: Line 5,618:
 
</asm>
 
</asm>
 
===Sound $A8===
 
===Sound $A8===
now find:
+
Now find:
 
<asm>
 
<asm>
 
move.w #$A8,d0
 
move.w #$A8,d0
Line 5,832: Line 5,634:
 
jmp (DisplaySprite).l
 
jmp (DisplaySprite).l
 
</asm>
 
</asm>
now find:
+
Now find:
 
<asm>
 
<asm>
 
move.w #$A8,d0
 
move.w #$A8,d0
Line 5,848: Line 5,650:
 
rts
 
rts
 
</asm>
 
</asm>
now find:
+
Now find:
 
<asm>
 
<asm>
 
Obj09_GOAL:
 
Obj09_GOAL:
Line 5,869: Line 5,671:
 
</asm>
 
</asm>
 
===Sound $A9===
 
===Sound $A9===
now find:
+
Now find:
 
<asm>
 
<asm>
 
Obj09_UPsnd:
 
Obj09_UPsnd:
Line 5,908: Line 5,710:
 
</asm>
 
</asm>
 
===Sound $AA===
 
===Sound $AA===
now find:
+
Now find:
 
<asm>
 
<asm>
 
move.w #$AA,d0
 
move.w #$AA,d0
Line 5,942: Line 5,744:
  
 
===Sound $AC===
 
===Sound $AC===
now we will find:
+
Now we will find:
 
<asm>
 
<asm>
 
bne.s locret_1784A
 
bne.s locret_1784A
Line 6,119: Line 5,921:
 
jsr (PlaySound_Special).l ; play boss damage sound
 
jsr (PlaySound_Special).l ; play boss damage sound
 
</asm>
 
</asm>
now find:
+
Now find:
 
<asm>
 
<asm>
 
loc_1A1D4: ; XREF: off_19E80
 
loc_1A1D4: ; XREF: off_19E80
Line 6,147: Line 5,949:
  
 
===Sound $AD===
 
===Sound $AD===
lets fix the air bubble sound, so locate:
+
Lets fix the air bubble sound, so locate:
 
<asm>
 
<asm>
 
bsr.w ResumeMusic ; cancel countdown music
 
bsr.w ResumeMusic ; cancel countdown music
Line 6,154: Line 5,956:
 
lea ($FFFFD000).w,a1
 
lea ($FFFFD000).w,a1
 
</asm>
 
</asm>
should not be very hard to do, it is part of object 64's wobble routine, and there is a single line it int to change so that it is like this:
+
Should not be very hard to do, it is part of Object 64's wobble routine, and there is a single line it it to change so that it is like this:
 
<asm>
 
<asm>
 
bsr.w ResumeMusic ; cancel countdown music
 
bsr.w ResumeMusic ; cancel countdown music
Line 6,161: Line 5,963:
 
lea ($FFFFD000).w,a1
 
lea ($FFFFD000).w,a1
 
</asm>
 
</asm>
I used that same sound in a monitor that is in a hack that will enter the 2011 hacking contest this year thanks to the early notice.
 
  
 
===Sound $AE===
 
===Sound $AE===
now find:
+
Now find:
 
<asm>
 
<asm>
 
Obj14_PlaySnd:
 
Obj14_PlaySnd:
Line 6,203: Line 6,004:
 
</asm>
 
</asm>
 
===Sound $AF===
 
===Sound $AF===
now find:
+
Now find:
 
<asm>
 
<asm>
 
Obj2E_ChkShield:
 
Obj2E_ChkShield:
Line 6,224: Line 6,025:
 
</asm>
 
</asm>
 
===Sound $B0===
 
===Sound $B0===
now find:
+
Now find:
 
<asm>
 
<asm>
 
loc_15A46:
 
loc_15A46:
Line 6,246: Line 6,047:
 
jsr (PlaySound_Special).l ; play saw sound
 
jsr (PlaySound_Special).l ; play saw sound
 
</asm>
 
</asm>
now find:
+
Now find:
 
<asm>
 
<asm>
 
loc_15A96:
 
loc_15A96:
Line 6,268: Line 6,069:
 
jsr (PlaySound_Special).l ; play saw sound
 
jsr (PlaySound_Special).l ; play saw sound
 
</asm>
 
</asm>
now find:
+
Now find:
 
<asm>
 
<asm>
 
move.w #$B0,d0
 
move.w #$B0,d0
Line 6,284: Line 6,085:
 
addq.l #4,sp
 
addq.l #4,sp
 
</asm>
 
</asm>
now find:
+
Now find:
 
<asm>
 
<asm>
 
move.w #$B0,d0
 
move.w #$B0,d0
Line 6,301: Line 6,102:
 
</asm>
 
</asm>
 
===Sound $B1===
 
===Sound $B1===
the next sound is a little different.  Sonic1 uses the same sound effect for both the shocker orb thingies and the balls of lightning in the final boss, but the sonic3 driver has a couple of sound effects that I see fitting better.  shocker orbs will use the sound used for a certain badnik in carnival night zone because it sounds better in my opinion, while the balls of lightning from final boss will use the sound used for knux being shocked in hidden palace zone.  This is how sonic 3d blast / flickies island used similar sound effects, so we will find:
+
The next sound is a little different.  Sonic 1 uses the same sound effect for both the shocker orb thingies and the balls of lightning in the final boss, but the Sonic 3 driver has a couple of sound effects that I see fitting better.  Shocker orbs will use the sound used for a certain badnik in Carnival Night, because it sounds better in my opinion, while the balls of lightning from final boss will use the sound used for Knux being shocked in Hidden palace.  This is how Sonic 3D: Flickies Island used similar sound effects, so we will find:
 
<asm>
 
<asm>
 
Obj6E_Shock: ; XREF: Obj6E_Index
 
Obj6E_Shock: ; XREF: Obj6E_Index
Line 6,338: Line 6,139:
 
</asm>
 
</asm>
 
===Sound $B2===
 
===Sound $B2===
the next sound is a lot more like the others, it is the drowning sound.  We will locate:
+
The next sound is a lot more like the others, it is the drowning sound.  We will locate:
 
<asm>
 
<asm>
 
Obj0A_ReduceAir:
 
Obj0A_ReduceAir:
Line 6,358: Line 6,159:
  
 
===Sound $B3===
 
===Sound $B3===
now find:
+
Now find:
 
<asm>
 
<asm>
 
move.w #$B3,d0
 
move.w #$B3,d0
Line 6,373: Line 6,174:
 
</asm>
 
</asm>
 
===Sound $B4===
 
===Sound $B4===
now find:
+
Now find:
 
<asm>
 
<asm>
 
move.w #$B4,d0
 
move.w #$B4,d0
Line 6,416: Line 6,217:
 
</asm>
 
</asm>
 
===Sound $B5===
 
===Sound $B5===
now find:
+
Now find:
 
<asm>
 
<asm>
 
Title_PlayRing:
 
Title_PlayRing:
Line 6,457: Line 6,258:
 
</asm>
 
</asm>
 
===Sound $B6===
 
===Sound $B6===
now find:
+
Now find:
 
<asm>
 
<asm>
 
move.w #$B6,d0
 
move.w #$B6,d0
Line 6,476: Line 6,277:
 
</asm>
 
</asm>
 
===Sound $B7===
 
===Sound $B7===
now find:
+
Now find:
 
<asm>
 
<asm>
 
move.w #$B7,d0
 
move.w #$B7,d0
Line 6,490: Line 6,291:
 
loc_3D54:
 
loc_3D54:
 
</asm>
 
</asm>
now find:
+
Now find:
 
<asm>
 
<asm>
 
move.w #$B7,d0
 
move.w #$B7,d0
Line 6,504: Line 6,305:
 
loc_6F28:
 
loc_6F28:
 
</asm>
 
</asm>
now find:
+
Now find:
 
<asm>
 
<asm>
 
move.w #$B7,d0
 
move.w #$B7,d0
Line 6,519: Line 6,320:
 
</asm>
 
</asm>
 
===Sound $B8===
 
===Sound $B8===
sound $B8 is not used in sonic1, so we will skip it.
+
Sound $B8 is not used in Sonic 1, so we will skip it.
  
 
===Sound $B9===
 
===Sound $B9===
now find:
+
Now find:
 
<asm>
 
<asm>
 
loc_84F2:
 
loc_84F2:
Line 6,537: Line 6,338:
 
</asm>
 
</asm>
 
===Sound $BA===
 
===Sound $BA===
'''note: the breaking and collapsing sounds in sonic3 are the same.'''<br>
+
'''Note: the breaking and collapsing sounds in Sonic 3 are the same.'''<br>
 
now we will find:
 
now we will find:
 
<asm>
 
<asm>
Line 6,552: Line 6,353:
  
 
===Sound $BB===
 
===Sound $BB===
now find:
+
Now find:
 
<asm>
 
<asm>
 
move.w #$BB,d0
 
move.w #$BB,d0
Line 6,567: Line 6,368:
 
</asm>
 
</asm>
  
now find:
+
Now find:
 
<asm>
 
<asm>
 
move.w #$BB,d0
 
move.w #$BB,d0
Line 6,582: Line 6,383:
 
</asm>
 
</asm>
 
===Sound $BC===
 
===Sound $BC===
'''note: this sound effect is used differently in sonic3 but is the closest to what we have here'''<br>
+
'''Note: this sound effect is used differently in Sonic 3 but is the closest to what we have here'''<br>
now we find:
+
Now we find:
 
<asm>
 
<asm>
 
move.w #$BC,d0
 
move.w #$BC,d0
Line 6,601: Line 6,402:
  
 
===Sound $BD===
 
===Sound $BD===
now find:
+
Now find:
 
<asm>
 
<asm>
 
move.w #$BD,d0
 
move.w #$BD,d0
Line 6,615: Line 6,416:
 
Obj31_Restart:
 
Obj31_Restart:
 
</asm>
 
</asm>
now find:
+
Now find:
 
<asm>
 
<asm>
 
move.w #$BD,d0
 
move.w #$BD,d0
Line 6,633: Line 6,434:
 
===Sound $BE===
 
===Sound $BE===
 
'''note: this stomp sound is very different, though it is a stomping sound, the one from MGZ to be exact'''<br>
 
'''note: this stomp sound is very different, though it is a stomping sound, the one from MGZ to be exact'''<br>
now find:
+
Now find:
 
<asm>
 
<asm>
 
move.w #$BE,d0
 
move.w #$BE,d0
Line 6,655: Line 6,456:
 
rts
 
rts
 
</asm>
 
</asm>
now find:
+
Now find:
 
<asm>
 
<asm>
 
move.w #$BE,d0
 
move.w #$BE,d0
Line 6,676: Line 6,477:
  
 
===Sound $C0===
 
===Sound $C0===
Seems the sonic 3 driver does not have a sound for this, since the bat robot in CNZ (sonic 3) does not sound anywhere close to the MZ (sonic 1) variant, we will use a similar but close sound.<br>
+
Seems the Sonic 3 driver does not have a sound for this, since the bat robot in CNZ (Sonic 3) does not sound anywhere close to the MZ (sonic 1) variant, we will use a similar but close sound.<br>
lets look at the code:
+
Lets look at the code:
 
<asm>
 
<asm>
 
Obj55_PlaySnd: ; XREF: Obj55_Index2
 
Obj55_PlaySnd: ; XREF: Obj55_Index2
Line 6,686: Line 6,487:
 
jsr (PlaySound_Special).l ; play flapping sound
 
jsr (PlaySound_Special).l ; play flapping sound
 
</asm>
 
</asm>
And we will do as we have always been doing (I hope you were not just simply copy/pasting in the sound corrections, but changing the sound number in the line above '''jsr (PlaySound_Special).l''' or similar to the value suggested in the "change it to:" part of the tutorial at each step so that you can actually learn something and '''not simply break your hack'''.  I have seen a lot of people complaining about their hack being broken with this driver, I assume that the hacker did not check to see if what they did effected their work.  i.e. if you have code added to the sonic 1 driver for your hack, it is either obsolete and will be removed, of it it is unrelated to sound, either use another guide, or update your code so that you don't lose it.
+
and change it to:
 
 
I use the hivebrain 2005 disassembly with asw, so you may need to apply fixes to make it work with a different disassembly.  Expect later, a svn sonic1 version of this tutorial later on.  Now that what was said is out of the way, lets change it:
 
 
<asm>
 
<asm>
 
Obj55_PlaySnd: ; XREF: Obj55_Index2
 
Obj55_PlaySnd: ; XREF: Obj55_Index2
Line 6,731: Line 6,530:
  
 
===Sound $C2===
 
===Sound $C2===
the warning sound that you hear every so often under water "ding, ding" will be fixed by finding:
+
The warning sound that you hear every so often under water "ding, ding" will be fixed by finding:
 
<asm>
 
<asm>
 
Obj0A_WarnSound: ; XREF: Obj0A_Countdown
 
Obj0A_WarnSound: ; XREF: Obj0A_Countdown
Line 6,745: Line 6,544:
  
 
===Sound $C3===
 
===Sound $C3===
now we fix the giant special stage ring sound, what sound to use should be a no brainer if you listen to the sound test in sonic 3, since a new version of the giant rings return in sonic 3, so lets fix it by finding:
+
The Special Stage ring sound. Find:
 +
 
 
<asm>
 
<asm>
 
Obj4B_PlaySnd:
 
Obj4B_PlaySnd:
Line 6,761: Line 6,561:
  
 
===Sound $C4===
 
===Sound $C4===
for this one, you can use a sonic 3/s&k/sonic3k exploding sound (monitor/badnik pop), or use the classic, with is $B4, both work in a sonic game and either one could be useful in the hack, it is up to you.  For that reason, I will provide two different versions of this step.
+
For this one, you can use a Sonic 3/S&K/S3K exploding sound (monitor/badnik pop), or use the classic, with is $B4, both work in a sonic game and either one could be useful in the hack, it is up to you.  For that reason, I will provide two different versions of this step.
 
====Classic version====
 
====Classic version====
still want the old school sound with the sonic 3 driver?<br>
+
Still want the old school sound with the sonic 3 driver?<br>
 
find:
 
find:
 
<asm>
 
<asm>
Line 6,796: Line 6,596:
  
 
====Sonic3/k version (my favorite)====
 
====Sonic3/k version (my favorite)====
want the new sound?<br>
+
Want the new sound?<br>
find:
+
Find:
 
<asm>
 
<asm>
 
Obj3F_Main: ; XREF: Obj3F_Index
 
Obj3F_Main: ; XREF: Obj3F_Index
Line 6,827: Line 6,627:
 
jmp (PlaySound_Special).l ; play monitor destruction sound like sonic3/k
 
jmp (PlaySound_Special).l ; play monitor destruction sound like sonic3/k
 
</asm>
 
</asm>
you are probably wondering, why use this sound here? the LRZ (s&k) exploding rock uses it and astareon (sonic2, MtZ) uese it, and besides it is used in the eggman defeat routine and the egg prison destruction routine.  the result, the eggman defeat sounds as it does in sonic 3, time to update the eggmobile artwork now if you so choose so that it fits better with this sound improvement.
+
You are probably wondering, why use this sound here? The LRZ exploding rock uses it and Asteron (Sonic 2, MTZ) uses it, and besides, it is used in the Eggman defeat routine and the Egg Prison destruction routine.  The result, the Eggman defeat sounds as it does in Sonic 3, so time to update the Eggmobile now if you so choose so that it fits better with this sound improvement.
  
 
===Sound $C5===
 
===Sound $C5===
this sound really needs to be fixed badly if the sonic 3 driver is in, it is the same in every single sonic game excluding 8-bit and portable games, even the next-gen games (though it is an enhanced version) and sonic adventure has an improved version even.  please fix this one in your hack or it will be way off from normal sonic games.<br>
+
The ker-ching sound is in Sonic 3, so lets modify the End Of Results bonus checker to play it.<br>
 
find:
 
find:
 
<asm>
 
<asm>
Line 6,881: Line 6,681:
 
</asm>
 
</asm>
 
===Sound $C6===
 
===Sound $C6===
fixing this sound will make sonic's ring loss sound right, so locate:
+
Fixing this sound will make sonic's ring loss sound right, so locate:
 
<asm>
 
<asm>
 
Obj37_ResetCounter: ; XREF: Obj37_Loop
 
Obj37_ResetCounter: ; XREF: Obj37_Loop
Line 6,901: Line 6,701:
  
 
===Sound $C7===
 
===Sound $C7===
remember the giant weight with spikes under it that goes up and crashes down in MZ? we are going to fix the sound now.<br>
+
Remember the giant weight with spikes under it that goes up and crashes down in MZ? We are going to fix the sound now.<br>
 
find:
 
find:
 
<asm>
 
<asm>
Line 6,952: Line 6,752:
  
 
===Sound $C8===
 
===Sound $C8===
Once again sonic3 has 2 sounds for this one (one used in the spiked weight in LRZ, the other from the lava waterfalls also in LRZ) we will put them both where they belong)<br>
+
Once again, Sonic 3 has 2 sounds for this one. (one used in the spiked weight in LRZ, the other from the lava waterfalls also in LRZ) we will put them both where they belong)<br>
first we will make the MZ lava spouts use the lava waterfall sound (yes, that one):
+
First we will make the MZ lava spouts use the lava waterfall sound (yes, that one):
 
<asm>
 
<asm>
 
Obj4D_PlaySnd:
 
Obj4D_PlaySnd:
Line 7,003: Line 6,803:
  
 
===Sound $C9===
 
===Sound $C9===
the hidden points sound is no longer in sonic 3, but the egg logger mini boss from MHZ has a similar sound that is used, so it probably will have to work until you replace a sound effect.<br>
+
The hidden points sound is no longer in Sonic 3, but the Hey Ho (MHZ Miniboss) has a similar sound that is used, so it probably will have to work until you replace a sound effect.<br>
find:
+
Find:
 
<asm>
 
<asm>
 
move.w #$C9,d0
 
move.w #$C9,d0
Line 7,030: Line 6,830:
  
 
===Sound $CA===
 
===Sound $CA===
This Sound should already be fixed by now (it was fixed with special event sounds)
+
This sound should already be fixed by now. (it was fixed with Special Event sounds)
  
 
===Sound $CB===
 
===Sound $CB===
remember that I said sonic3 has only 1 version of this sound above?<br>
+
Remember that I said Sonic 3 has only 1 version of this sound above?<br>
the crumbling sound from above and smashing sound in sonic3 are identical, so find:
+
The crumbling sound from above and smashing sound in Sonic 3 are identical, so find:
 
<asm>
 
<asm>
 
loc_197D4:
 
loc_197D4:
Line 7,060: Line 6,860:
 
jmp (DisplaySprite).l
 
jmp (DisplaySprite).l
 
</asm>
 
</asm>
now find:
+
Now find:
 
<asm>
 
<asm>
 
Smash_PlaySnd:
 
Smash_PlaySnd:
Line 7,076: Line 6,876:
  
 
===Sound $CC===
 
===Sound $CC===
the spring sound now, find:
+
The Spring Sound now, find:
 
<asm>
 
<asm>
 
Obj41_BounceUp: ; XREF: Obj41_Up
 
Obj41_BounceUp: ; XREF: Obj41_Up
Line 7,198: Line 6,998:
  
 
===Sound $CD===
 
===Sound $CD===
find:
+
Find:
 
<asm>
 
<asm>
 
loc_BDC8:
 
loc_BDC8:
Line 7,268: Line 7,068:
  
 
===Sound $CE===
 
===Sound $CE===
this sound's usage was defined in the old 68k driver and fixes itself.
+
This sound's usage was defined in the old 68k driver and fixes itself.
  
 
===Sound $CF===
 
===Sound $CF===
the old sound for the end sign is no longer in sonic 3, but a similar (unused) sound does exist, so find:
+
The old sound for the end sign is no longer in Sonic 3, but a similar (unused) sound does exist, so find:
 
<asm>
 
<asm>
 
Obj0D_Touch: ; XREF: Obj0D_Index
 
Obj0D_Touch: ; XREF: Obj0D_Index
Line 7,301: Line 7,101:
  
 
===Sound $D0===
 
===Sound $D0===
this one is the hard one, sonic1's timing of the waterfalls is not right, so the water sound will have pauses in it.  I will look into it and update the code when I get it working right.<br>
+
This one is the hard one, Sonic 1's timing of the waterfalls is not right, so the water sound will have pauses in it.  I will look into it and update the code when I get it working right.<br>
for now find:
+
for now, find:
 
<asm>
 
<asm>
 
loc_3F9A:
 
loc_3F9A:
Line 7,386: Line 7,186:
  
 
==Utilizing new sounds in existing badniks==
 
==Utilizing new sounds in existing badniks==
here, we delve a little into object editing and how to effectively use the sonic 3 sound system, because you have already decided to use it, right?  Well, if you hadn't, then why are you here?<br>
+
here, we delve a little into object editing and how to effectively use the Sonic 3 sound system, because you have already decided to use it, right?  Well, if you hadn't, then why are you here?<br>
Using sounds in sonic 3 is very similar to older games, just the sound numbers are changed thus why the strange stuff you may have encountered earlier and why you will have to fix the level select later. here is how the sounds line up:
+
Using sounds in Sonic 3 is very similar to older games, just the sound numbers are changed thus why the strange stuff you may have encountered earlier and why you will have to fix the Level Select later. here is how the sounds line up:
 
{|class="prettytable"
 
{|class="prettytable"
 
!Type||Numbers in Sonic 1/Sonic 2||Numbers in Sonic 3+
 
!Type||Numbers in Sonic 1/Sonic 2||Numbers in Sonic 3+
Line 7,410: Line 7,210:
  
 
===Buzz Bomber===
 
===Buzz Bomber===
The buzz bomber fires at sonic, and most enemies in sonic 3 tend to make a certain sound when they fire at sonic, so lets add that one to the buzz bomber, so why don't we locate the firing routine:
+
The buzz bomber fires at sonic, and most enemies in Sonic 3 tend to make a certain sound when they fire at sonic, so lets add that one to the buzz bomber, so why don't we locate the firing routine:
 
<asm>
 
<asm>
 
loc_98AA:
 
loc_98AA:
Line 7,427: Line 7,227:
 
</asm>
 
</asm>
  
now our buzz bomber has sound!
+
Now our buzz bomber has sound!
 
===Crabmeat===
 
===Crabmeat===
the Crabmeat badnik can have a sound too, if we add it in a similar manner, so lets do it!  Crabmeat throws something with both claws, but so does that monkey in AIZ throw something, so lets use that sound. lets find the Crabmeat throwing routine:
+
The Crabmeat badnik can have a sound too, if we add it in a similar manner, so lets do it!  Crabmeat throws something with both claws, but so does Monkey Dude in AIZ, so lets use that sound. Lets find the Crabmeat throwing routine:
 
<asm>
 
<asm>
 
Obj1F_MakeFire: ; XREF: Obj1F_WaitFire
 
Obj1F_MakeFire: ; XREF: Obj1F_WaitFire
Line 7,481: Line 7,281:
 
jsr PlaySound ;play throwing sound
 
jsr PlaySound ;play throwing sound
 
</asm>
 
</asm>
finally an audiable Crabmeat.
+
Finally, an audiable Crabmeat.
  
 
===Orbinaught===
 
===Orbinaught===
Line 7,513: Line 7,313:
  
 
==Fixing the sound test on the level select==
 
==Fixing the sound test on the level select==
Now we finally get to correcting the level select.  First off, we do a sort of addition to the sonic 1 level select that has been added to the simon wai prototype, but not yet to the sonic 1 level select, music.
+
Now, we'll fix the level select to suit the Sonic 3 driver.
===music upon entry of level select===
+
 
locate:
+
===Music upon entry of level select===
 +
Optionally, you can do what Sonic 2 Beta (Simon Wai to Beta 5) does and play music upon entering the Level Select. If you'd rather not do it, skip this step.
 +
 
 +
Locate:
 
<asm>
 
<asm>
 
LevelSelect:
 
LevelSelect:
Line 7,544: Line 7,347:
 
</asm>
 
</asm>
  
the result should look like this:
+
The result should look like this:
 
<asm>
 
<asm>
 
bsr.w LevSelTextLoad
 
bsr.w LevSelTextLoad
Line 7,576: Line 7,379:
  
 
===fixing the sound test===
 
===fixing the sound test===
Okay, there is a lot that needs fixing here, the sonic 1 sound test seems to be set up for the old driver not the new one, first off lets look at part 1 of the level select code:
+
Okay, there is a lot that needs fixing here, the Sound Test seems to be set up for the old driver not the new one, first off lets look at part 1 of the level select code:
 
<asm>
 
<asm>
 
LevelSelect:
 
LevelSelect:
Line 7,644: Line 7,447:
 
move.w d0,($FFFFFE10).w ; set level number
 
move.w d0,($FFFFFE10).w ; set level number
  
PlayLevel: ; XREF: ROM:00003246�j ...
+
PlayLevel: ; XREF: ROM:00003246?j ...
 
move.b #$C,($FFFFF600).w ; set screen mode to $0C (level)
 
move.b #$C,($FFFFF600).w ; set screen mode to $0C (level)
 
move.b #3,($FFFFFE12).w ; set lives to 3
 
move.b #3,($FFFFFE12).w ; set lives to 3
Line 7,664: Line 7,467:
 
; ---------------------------------------------------------------------------
 
; ---------------------------------------------------------------------------
 
LSelectPointers:
 
LSelectPointers:
binclude misc/ls_point.bin
+
incbin misc/ls_point.bin
 
align 2
 
align 2
 
</asm>
 
</asm>
my, oh my...  first off we do not need all that japanese cheat junk, and second we do not need any gaps in the sound test, so lets remove that junk:
+
Since the Japanese Credits Easter Egg is in no need of use, we'll remove it. We're also going to fix the gaps in the Sound Test too.
 
<asm>
 
<asm>
 
LevelSelect:
 
LevelSelect:
Line 7,706: Line 7,509:
 
move.w d0,($FFFFFE10).w ; set level number
 
move.w d0,($FFFFFE10).w ; set level number
  
PlayLevel: ; XREF: ROM:00003246�j ...
+
PlayLevel: ; XREF: ROM:00003246?j ...
 
move.b #$C,($FFFFF600).w ; set screen mode to $0C (level)
 
move.b #$C,($FFFFF600).w ; set screen mode to $0C (level)
 
move.b #3,($FFFFFE12).w ; set lives to 3
 
move.b #3,($FFFFFE12).w ; set lives to 3
Line 7,726: Line 7,529:
 
; ---------------------------------------------------------------------------
 
; ---------------------------------------------------------------------------
 
LSelectPointers:
 
LSelectPointers:
binclude misc/ls_point.bin
+
incbin misc/ls_point.bin
 
align 2
 
align 2
 
</asm>
 
</asm>
now lets look at the next part of the level select:
+
Now lets look at the next part of the level select:
 
<asm>
 
<asm>
 
LevSelControls: ; XREF: LevelSelect
 
LevSelControls: ; XREF: LevelSelect
Line 7,792: Line 7,595:
 
rts
 
rts
 
</asm>
 
</asm>
seems that we have now located the code that limits the level select to $80 - $CF, so we fix it:
+
Seems that we have now located the code that limits the level select to $80 - $CF, so we fix it:
 
<asm>
 
<asm>
 
LevSelControls: ; XREF: LevelSelect
 
LevSelControls: ; XREF: LevelSelect
Line 7,855: Line 7,658:
 
rts
 
rts
 
</asm>
 
</asm>
Thought it was fixed already? well even though it works right, the display is still wrong, so we need to fix it.
+
Thought it was fixed already? Well even though it works right, the display is still wrong, so we need to fix it.
 
so lets go to:
 
so lets go to:
 
<asm>
 
<asm>
Line 7,877: Line 7,680:
 
==Credits==
 
==Credits==
 
I give credit where it is due:
 
I give credit where it is due:
*  '''Esrael''' for the original port of the Sonic 3 Driver, which I fixed up.
+
*  '''Esrael''' for the original port of the Sonic 3 Driver to Sonic 2 Beta, which I fixed up.
*  '''Tornado''' for the original hackish guide on SSRG
+
*  '''Tornado''' for the original guide on SSRG
*  '''Selbi''' for posting info on most of, but not all the sound test values which I had to finish
+
*  '''Selbi''' for posting info on most of, but not all the sound test values which I had to finish.
  
 
{{S1Howtos}}
 
{{S1Howtos}}
 
[[Category:SCHG How-tos|{{PAGENAME}}]]
 
[[Category:SCHG How-tos|{{PAGENAME}}]]

Revision as of 18:18, 1 January 2015

(Original guide by Kram1024)
Updated by User:Kram1024

You probably saw a quick and dirty way to do this on SSRG, but lets do it the proper way, the way that Sonic Team would do it.

Contents

Overview

First off, Sonic 3's sound driver has the V_Int reloader built into it so it is not needed. Some routines need replacement, sounds need fixing, and we need to replace the sounds and music. We will be using the commonly used Hivebrain disasm. If you wish to do it via the up-to-date Github version, you would need to get the Hivebrain labels used in this guide and replace them with their Git equivalents. S1 Git also has a different alignment macro too, so copy and paste the Hivebrain disasm's align macro to "Macros.asm" and change it's macro label to "align2", then replace every single "align" used in this guide with "align2".

AS Users: change "incbin" to "binclude".

Macros

Before going on with this guide, add these macros to the start of your disassembly:

<asm>

(since the DAC banks are incbin'd, this macro isn't in use)
for DAC pointers

zPtrDAC: macro addr

    dc.w ((((addr&$7FFF)+$8000)<<8)&$FF00)+(((addr&$7FFF)+$8000)>>8)
    endm
for special pointers in the driver itself

zPtrSpec: macro addr

    dc.w (((addr&$1FFF)>>$08)|((addr&$1FFF)<<$08))&$FFFF
    endm
for pointers to things that the 68k will interact with in the Z80 Driver

z68kPtr: macro addr

    dc.w (((addr&$FFFF)|$8000>>$08)|((addr&$FFFF)|$8000<<$08))&$FFFF
    endm

</asm>

Preparing to use Sonic 3/K/3K sound system

The Vertical Interrupt and Horizontal Interrupt need to be fixed, Since the Sonic 1/2 system uses them but the Sonic 3/K/3K system doesn't.

Removal of Master V_Int branch to S1's driver pointer

first we will fix the vertical interrupt, by changing: <asm>

loc_B5E: ; XREF: loc_B88 jsr (sub_71B4C).l </asm>

to:

<asm> loc_B5E: ; XREF: loc_B88 nop ; The nop was placed here in order to make sure ; that the same number of cycles was used. ; not doing so could put things slightly out of sync. </asm>

Removal of H_Int branch point to s1driver

Now we locate: <asm> loc_119E: ; XREF: PalToCRAM clr.b ($FFFFF64F).w movem.l d0-a6,-(sp) bsr.w Demo_Time jsr (sub_71B4C).l movem.l (sp)+,d0-a6 rte

End of function PalToCRAM

</asm> See another familiar line? Yes, you've got it, do the same thing to it: <asm> loc_119E: ; XREF: PalToCRAM clr.b ($FFFFF64F).w movem.l d0-a6,-(sp) bsr.w Demo_Time nop ; The nop was placed here in order to make sure ; that the same number of cycles was used. ; not doing so could put things slightly out of sync.

		movem.l	(sp)+,d0-a6

rte

End of function PalToCRAM

</asm> That effectively disables the Sonic 1/2 style V_int and H_int driver reloading that we will not need and prevents a nasty error down the road.

Upgrading the Load Driver Routine

Okay, we disabled the driver's V_Int/H_Int system, wouldn't we want now to use the sonic3 driver instead? Here is where we start installing it. Locate: <asm>

---------------------------------------------------------------------------
Subroutine to load the sound driver
---------------------------------------------------------------------------
||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


SoundDriverLoad: ; XREF: GameClrRAM; TitleScreen nop move.w #$100,($A11100).l ; stop the Z80 move.w #$100,($A11200).l ; reset the Z80 lea (Kos_Z80).l,a0 ; load sound driver lea ($A00000).l,a1 bsr.w KosDec ; decompress move.w #0,($A11200).l nop nop nop nop move.w #$100,($A11200).l ; reset the Z80 move.w #0,($A11100).l ; start the Z80 rts

End of function SoundDriverLoad

</asm>

and replace it all with: <asm>

---------------------------------------------------------------------------
Subroutine to load the sound driver
---------------------------------------------------------------------------
||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||

SoundDriverLoad: ; XREF: GameClrRAM; TitleScreen nop move.w #$100,($A11100).l ; Z80 bus request - Start move.w #$100,($A11200).l ; Z80 stop reset lea (DriverData).l,a0 lea ($A00000).l,a1 move.w #DriverDataEnd-DriverData,d0

DriverLoadLoop: move.b (a0)+,(a1)+ dbf d0,DriverLoadLoop lea (DriverPointers).l,a0 lea ($A01300).l,a1 move.w #DriverPointersEnd-DriverPointers,d0

DriverPointersLoadLoop: move.b (a0)+,(a1)+ dbf d0, DriverPointersLoadLoop lea (UniversalVoiceBank).l,a0 lea ($A017D8).l,a1 move.w #UniversalVoiceBankEnd-UniversalVoiceBank,d0

UniversalVoiceBankLoadLoop: move.b (a0)+,(a1)+ dbf d0,UniversalVoiceBankLoadLoop lea (DriverResetData).l,a0 lea ($A01C00).l,a1 move.w #DriverResetDataEnd-DriverResetData,d0

DriverResetDataLoadLoop: move.b (a0)+,(a1)+ dbf d0,DriverResetDataLoadLoop btst #6,($FFFFFFF8).w beq.s DriverAlreadyInitialized move.b #1,($A01C02).l

DriverAlreadyInitialized: move.w #0,($A11200).l nop nop nop nop move.w #$100,($A11200).l ; Z80 start reset move.w #0,($A11100).l ; Z80 bus request - Stop rts

End of function SoundDriverLoad


DriverResetData: dc.b 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 DriverResetDataEnd: </asm>

Upgrading the Playback Routines

Now we have the code to load the new driver, time to add the new playback routines.

Upgrade Music Routine

First the PlaySound routine, locate: <asm>

---------------------------------------------------------------------------
Subroutine to play a sound or music track
---------------------------------------------------------------------------
||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


PlaySound: move.b d0,($FFFFF00A).w rts

End of function PlaySound

</asm>

and replace it completely with: <asm>

---------------------------------------------------------------------------
Subroutine to play a sound or music track
---------------------------------------------------------------------------
||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


PlaySound: cmpi.w #$FB,d0 blt.s PlayNotSpecialFlag bhi.s TestForNormalSpeed move #8,d0 jmp SetTempo

TestForNormalSpeed: cmpi.w #$FC,d0 bne.s PlayNotSpecialFlag clr.w d0 jmp SetTempo

PlayNotSpecialFlag: move.w #$100,($A11100).l

PlaySoundZ80NotStopped: btst #0,($A11100).l bne.s PlaySoundZ80NotStopped ; loop until it says it's stopped move.b d0,($A01C0A).l move.w #0,($A11100).l rts

End of function PlaySound
---------------------------------------------------------------------------
Exclusive sound/music subroutine
---------------------------------------------------------------------------


||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


PlaySound_Ex: tst.b 4(A0) bpl.s SkipPlaySound_Special </asm> Do not be alarmed about the new sound routine that was added, it is equivalent to the PlaySound_Local routine (as a matter of fact, it is identical, why sonic1 does not already have it is beyond me, since it indeed does work in Sonic 1)

sound playback routines

now find: <asm>

---------------------------------------------------------------------------
Subroutine to play a special sound/music (E0-E4)
E0 - Fade out
E1 - Sega
E2 - Speed up
E3 - Normal speed
E4 - Stop
---------------------------------------------------------------------------
||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


PlaySound_Special: move.b d0,($FFFFF00B).w rts

End of function PlaySound_Special
===========================================================================
---------------------------------------------------------------------------
Unused sound/music subroutine
---------------------------------------------------------------------------

PlaySound_Unk: move.b d0,($FFFFF00C).w rts </asm>

and replace it entirely with: <asm>

---------------------------------------------------------------------------
Unused sound/music subroutine
---------------------------------------------------------------------------

PlaySound_Unk: nop

---------------------------------------------------------------------------
Subroutine to play a special sound/music (FB-FF)
---------------------------------------------------------------------------

PlaySound_Special: move.w #$100,($A11100).l

PlaySound_SpecialZ80NotStopped: btst #0,($A11100).l bne.s PlaySound_SpecialZ80NotStopped cmp.b ($A01C0B).l,d0 beq.s PlaySound_Special1 tst.b ($A01C0B).l bne.s PlaySound_Special0 move.b d0,($A01C0B).l move.w #0,($A11100).l rts

PlaySound_Special0: move.b d0,($A01C0C).l

PlaySound_Special1: move.w #0,($A11100).l

SkipPlaySound_Special: rts

End of function PlaySound_Special
---------------------------------------------------------------------------
Subroutine to change the music tempo
---------------------------------------------------------------------------

SetTempo: move.w #$100,($A11100).l

SetTempoZ80NotStopped: btst #0,($A11100).l bne.s SetTempoZ80NotStopped move.b D0,($A01C08).l move.w #0,($A11100).l rts </asm>

Upgrading Pause / Resume routines

Now the playback routines are fixed and we have a routine to set the tempo the way the sneakers do, which we will elaberate later on, but we still have to update the pause / resume routines to the sonic 3 equivilents.

Find: <asm>

---------------------------------------------------------------------------
Subroutine to pause the game
---------------------------------------------------------------------------
||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


PauseGame: ; XREF: Level_MainLoop; et al nop tst.b ($FFFFFE12).w ; do you have any lives left? beq.s Unpause ; if not, branch tst.w ($FFFFF63A).w ; is game already paused? bne.s loc_13BE ; if yes, branch btst #7,($FFFFF605).w ; is Start button pressed? beq.s Pause_DoNothing ; if not, branch

loc_13BE: move.w #1,($FFFFF63A).w ; freeze time move.b #1,($FFFFF003).w ; pause music

loc_13CA: move.b #$10,($FFFFF62A).w bsr.w DelayProgram tst.b ($FFFFFFE1).w ; is slow-motion cheat on? beq.s Pause_ChkStart ; if not, branch btst #6,($FFFFF605).w ; is button A pressed? beq.s Pause_ChkBC ; if not, branch move.b #4,($FFFFF600).w ; set game mode to 4 (title screen) nop bra.s loc_1404

===========================================================================

Pause_ChkBC: ; XREF: PauseGame btst #4,($FFFFF604).w ; is button B pressed? bne.s Pause_SlowMo ; if yes, branch btst #5,($FFFFF605).w ; is button C pressed? bne.s Pause_SlowMo ; if yes, branch

Pause_ChkStart: ; XREF: PauseGame btst #7,($FFFFF605).w ; is Start button pressed? beq.s loc_13CA ; if not, branch

loc_1404: ; XREF: PauseGame move.b #$80,($FFFFF003).w

Unpause: ; XREF: PauseGame move.w #0,($FFFFF63A).w ; unpause the game

Pause_DoNothing: ; XREF: PauseGame rts

===========================================================================

Pause_SlowMo: ; XREF: PauseGame move.w #1,($FFFFF63A).w move.b #$80,($FFFFF003).w rts

End of function PauseGame

</asm>

and replace it completely with: <asm>

---------------------------------------------------------------------------
Subroutine to pause the game
---------------------------------------------------------------------------
||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


PauseGame: ; XREF: Level_MainLoop; et al nop tst.b ($FFFFFE12).w beq Unpause tst.w ($FFFFF63A).w bne.s PauseGame_AlreadyPaused move.b ($FFFFF605).w,d0 or.b ($FFFFF607).w,d0 andi.b #$80,d0 beq Pause_DoNothing

PauseGame_AlreadyPaused: move.w #1,($FFFFF63A).w move.w #$100,($A11100).l

PauseGameZ80NotStopped: btst #0,($A11100).l bne.s PauseGameZ80NotStopped move.b #1,($A01C10).l move.w #0,($A11100).l

PauseGameLoop: move.b #$10,($FFFFF62A).w jsr DelayProgram tst.b ($FFFFFFE1).w ; Edit: the value is $FFFFFFE1 in Sonic 1 beq.s Pause_ChkStart btst #6,($FFFFF605).w beq.s Pause_ChkBC move.b #$4,($FFFFF600).w ; Go To Title Screen nop bra.s PauseGame1

Pause_ChkBC: btst #4,($FFFFF604).w bne.s Pause_SlowMo btst #5,($FFFFF605).w bne.s Pause_SlowMo

Pause_ChkStart: cmpi.b #$E,($FFFFFE10).w bcs.s PauseGame0 cmpi.b #$12,($FFFFFE10).w bhi.s PauseGame0 tst.b ($FFFFFF8B).w bpl.s PauseGame0 btst #4,($FFFFF605).w beq.s PauseGame0 move.b #$C0,($FFFFF600).w bra.s PauseGame1

PauseGame0: move.b ($FFFFF605).w,d0 or.b ($FFFFF607).w,d0 andi.b #$80,d0 beq.s PauseGameLoop

PauseGame1: move.w #$100,($A11100).l

Pause_ChkStartZ80NotStopped: btst #0,($A11100).l bne.s Pause_ChkStartZ80NotStopped move.b #$80,($A01C10).l move.w #0,($A11100).l

Unpause: move.w #0,($FFFFF63A).w

Pause_DoNothing: rts

Pause_SlowMo: move.w #1,($FFFFF63A).w move.w #$100,($A11100).l

Pause_SlowMoZ80NotStopped: btst #0,($A11100).l bne.s Pause_SlowMoZ80NotStopped move.b #$80,($A01C10).l move.w #0,($A11100).l rts

End of function PauseGame

</asm>

Replacing 68k driver with new Z80 driver

We need the sound driver itself if we are going to have any sound and music, so we locate: <asm> align 2

Go_SoundTypes: dc.l SoundTypes ; XREF: Sound_Play Go_SoundD0: dc.l SoundD0Index ; XREF: Sound_D0toDF Go_MusicIndex: dc.l MusicIndex ; XREF: Sound_81to9F Go_SoundIndex: dc.l SoundIndex ; XREF: Sound_A0toCF off_719A0: dc.l byte_71A94 ; XREF: Sound_81to9F Go_PSGIndex: dc.l PSG_Index ; XREF: sub_72926

---------------------------------------------------------------------------
PSG instruments used in music
---------------------------------------------------------------------------

PSG_Index: dc.l PSG1, PSG2, PSG3 dc.l PSG4, PSG5, PSG6 dc.l PSG7, PSG8, PSG9 PSG1: binclude sound\psg1.bin PSG2: binclude sound\psg2.bin PSG3: binclude sound\psg3.bin PSG4: binclude sound\psg4.bin PSG6: binclude sound\psg6.bin PSG5: binclude sound\psg5.bin PSG7: binclude sound\psg7.bin PSG8: binclude sound\psg8.bin PSG9: binclude sound\psg9.bin

byte_71A94: dc.b 7, $72, $73, $26, $15, 8, $FF, 5

---------------------------------------------------------------------------
Music Pointers
---------------------------------------------------------------------------

MusicIndex: dc.l Music81, Music82 dc.l Music83, Music84 dc.l Music85, Music86 dc.l Music87, Music88 dc.l Music89, Music8A dc.l Music8B, Music8C dc.l Music8D, Music8E dc.l Music8F, Music90 dc.l Music91, Music92 dc.l Music93

---------------------------------------------------------------------------
Type of sound being played ($90 = music; $70 = normal sound effect)
---------------------------------------------------------------------------

SoundTypes: dc.b $90, $90, $90, $90, $90, $90, $90, $90, $90, $90, $90, $90, $90, $90, $90, $90 dc.b $90, $90, $90, $90, $90, $90, $90, $90, $90, $90, $90, $90, $90, $90, $90, $80 dc.b $70, $70, $70, $70, $70, $70, $70, $70, $70, $68, $70, $70, $70, $60, $70, $70 dc.b $60, $70, $60, $70, $70, $70, $70, $70, $70, $70, $70, $70, $70, $70, $7F, $60 dc.b $70, $70, $70, $70, $70, $70, $70, $70, $70, $70, $70, $70, $70, $70, $70, $80 dc.b $80, $80, $80, $80, $80, $80, $80, $80, $80, $80, $80, $80, $80, $80, $80, $90 dc.b $90, $90, $90, $90

||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_71B4C: ; XREF: loc_B10; PalToCRAM move.w #$100,($A11100).l ; stop the Z80 nop nop nop

loc_71B5A: btst #0,($A11100).l bne.s loc_71B5A

btst #7,($A01FFD).l beq.s loc_71B82 move.w #0,($A11100).l ; start the Z80 nop nop nop nop nop bra.s sub_71B4C

===========================================================================

loc_71B82: lea ($FFF000).l,a6 clr.b $E(a6) tst.b 3(a6) ; is music paused? bne.w loc_71E50 ; if yes, branch subq.b #1,1(a6) bne.s loc_71B9E jsr sub_7260C(pc)

loc_71B9E: move.b 4(a6),d0 beq.s loc_71BA8 jsr sub_72504(pc)

loc_71BA8: tst.b $24(a6) beq.s loc_71BB2 jsr sub_7267C(pc)

loc_71BB2: tst.w $A(a6) ; is music or sound being played? beq.s loc_71BBC ; if not, branch jsr Sound_Play(pc)

loc_71BBC: cmpi.b #$80,9(a6) beq.s loc_71BC8 jsr Sound_ChkValue(pc)

loc_71BC8: lea $40(a6),a5 tst.b (a5) bpl.s loc_71BD4 jsr sub_71C4E(pc)

loc_71BD4: clr.b 8(a6) moveq #5,d7

loc_71BDA: adda.w #$30,a5 tst.b (a5) bpl.s loc_71BE6 jsr sub_71CCA(pc)

loc_71BE6: dbf d7,loc_71BDA

moveq #2,d7

loc_71BEC: adda.w #$30,a5 tst.b (a5) bpl.s loc_71BF8 jsr sub_72850(pc)

loc_71BF8: dbf d7,loc_71BEC

move.b #$80,$E(a6) moveq #2,d7

loc_71C04: adda.w #$30,a5 tst.b (a5) bpl.s loc_71C10 jsr sub_71CCA(pc)

loc_71C10: dbf d7,loc_71C04

moveq #2,d7

loc_71C16: adda.w #$30,a5 tst.b (a5) bpl.s loc_71C22 jsr sub_72850(pc)

loc_71C22: dbf d7,loc_71C16 move.b #$40,$E(a6) adda.w #$30,a5 tst.b (a5) bpl.s loc_71C38 jsr sub_71CCA(pc)

loc_71C38: adda.w #$30,a5 tst.b (a5) bpl.s loc_71C44 jsr sub_72850(pc)

loc_71C44: move.w #0,($A11100).l ; start the Z80 rts

End of function sub_71B4C


||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_71C4E: ; XREF: sub_71B4C subq.b #1,$E(a5) bne.s locret_71CAA move.b #$80,8(a6) movea.l 4(a5),a4

loc_71C5E: moveq #0,d5 move.b (a4)+,d5 cmpi.b #-$20,d5 bcs.s loc_71C6E jsr sub_72A5A(pc) bra.s loc_71C5E

===========================================================================

loc_71C6E: tst.b d5 bpl.s loc_71C84 move.b d5,$10(a5) move.b (a4)+,d5 bpl.s loc_71C84 subq.w #1,a4 move.b $F(a5),$E(a5) bra.s loc_71C88

===========================================================================

loc_71C84: jsr sub_71D40(pc)

loc_71C88: move.l a4,4(a5) btst #2,(a5) bne.s locret_71CAA moveq #0,d0 move.b $10(a5),d0 cmpi.b #$80,d0 beq.s locret_71CAA btst #3,d0 bne.s loc_71CAC move.b d0,($A01FFF).l

locret_71CAA: rts

===========================================================================

loc_71CAC: subi.b #$88,d0 move.b byte_71CC4(pc,d0.w),d0 move.b d0,($A000EA).l move.b #$83,($A01FFF).l rts

End of function sub_71C4E
===========================================================================

byte_71CC4: dc.b $12, $15, $1C, $1D, $FF, $FF

||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_71CCA: ; XREF: sub_71B4C subq.b #1,$E(a5) bne.s loc_71CE0 bclr #4,(a5) jsr sub_71CEC(pc) jsr sub_71E18(pc) bra.w loc_726E2

===========================================================================

loc_71CE0: jsr sub_71D9E(pc) jsr sub_71DC6(pc) bra.w loc_71E24

End of function sub_71CCA


||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_71CEC: ; XREF: sub_71CCA movea.l 4(a5),a4 bclr #1,(a5)

loc_71CF4: moveq #0,d5 move.b (a4)+,d5 cmpi.b #-$20,d5 bcs.s loc_71D04 jsr sub_72A5A(pc) bra.s loc_71CF4

===========================================================================

loc_71D04: jsr sub_726FE(pc) tst.b d5 bpl.s loc_71D1A jsr sub_71D22(pc) move.b (a4)+,d5 bpl.s loc_71D1A subq.w #1,a4 bra.w sub_71D60

===========================================================================

loc_71D1A: jsr sub_71D40(pc) bra.w sub_71D60

End of function sub_71CEC


||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_71D22: ; XREF: sub_71CEC subi.b #$80,d5 beq.s loc_71D58 add.b 8(a5),d5 andi.w #$7F,d5 lsl.w #1,d5 lea word_72790(pc),a0 move.w (a0,d5.w),d6 move.w d6,$10(a5) rts

End of function sub_71D22


||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_71D40: ; XREF: sub_71C4E; sub_71CEC; sub_72878 move.b d5,d0 move.b 2(a5),d1

loc_71D46: subq.b #1,d1 beq.s loc_71D4E add.b d5,d0 bra.s loc_71D46

===========================================================================

loc_71D4E: move.b d0,$F(a5) move.b d0,$E(a5) rts

End of function sub_71D40
===========================================================================

loc_71D58: ; XREF: sub_71D22 bset #1,(a5) clr.w $10(a5)

||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_71D60: ; XREF: sub_71CEC; sub_72878; sub_728AC move.l a4,4(a5) move.b $F(a5),$E(a5) btst #4,(a5) bne.s locret_71D9C move.b $13(a5),$12(a5) clr.b $C(a5) btst #3,(a5) beq.s locret_71D9C movea.l $14(a5),a0 move.b (a0)+,$18(a5) move.b (a0)+,$19(a5) move.b (a0)+,$1A(a5) move.b (a0)+,d0 lsr.b #1,d0 move.b d0,$1B(a5) clr.w $1C(a5)

locret_71D9C: rts

End of function sub_71D60


||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_71D9E: ; XREF: sub_71CCA; sub_72850 tst.b $12(a5) beq.s locret_71DC4 subq.b #1,$12(a5) bne.s locret_71DC4 bset #1,(a5) tst.b 1(a5) bmi.w loc_71DBE jsr sub_726FE(pc) addq.w #4,sp rts

===========================================================================

loc_71DBE: jsr sub_729A0(pc) addq.w #4,sp

locret_71DC4: rts

End of function sub_71D9E


||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_71DC6: ; XREF: sub_71CCA; sub_72850 addq.w #4,sp btst #3,(a5) beq.s locret_71E16 tst.b $18(a5) beq.s loc_71DDA subq.b #1,$18(a5) rts

===========================================================================

loc_71DDA: subq.b #1,$19(a5) beq.s loc_71DE2 rts

===========================================================================

loc_71DE2: movea.l $14(a5),a0 move.b 1(a0),$19(a5) tst.b $1B(a5) bne.s loc_71DFE move.b 3(a0),$1B(a5) neg.b $1A(a5) rts

===========================================================================

loc_71DFE: subq.b #1,$1B(a5) move.b $1A(a5),d6 ext.w d6 add.w $1C(a5),d6 move.w d6,$1C(a5) add.w $10(a5),d6 subq.w #4,sp

locret_71E16: rts

End of function sub_71DC6


||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_71E18: ; XREF: sub_71CCA btst #1,(a5) bne.s locret_71E48 move.w $10(a5),d6 beq.s loc_71E4A

loc_71E24: ; XREF: sub_71CCA move.b $1E(a5),d0 ext.w d0 add.w d0,d6 btst #2,(a5) bne.s locret_71E48 move.w d6,d1 lsr.w #8,d1 move.b #-$5C,d0 jsr sub_72722(pc) move.b d6,d1 move.b #-$60,d0 jsr sub_72722(pc)

locret_71E48: rts

===========================================================================

loc_71E4A: bset #1,(a5) rts

End of function sub_71E18
===========================================================================

loc_71E50: ; XREF: sub_71B4C bmi.s loc_71E94 cmpi.b #2,3(a6) beq.w loc_71EFE move.b #2,3(a6) moveq #2,d3 move.b #-$4C,d0 moveq #0,d1

loc_71E6A: jsr sub_7272E(pc) jsr sub_72764(pc) addq.b #1,d0 dbf d3,loc_71E6A

moveq #2,d3 moveq #$28,d0

loc_71E7C: move.b d3,d1 jsr sub_7272E(pc) addq.b #4,d1 jsr sub_7272E(pc) dbf d3,loc_71E7C

jsr sub_729B6(pc) bra.w loc_71C44

===========================================================================

loc_71E94: ; XREF: loc_71E50 clr.b 3(a6) moveq #$30,d3 lea $40(a6),a5 moveq #6,d4

loc_71EA0: btst #7,(a5) beq.s loc_71EB8 btst #2,(a5) bne.s loc_71EB8 move.b #-$4C,d0 move.b $A(a5),d1 jsr sub_72722(pc)

loc_71EB8: adda.w d3,a5 dbf d4,loc_71EA0

lea $220(a6),a5 moveq #2,d4

loc_71EC4: btst #7,(a5) beq.s loc_71EDC btst #2,(a5) bne.s loc_71EDC move.b #-$4C,d0 move.b $A(a5),d1 jsr sub_72722(pc)

loc_71EDC: adda.w d3,a5 dbf d4,loc_71EC4

lea $340(a6),a5 btst #7,(a5) beq.s loc_71EFE btst #2,(a5) bne.s loc_71EFE move.b #-$4C,d0 move.b $A(a5),d1 jsr sub_72722(pc)

loc_71EFE: bra.w loc_71C44

---------------------------------------------------------------------------
Subroutine to play a sound or music track
---------------------------------------------------------------------------
||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


Sound_Play: ; XREF: sub_71B4C movea.l (Go_SoundTypes).l,a0 lea $A(a6),a1 ; load music track number move.b 0(a6),d3 moveq #2,d4

loc_71F12: move.b (a1),d0 ; move track number to d0 move.b d0,d1 clr.b (a1)+ subi.b #$81,d0 bcs.s loc_71F3E cmpi.b #$80,9(a6) beq.s loc_71F2C move.b d1,$A(a6) bra.s loc_71F3E

===========================================================================

loc_71F2C: andi.w #$7F,d0 move.b (a0,d0.w),d2 cmp.b d3,d2 bcs.s loc_71F3E move.b d2,d3 move.b d1,9(a6) ; set music flag

loc_71F3E: dbf d4,loc_71F12

tst.b d3 bmi.s locret_71F4A move.b d3,0(a6)

locret_71F4A: rts

End of function Sound_Play


||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


Sound_ChkValue: ; XREF: sub_71B4C moveq #0,d7 move.b 9(a6),d7 beq.w Sound_E4 bpl.s locret_71F8C move.b #$80,9(a6) ; reset music flag cmpi.b #$9F,d7 bls.w Sound_81to9F ; music $81-$9F cmpi.b #$A0,d7 bcs.w locret_71F8C cmpi.b #$CF,d7 bls.w Sound_A0toCF ; sound $A0-$CF cmpi.b #$D0,d7 bcs.w locret_71F8C cmpi.b #$E0,d7 bcs.w Sound_D0toDF ; sound $D0-$DF cmpi.b #$E4,d7 bls.s Sound_E0toE4 ; sound $E0-$E4

locret_71F8C: rts

===========================================================================

Sound_E0toE4: ; XREF: Sound_ChkValue subi.b #$E0,d7 lsl.w #2,d7 jmp Sound_ExIndex(pc,d7.w)

===========================================================================

Sound_ExIndex: bra.w Sound_E0

===========================================================================

bra.w Sound_E1

===========================================================================

bra.w Sound_E2

===========================================================================

bra.w Sound_E3

===========================================================================

bra.w Sound_E4

===========================================================================
---------------------------------------------------------------------------
Play "Say-gaa" PCM sound
---------------------------------------------------------------------------

Sound_E1: ; XREF: Sound_ExIndex move.b #$88,($A01FFF).l move.w #0,($A11100).l ; start the Z80 move.w #$11,d1

loc_71FC0: move.w #-1,d0

loc_71FC4: nop dbf d0,loc_71FC4

dbf d1,loc_71FC0

addq.w #4,sp rts

===========================================================================
---------------------------------------------------------------------------
Play music track $81-$9F
---------------------------------------------------------------------------

Sound_81to9F: ; XREF: Sound_ChkValue cmpi.b #$88,d7 ; is "extra life" music played? bne.s loc_72024 ; if not, branch tst.b $27(a6) bne.w loc_721B6 lea $40(a6),a5 moveq #9,d0

loc_71FE6: bclr #2,(a5) adda.w #$30,a5 dbf d0,loc_71FE6

lea $220(a6),a5 moveq #5,d0

loc_71FF8: bclr #7,(a5) adda.w #$30,a5 dbf d0,loc_71FF8 clr.b 0(a6) movea.l a6,a0 lea $3A0(a6),a1 move.w #$87,d0

loc_72012: move.l (a0)+,(a1)+ dbf d0,loc_72012

move.b #$80,$27(a6) clr.b 0(a6) bra.s loc_7202C

===========================================================================

loc_72024: clr.b $27(a6) clr.b $26(a6)

loc_7202C: jsr sub_725CA(pc) movea.l (off_719A0).l,a4 subi.b #$81,d7 move.b (a4,d7.w),$29(a6) movea.l (Go_MusicIndex).l,a4 lsl.w #2,d7 movea.l (a4,d7.w),a4 moveq #0,d0 move.w (a4),d0 add.l a4,d0 move.l d0,$18(a6) move.b 5(a4),d0 move.b d0,$28(a6) tst.b $2A(a6) beq.s loc_72068 move.b $29(a6),d0

loc_72068: move.b d0,2(a6) move.b d0,1(a6) moveq #0,d1 movea.l a4,a3 addq.w #6,a4 moveq #0,d7 move.b 2(a3),d7 beq.w loc_72114 subq.b #1,d7 move.b #-$40,d1 move.b 4(a3),d4 moveq #$30,d6 move.b #1,d5 lea $40(a6),a1 lea byte_721BA(pc),a2

loc_72098: bset #7,(a1) move.b (a2)+,1(a1) move.b d4,2(a1) move.b d6,$D(a1) move.b d1,$A(a1) move.b d5,$E(a1) moveq #0,d0 move.w (a4)+,d0 add.l a3,d0 move.l d0,4(a1) move.w (a4)+,8(a1) adda.w d6,a1 dbf d7,loc_72098 cmpi.b #7,2(a3) bne.s loc_720D8 moveq #$2B,d0 moveq #0,d1 jsr sub_7272E(pc) bra.w loc_72114

===========================================================================

loc_720D8: moveq #$28,d0 moveq #6,d1 jsr sub_7272E(pc) move.b #$42,d0 moveq #$7F,d1 jsr sub_72764(pc) move.b #$4A,d0 moveq #$7F,d1 jsr sub_72764(pc) move.b #$46,d0 moveq #$7F,d1 jsr sub_72764(pc) move.b #$4E,d0 moveq #$7F,d1 jsr sub_72764(pc) move.b #-$4A,d0 move.b #-$40,d1 jsr sub_72764(pc)

loc_72114: moveq #0,d7 move.b 3(a3),d7 beq.s loc_72154 subq.b #1,d7 lea $190(a6),a1 lea byte_721C2(pc),a2

loc_72126: bset #7,(a1) move.b (a2)+,1(a1) move.b d4,2(a1) move.b d6,$D(a1) move.b d5,$E(a1) moveq #0,d0 move.w (a4)+,d0 add.l a3,d0 move.l d0,4(a1) move.w (a4)+,8(a1) move.b (a4)+,d0 move.b (a4)+,$B(a1) adda.w d6,a1 dbf d7,loc_72126

loc_72154: lea $220(a6),a1 moveq #5,d7

loc_7215A: tst.b (a1) bpl.w loc_7217C moveq #0,d0 move.b 1(a1),d0 bmi.s loc_7216E subq.b #2,d0 lsl.b #2,d0 bra.s loc_72170

===========================================================================

loc_7216E: lsr.b #3,d0

loc_72170: lea dword_722CC(pc),a0 movea.l (a0,d0.w),a0 bset #2,(a0)

loc_7217C: adda.w d6,a1 dbf d7,loc_7215A

tst.w $340(a6) bpl.s loc_7218E bset #2,$100(a6)

loc_7218E: tst.w $370(a6) bpl.s loc_7219A bset #2,$1F0(a6)

loc_7219A: lea $70(a6),a5 moveq #5,d4

loc_721A0: jsr sub_726FE(pc) adda.w d6,a5 dbf d4,loc_721A0 moveq #2,d4

loc_721AC: jsr sub_729A0(pc) adda.w d6,a5 dbf d4,loc_721AC

loc_721B6: addq.w #4,sp rts

===========================================================================

byte_721BA: dc.b 6, 0, 1, 2, 4, 5, 6, 0 align 2 byte_721C2: dc.b $80, $A0, $C0, 0 align 2

===========================================================================
---------------------------------------------------------------------------
Play normal sound effect
---------------------------------------------------------------------------

Sound_A0toCF: ; XREF: Sound_ChkValue tst.b $27(a6) bne.w loc_722C6 tst.b 4(a6) bne.w loc_722C6 tst.b $24(a6) bne.w loc_722C6 cmpi.b #$B5,d7 ; is ring sound effect played? bne.s Sound_notB5 ; if not, branch tst.b $2B(a6) bne.s loc_721EE move.b #$CE,d7 ; play ring sound in left speaker

loc_721EE: bchg #0,$2B(a6) ; change speaker

Sound_notB5: cmpi.b #$A7,d7 ; is "pushing" sound played? bne.s Sound_notA7 ; if not, branch tst.b $2C(a6) bne.w locret_722C4 move.b #$80,$2C(a6)

Sound_notA7: movea.l (Go_SoundIndex).l,a0 subi.b #$A0,d7 lsl.w #2,d7 movea.l (a0,d7.w),a3 movea.l a3,a1 moveq #0,d1 move.w (a1)+,d1 add.l a3,d1 move.b (a1)+,d5 move.b (a1)+,d7 subq.b #1,d7 moveq #$30,d6

loc_72228: moveq #0,d3 move.b 1(a1),d3 move.b d3,d4 bmi.s loc_72244 subq.w #2,d3 lsl.w #2,d3 lea dword_722CC(pc),a5 movea.l (a5,d3.w),a5 bset #2,(a5) bra.s loc_7226E

===========================================================================

loc_72244: lsr.w #3,d3 lea dword_722CC(pc),a5 movea.l (a5,d3.w),a5 bset #2,(a5) cmpi.b #$C0,d4 bne.s loc_7226E move.b d4,d0 ori.b #$1F,d0 move.b d0,($C00011).l bchg #5,d0 move.b d0,($C00011).l

loc_7226E: movea.l dword_722EC(pc,d3.w),a5 movea.l a5,a2 moveq #$B,d0

loc_72276: clr.l (a2)+ dbf d0,loc_72276

move.w (a1)+,(a5) move.b d5,2(a5) moveq #0,d0 move.w (a1)+,d0 add.l a3,d0 move.l d0,4(a5) move.w (a1)+,8(a5) move.b #1,$E(a5) move.b d6,$D(a5) tst.b d4 bmi.s loc_722A8 move.b #$C0,$A(a5) move.l d1,$20(a5)

loc_722A8: dbf d7,loc_72228

tst.b $250(a6) bpl.s loc_722B8 bset #2,$340(a6)

loc_722B8: tst.b $310(a6) bpl.s locret_722C4 bset #2,$370(a6)

locret_722C4: rts

===========================================================================

loc_722C6: clr.b 0(a6) rts

===========================================================================

dword_722CC: dc.l $FFF0D0 dc.l 0 dc.l $FFF100 dc.l $FFF130 dc.l $FFF190 dc.l $FFF1C0 dc.l $FFF1F0 dc.l $FFF1F0 dword_722EC: dc.l $FFF220 dc.l 0 dc.l $FFF250 dc.l $FFF280 dc.l $FFF2B0 dc.l $FFF2E0 dc.l $FFF310 dc.l $FFF310

===========================================================================
---------------------------------------------------------------------------
Play GHZ waterfall sound
---------------------------------------------------------------------------

Sound_D0toDF: ; XREF: Sound_ChkValue tst.b $27(a6) bne.w locret_723C6 tst.b 4(a6) bne.w locret_723C6 tst.b $24(a6) bne.w locret_723C6 movea.l (Go_SoundD0).l,a0 subi.b #$D0,d7 lsl.w #2,d7 movea.l (a0,d7.w),a3 movea.l a3,a1 moveq #0,d0 move.w (a1)+,d0 add.l a3,d0 move.l d0,$20(a6) move.b (a1)+,d5 move.b (a1)+,d7 subq.b #1,d7 moveq #$30,d6

loc_72348: move.b 1(a1),d4 bmi.s loc_7235A bset #2,$100(a6) lea $340(a6),a5 bra.s loc_72364

===========================================================================

loc_7235A: bset #2,$1F0(a6) lea $370(a6),a5

loc_72364: movea.l a5,a2 moveq #$B,d0

loc_72368: clr.l (a2)+ dbf d0,loc_72368

move.w (a1)+,(a5) move.b d5,2(a5) moveq #0,d0 move.w (a1)+,d0 add.l a3,d0 move.l d0,4(a5) move.w (a1)+,8(a5) move.b #1,$E(a5) move.b d6,$D(a5) tst.b d4 bmi.s loc_72396 move.b #$C0,$A(a5)

loc_72396: dbf d7,loc_72348

tst.b $250(a6) bpl.s loc_723A6 bset #2,$340(a6)

loc_723A6: tst.b $310(a6) bpl.s locret_723C6 bset #2,$370(a6) ori.b #$1F,d4 move.b d4,($C00011).l bchg #5,d4 move.b d4,($C00011).l

locret_723C6: rts

End of function Sound_ChkValue
===========================================================================

dc.l $FFF100 dc.l $FFF1F0 dc.l $FFF250 dc.l $FFF310 dc.l $FFF340 dc.l $FFF370

||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


Snd_FadeOut1: ; XREF: Sound_E0 clr.b 0(a6) lea $220(a6),a5 moveq #5,d7

loc_723EA: tst.b (a5) bpl.w loc_72472 bclr #7,(a5) moveq #0,d3 move.b 1(a5),d3 bmi.s loc_7243C jsr sub_726FE(pc) cmpi.b #4,d3 bne.s loc_72416 tst.b $340(a6) bpl.s loc_72416 lea $340(a6),a5 movea.l $20(a6),a1 bra.s loc_72428

===========================================================================

loc_72416: subq.b #2,d3 lsl.b #2,d3 lea dword_722CC(pc),a0 movea.l a5,a3 movea.l (a0,d3.w),a5 movea.l $18(a6),a1

loc_72428: bclr #2,(a5) bset #1,(a5) move.b $B(a5),d0 jsr sub_72C4E(pc) movea.l a3,a5 bra.s loc_72472

===========================================================================

loc_7243C: jsr sub_729A0(pc) lea $370(a6),a0 cmpi.b #$E0,d3 beq.s loc_7245A cmpi.b #$C0,d3 beq.s loc_7245A lsr.b #3,d3 lea dword_722CC(pc),a0 movea.l (a0,d3.w),a0

loc_7245A: bclr #2,(a0) bset #1,(a0) cmpi.b #$E0,1(a0) bne.s loc_72472 move.b $1F(a0),($C00011).l

loc_72472: adda.w #$30,a5 dbf d7,loc_723EA

rts

End of function Snd_FadeOut1


||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


Snd_FadeOut2: ; XREF: Sound_E0 lea $340(a6),a5 tst.b (a5) bpl.s loc_724AE bclr #7,(a5) btst #2,(a5) bne.s loc_724AE jsr loc_7270A(pc) lea $100(a6),a5 bclr #2,(a5) bset #1,(a5) tst.b (a5) bpl.s loc_724AE movea.l $18(a6),a1 move.b $B(a5),d0 jsr sub_72C4E(pc)

loc_724AE: lea $370(a6),a5 tst.b (a5) bpl.s locret_724E4 bclr #7,(a5) btst #2,(a5) bne.s locret_724E4 jsr loc_729A6(pc) lea $1F0(a6),a5 bclr #2,(a5) bset #1,(a5) tst.b (a5) bpl.s locret_724E4 cmpi.b #-$20,1(a5) bne.s locret_724E4 move.b $1F(a5),($C00011).l

locret_724E4: rts

End of function Snd_FadeOut2
===========================================================================
---------------------------------------------------------------------------
Fade out music
---------------------------------------------------------------------------

Sound_E0: ; XREF: Sound_ExIndex jsr Snd_FadeOut1(pc) jsr Snd_FadeOut2(pc) move.b #3,6(a6) move.b #$28,4(a6) clr.b $40(a6) clr.b $2A(a6) rts

||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_72504: ; XREF: sub_71B4C move.b 6(a6),d0 beq.s loc_72510 subq.b #1,6(a6) rts

===========================================================================

loc_72510: subq.b #1,4(a6) beq.w Sound_E4 move.b #3,6(a6) lea $70(a6),a5 moveq #5,d7

loc_72524: tst.b (a5) bpl.s loc_72538 addq.b #1,9(a5) bpl.s loc_72534 bclr #7,(a5) bra.s loc_72538

===========================================================================

loc_72534: jsr sub_72CB4(pc)

loc_72538: adda.w #$30,a5 dbf d7,loc_72524

moveq #2,d7

loc_72542: tst.b (a5) bpl.s loc_72560 addq.b #1,9(a5) cmpi.b #$10,9(a5) bcs.s loc_72558 bclr #7,(a5) bra.s loc_72560

===========================================================================

loc_72558: move.b 9(a5),d6 jsr sub_7296A(pc)

loc_72560: adda.w #$30,a5 dbf d7,loc_72542

rts

End of function sub_72504


||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_7256A: ; XREF: Sound_E4; sub_725CA moveq #2,d3 moveq #$28,d0

loc_7256E: move.b d3,d1 jsr sub_7272E(pc) addq.b #4,d1 jsr sub_7272E(pc) dbf d3,loc_7256E

moveq #$40,d0 moveq #$7F,d1 moveq #2,d4

loc_72584: moveq #3,d3

loc_72586: jsr sub_7272E(pc) jsr sub_72764(pc) addq.w #4,d0 dbf d3,loc_72586

subi.b #$F,d0 dbf d4,loc_72584

rts

End of function sub_7256A
===========================================================================
---------------------------------------------------------------------------
Stop music
---------------------------------------------------------------------------

Sound_E4: ; XREF: Sound_ChkValue; Sound_ExIndex; sub_72504 moveq #$2B,d0 move.b #$80,d1 jsr sub_7272E(pc) moveq #$27,d0 moveq #0,d1 jsr sub_7272E(pc) movea.l a6,a0 move.w #$E3,d0

loc_725B6: clr.l (a0)+ dbf d0,loc_725B6

move.b #$80,9(a6) ; set music to $80 (silence) jsr sub_7256A(pc) bra.w sub_729B6

||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_725CA: ; XREF: Sound_ChkValue movea.l a6,a0 move.b 0(a6),d1 move.b $27(a6),d2 move.b $2A(a6),d3 move.b $26(a6),d4 move.w $A(a6),d5 move.w #$87,d0

loc_725E4: clr.l (a0)+ dbf d0,loc_725E4

move.b d1,0(a6) move.b d2,$27(a6) move.b d3,$2A(a6) move.b d4,$26(a6) move.w d5,$A(a6) move.b #$80,9(a6) jsr sub_7256A(pc) bra.w sub_729B6

End of function sub_725CA


||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_7260C: ; XREF: sub_71B4C move.b 2(a6),1(a6) lea $4E(a6),a0 moveq #$30,d0 moveq #9,d1

loc_7261A: addq.b #1,(a0) adda.w d0,a0 dbf d1,loc_7261A

rts

End of function sub_7260C
===========================================================================
---------------------------------------------------------------------------
Speed up music
---------------------------------------------------------------------------

Sound_E2: ; XREF: Sound_ExIndex tst.b $27(a6) bne.s loc_7263E move.b $29(a6),2(a6) move.b $29(a6),1(a6) move.b #$80,$2A(a6) rts

===========================================================================

loc_7263E: move.b $3C9(a6),$3A2(a6) move.b $3C9(a6),$3A1(a6) move.b #$80,$3CA(a6) rts

===========================================================================
---------------------------------------------------------------------------
Change music back to normal speed
---------------------------------------------------------------------------

Sound_E3: ; XREF: Sound_ExIndex tst.b $27(a6) bne.s loc_7266A move.b $28(a6),2(a6) move.b $28(a6),1(a6) clr.b $2A(a6) rts

===========================================================================

loc_7266A: move.b $3C8(a6),$3A2(a6) move.b $3C8(a6),$3A1(a6) clr.b $3CA(a6) rts

||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_7267C: ; XREF: sub_71B4C tst.b $25(a6) beq.s loc_72688 subq.b #1,$25(a6) rts

===========================================================================

loc_72688: tst.b $26(a6) beq.s loc_726D6 subq.b #1,$26(a6) move.b #2,$25(a6) lea $70(a6),a5 moveq #5,d7

loc_7269E: tst.b (a5) bpl.s loc_726AA subq.b #1,9(a5) jsr sub_72CB4(pc)

loc_726AA: adda.w #$30,a5 dbf d7,loc_7269E moveq #2,d7

loc_726B4: tst.b (a5) bpl.s loc_726CC subq.b #1,9(a5) move.b 9(a5),d6 cmpi.b #$10,d6 bcs.s loc_726C8 moveq #$F,d6

loc_726C8: jsr sub_7296A(pc)

loc_726CC: adda.w #$30,a5 dbf d7,loc_726B4 rts

===========================================================================

loc_726D6: bclr #2,$40(a6) clr.b $24(a6) rts

End of function sub_7267C
===========================================================================

loc_726E2: ; XREF: sub_71CCA btst #1,(a5) bne.s locret_726FC btst #2,(a5) bne.s locret_726FC moveq #$28,d0 move.b 1(a5),d1 ori.b #-$10,d1 bra.w sub_7272E

===========================================================================

locret_726FC: rts

||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_726FE: ; XREF: sub_71CEC; sub_71D9E; Sound_ChkValue; Snd_FadeOut1 btst #4,(a5) bne.s locret_72714 btst #2,(a5) bne.s locret_72714

loc_7270A: ; XREF: Snd_FadeOut2 moveq #$28,d0 move.b 1(a5),d1 bra.w sub_7272E

===========================================================================

locret_72714: rts

End of function sub_726FE
===========================================================================

loc_72716: ; XREF: sub_72A5A btst #2,(a5) bne.s locret_72720 bra.w sub_72722

===========================================================================

locret_72720: rts

||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_72722: ; XREF: sub_71E18; sub_72C4E; sub_72CB4 btst #2,1(a5) bne.s loc_7275A add.b 1(a5),d0

End of function sub_72722


||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_7272E: ; XREF: loc_71E6A move.b ($A04000).l,d2 btst #7,d2 bne.s sub_7272E move.b d0,($A04000).l nop nop nop

loc_72746: move.b ($A04000).l,d2 btst #7,d2 bne.s loc_72746

move.b d1,($A04001).l rts

End of function sub_7272E
===========================================================================

loc_7275A: ; XREF: sub_72722 move.b 1(a5),d2 bclr #2,d2 add.b d2,d0

||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_72764: ; XREF: loc_71E6A; Sound_ChkValue; sub_7256A; sub_72764 move.b ($A04000).l,d2 btst #7,d2 bne.s sub_72764 move.b d0,($A04002).l nop nop nop

loc_7277C: move.b ($A04000).l,d2 btst #7,d2 bne.s loc_7277C

move.b d1,($A04003).l rts

End of function sub_72764
===========================================================================

word_72790: dc.w $25E, $284, $2AB, $2D3, $2FE, $32D, $35C, $38F, $3C5 dc.w $3FF, $43C, $47C, $A5E, $A84, $AAB, $AD3, $AFE, $B2D dc.w $B5C, $B8F, $BC5, $BFF, $C3C, $C7C, $125E, $1284 dc.w $12AB, $12D3, $12FE, $132D, $135C, $138F, $13C5, $13FF dc.w $143C, $147C, $1A5E, $1A84, $1AAB, $1AD3, $1AFE, $1B2D dc.w $1B5C, $1B8F, $1BC5, $1BFF, $1C3C, $1C7C, $225E, $2284 dc.w $22AB, $22D3, $22FE, $232D, $235C, $238F, $23C5, $23FF dc.w $243C, $247C, $2A5E, $2A84, $2AAB, $2AD3, $2AFE, $2B2D dc.w $2B5C, $2B8F, $2BC5, $2BFF, $2C3C, $2C7C, $325E, $3284 dc.w $32AB, $32D3, $32FE, $332D, $335C, $338F, $33C5, $33FF dc.w $343C, $347C, $3A5E, $3A84, $3AAB, $3AD3, $3AFE, $3B2D dc.w $3B5C, $3B8F, $3BC5, $3BFF, $3C3C, $3C7C

||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_72850: ; XREF: sub_71B4C subq.b #1,$E(a5) bne.s loc_72866 bclr #4,(a5) jsr sub_72878(pc) jsr sub_728DC(pc) bra.w loc_7292E

===========================================================================

loc_72866: jsr sub_71D9E(pc) jsr sub_72926(pc) jsr sub_71DC6(pc) jsr sub_728E2(pc) rts

End of function sub_72850


||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_72878: ; XREF: sub_72850 bclr #1,(a5) movea.l 4(a5),a4

loc_72880: moveq #0,d5 move.b (a4)+,d5 cmpi.b #$E0,d5 bcs.s loc_72890 jsr sub_72A5A(pc) bra.s loc_72880

===========================================================================

loc_72890: tst.b d5 bpl.s loc_728A4 jsr sub_728AC(pc) move.b (a4)+,d5 tst.b d5 bpl.s loc_728A4 subq.w #1,a4 bra.w sub_71D60

===========================================================================

loc_728A4: jsr sub_71D40(pc) bra.w sub_71D60

End of function sub_72878


||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_728AC: ; XREF: sub_72878 subi.b #$81,d5 bcs.s loc_728CA add.b 8(a5),d5 andi.w #$7F,d5 lsl.w #1,d5 lea word_729CE(pc),a0 move.w (a0,d5.w),$10(a5) bra.w sub_71D60

===========================================================================

loc_728CA: bset #1,(a5) move.w #-1,$10(a5) jsr sub_71D60(pc) bra.w sub_729A0

End of function sub_728AC


||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_728DC: ; XREF: sub_72850 move.w $10(a5),d6 bmi.s loc_72920

End of function sub_728DC


||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_728E2: ; XREF: sub_72850 move.b $1E(a5),d0 ext.w d0 add.w d0,d6 btst #2,(a5) bne.s locret_7291E btst #1,(a5) bne.s locret_7291E move.b 1(a5),d0 cmpi.b #$E0,d0 bne.s loc_72904 move.b #$C0,d0

loc_72904: move.w d6,d1 andi.b #$F,d1 or.b d1,d0 lsr.w #4,d6 andi.b #$3F,d6 move.b d0,($C00011).l move.b d6,($C00011).l

locret_7291E: rts

End of function sub_728E2
===========================================================================

loc_72920: ; XREF: sub_728DC bset #1,(a5) rts

||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_72926: ; XREF: sub_72850 tst.b $B(a5) beq.w locret_7298A

loc_7292E: ; XREF: sub_72850 move.b 9(a5),d6 moveq #0,d0 move.b $B(a5),d0 beq.s sub_7296A movea.l (Go_PSGIndex).l,a0 subq.w #1,d0 lsl.w #2,d0 movea.l (a0,d0.w),a0 move.b $C(a5),d0 move.b (a0,d0.w),d0 addq.b #1,$C(a5) btst #7,d0 beq.s loc_72960 cmpi.b #$80,d0 beq.s loc_7299A

loc_72960: add.w d0,d6 cmpi.b #$10,d6 bcs.s sub_7296A moveq #$F,d6

End of function sub_72926


||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_7296A: ; XREF: sub_72504; sub_7267C; sub_72926 btst #1,(a5) bne.s locret_7298A btst #2,(a5) bne.s locret_7298A btst #4,(a5) bne.s loc_7298C

loc_7297C: or.b 1(a5),d6 addi.b #$10,d6 move.b d6,($C00011).l

locret_7298A: rts

===========================================================================

loc_7298C: tst.b $13(a5) beq.s loc_7297C tst.b $12(a5) bne.s loc_7297C rts

End of function sub_7296A
===========================================================================

loc_7299A: ; XREF: sub_72926 subq.b #1,$C(a5) rts

||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_729A0: ; XREF: sub_71D9E; Sound_ChkValue; Snd_FadeOut1; sub_728AC btst #2,(a5) bne.s locret_729B4

loc_729A6: ; XREF: Snd_FadeOut2 move.b 1(a5),d0 ori.b #$1F,d0 move.b d0,($C00011).l

locret_729B4: rts

End of function sub_729A0


||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_729B6: ; XREF: loc_71E7C lea ($C00011).l,a0 move.b #$9F,(a0) move.b #$BF,(a0) move.b #$DF,(a0) move.b #$FF,(a0) rts

End of function sub_729B6
===========================================================================

word_729CE: dc.w $356, $326, $2F9, $2CE, $2A5, $280, $25C, $23A, $21A dc.w $1FB, $1DF, $1C4, $1AB, $193, $17D, $167, $153, $140 dc.w $12E, $11D, $10D, $FE, $EF, $E2, $D6, $C9, $BE, $B4 dc.w $A9, $A0, $97, $8F, $87, $7F, $78, $71, $6B, $65 dc.w $5F, $5A, $55, $50, $4B, $47, $43, $40, $3C, $39 dc.w $36, $33, $30, $2D, $2B, $28, $26, $24, $22, $20 dc.w $1F, $1D, $1B, $1A, $18, $17, $16, $15, $13, $12 dc.w $11, 0

||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_72A5A: ; XREF: sub_71C4E; sub_71CEC; sub_72878 subi.w #$E0,d5 lsl.w #2,d5 jmp loc_72A64(pc,d5.w)

End of function sub_72A5A
===========================================================================

loc_72A64: bra.w loc_72ACC

===========================================================================

bra.w loc_72AEC

===========================================================================

bra.w loc_72AF2

===========================================================================

bra.w loc_72AF8

===========================================================================

bra.w loc_72B14

===========================================================================

bra.w loc_72B9E

===========================================================================

bra.w loc_72BA4

===========================================================================

bra.w loc_72BAE

===========================================================================

bra.w loc_72BB4

===========================================================================

bra.w loc_72BBE

===========================================================================

bra.w loc_72BC6

===========================================================================

bra.w loc_72BD0

===========================================================================

bra.w loc_72BE6

===========================================================================

bra.w loc_72BEE

===========================================================================

bra.w loc_72BF4

===========================================================================

bra.w loc_72C26

===========================================================================

bra.w loc_72D30

===========================================================================

bra.w loc_72D52

===========================================================================

bra.w loc_72D58

===========================================================================

bra.w loc_72E06

===========================================================================

bra.w loc_72E20

===========================================================================

bra.w loc_72E26

===========================================================================

bra.w loc_72E2C

===========================================================================

bra.w loc_72E38

===========================================================================

bra.w loc_72E52

===========================================================================

bra.w loc_72E64

===========================================================================

loc_72ACC: ; XREF: loc_72A64 move.b (a4)+,d1 tst.b 1(a5) bmi.s locret_72AEA move.b $A(a5),d0 andi.b #$37,d0 or.b d0,d1 move.b d1,$A(a5) move.b #$B4,d0 bra.w loc_72716

===========================================================================

locret_72AEA: rts

===========================================================================

loc_72AEC: ; XREF: loc_72A64 move.b (a4)+,$1E(a5) rts

===========================================================================

loc_72AF2: ; XREF: loc_72A64 move.b (a4)+,7(a6) rts

===========================================================================

loc_72AF8: ; XREF: loc_72A64 moveq #0,d0 move.b $D(a5),d0 movea.l (a5,d0.w),a4 move.l #0,(a5,d0.w) addq.w #2,a4 addq.b #4,d0 move.b d0,$D(a5) rts

===========================================================================

loc_72B14: ; XREF: loc_72A64 movea.l a6,a0 lea $3A0(a6),a1 move.w #$87,d0

loc_72B1E: move.l (a1)+,(a0)+ dbf d0,loc_72B1E

bset #2,$40(a6) movea.l a5,a3 move.b #$28,d6 sub.b $26(a6),d6 moveq #5,d7 lea $70(a6),a5

loc_72B3A: btst #7,(a5) beq.s loc_72B5C bset #1,(a5) add.b d6,9(a5) btst #2,(a5) bne.s loc_72B5C moveq #0,d0 move.b $B(a5),d0 movea.l $18(a6),a1 jsr sub_72C4E(pc)

loc_72B5C: adda.w #$30,a5 dbf d7,loc_72B3A

moveq #2,d7

loc_72B66: btst #7,(a5) beq.s loc_72B78 bset #1,(a5) jsr sub_729A0(pc) add.b d6,9(a5)

loc_72B78: adda.w #$30,a5 dbf d7,loc_72B66 movea.l a3,a5 move.b #$80,$24(a6) move.b #$28,$26(a6) clr.b $27(a6) move.w #0,($A11100).l addq.w #8,sp rts

===========================================================================

loc_72B9E: ; XREF: loc_72A64 move.b (a4)+,2(a5) rts

===========================================================================

loc_72BA4: ; XREF: loc_72A64 move.b (a4)+,d0 add.b d0,9(a5) bra.w sub_72CB4

===========================================================================

loc_72BAE: ; XREF: loc_72A64 bset #4,(a5) rts

===========================================================================

loc_72BB4: ; XREF: loc_72A64 move.b (a4),$12(a5) move.b (a4)+,$13(a5) rts

===========================================================================

loc_72BBE: ; XREF: loc_72A64 move.b (a4)+,d0 add.b d0,8(a5) rts

===========================================================================

loc_72BC6: ; XREF: loc_72A64 move.b (a4),2(a6) move.b (a4)+,1(a6) rts

===========================================================================

loc_72BD0: ; XREF: loc_72A64 lea $40(a6),a0 move.b (a4)+,d0 moveq #$30,d1 moveq #9,d2

loc_72BDA: move.b d0,2(a0) adda.w d1,a0 dbf d2,loc_72BDA

rts

===========================================================================

loc_72BE6: ; XREF: loc_72A64 move.b (a4)+,d0 add.b d0,9(a5) rts

===========================================================================

loc_72BEE: ; XREF: loc_72A64 clr.b $2C(a6) rts

===========================================================================

loc_72BF4: ; XREF: loc_72A64 bclr #7,(a5) bclr #4,(a5) jsr sub_726FE(pc) tst.b $250(a6) bmi.s loc_72C22 movea.l a5,a3 lea $100(a6),a5 movea.l $18(a6),a1 bclr #2,(a5) bset #1,(a5) move.b $B(a5),d0 jsr sub_72C4E(pc) movea.l a3,a5

loc_72C22: addq.w #8,sp rts

===========================================================================

loc_72C26: ; XREF: loc_72A64 moveq #0,d0 move.b (a4)+,d0 move.b d0,$B(a5) btst #2,(a5) bne.w locret_72CAA movea.l $18(a6),a1 tst.b $E(a6) beq.s sub_72C4E movea.l $20(a5),a1 tst.b $E(a6) bmi.s sub_72C4E movea.l $20(a6),a1

||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_72C4E: ; XREF: Snd_FadeOut1; et al subq.w #1,d0 bmi.s loc_72C5C move.w #$19,d1

loc_72C56: adda.w d1,a1 dbf d0,loc_72C56

loc_72C5C: move.b (a1)+,d1 move.b d1,$1F(a5) move.b d1,d4 move.b #$B0,d0 jsr sub_72722(pc) lea byte_72D18(pc),a2 moveq #$13,d3

loc_72C72: move.b (a2)+,d0 move.b (a1)+,d1 jsr sub_72722(pc) dbf d3,loc_72C72 moveq #3,d5 andi.w #7,d4 move.b byte_72CAC(pc,d4.w),d4 move.b 9(a5),d3

loc_72C8C: move.b (a2)+,d0 move.b (a1)+,d1 lsr.b #1,d4 bcc.s loc_72C96 add.b d3,d1

loc_72C96: jsr sub_72722(pc) dbf d5,loc_72C8C move.b #$B4,d0 move.b $A(a5),d1 jsr sub_72722(pc)

locret_72CAA: rts

End of function sub_72C4E
===========================================================================

byte_72CAC: dc.b 8, 8, 8, 8, $A, $E, $E, $F

||||||||||||||| S U B R O U T I N E |||||||||||||||||||||||||||||||||||||||


sub_72CB4: ; XREF: sub_72504; sub_7267C; loc_72BA4 btst #2,(a5) bne.s locret_72D16 moveq #0,d0 move.b $B(a5),d0 movea.l $18(a6),a1 tst.b $E(a6) beq.s loc_72CD8 movea.l $20(a6),a1 tst.b $E(a6) bmi.s loc_72CD8 movea.l $20(a6),a1

loc_72CD8: subq.w #1,d0 bmi.s loc_72CE6 move.w #$19,d1

loc_72CE0: adda.w d1,a1 dbf d0,loc_72CE0

loc_72CE6: adda.w #$15,a1 lea byte_72D2C(pc),a2 move.b $1F(a5),d0 andi.w #7,d0 move.b byte_72CAC(pc,d0.w),d4 move.b 9(a5),d3 bmi.s locret_72D16 moveq #3,d5

loc_72D02: move.b (a2)+,d0 move.b (a1)+,d1 lsr.b #1,d4 bcc.s loc_72D12 add.b d3,d1 bcs.s loc_72D12 jsr sub_72722(pc)

loc_72D12: dbf d5,loc_72D02

locret_72D16: rts

End of function sub_72CB4
===========================================================================

byte_72D18: dc.b $30, $38, $34, $3C, $50, $58, $54, $5C, $60, $68 dc.b $64, $6C, $70, $78, $74, $7C, $80, $88, $84, $8C byte_72D2C: dc.b $40, $48, $44, $4C

===========================================================================

loc_72D30: ; XREF: loc_72A64 bset #3,(a5) move.l a4,$14(a5) move.b (a4)+,$18(a5) move.b (a4)+,$19(a5) move.b (a4)+,$1A(a5) move.b (a4)+,d0 lsr.b #1,d0 move.b d0,$1B(a5) clr.w $1C(a5) rts

===========================================================================

loc_72D52: ; XREF: loc_72A64 bset #3,(a5) rts

===========================================================================

loc_72D58: ; XREF: loc_72A64 bclr #7,(a5) bclr #4,(a5) tst.b 1(a5) bmi.s loc_72D74 tst.b 8(a6) bmi.w loc_72E02 jsr sub_726FE(pc) bra.s loc_72D78

===========================================================================

loc_72D74: jsr sub_729A0(pc)

loc_72D78: tst.b $E(a6) bpl.w loc_72E02 clr.b 0(a6) moveq #0,d0 move.b 1(a5),d0 bmi.s loc_72DCC lea dword_722CC(pc),a0 movea.l a5,a3 cmpi.b #4,d0 bne.s loc_72DA8 tst.b $340(a6) bpl.s loc_72DA8 lea $340(a6),a5 movea.l $20(a6),a1 bra.s loc_72DB8

===========================================================================

loc_72DA8: subq.b #2,d0 lsl.b #2,d0 movea.l (a0,d0.w),a5 tst.b (a5) bpl.s loc_72DC8 movea.l $18(a6),a1

loc_72DB8: bclr #2,(a5) bset #1,(a5) move.b $B(a5),d0 jsr sub_72C4E(pc)

loc_72DC8: movea.l a3,a5 bra.s loc_72E02

===========================================================================

loc_72DCC: lea $370(a6),a0 tst.b (a0) bpl.s loc_72DE0 cmpi.b #$E0,d0 beq.s loc_72DEA cmpi.b #$C0,d0 beq.s loc_72DEA

loc_72DE0: lea dword_722CC(pc),a0 lsr.b #3,d0 movea.l (a0,d0.w),a0

loc_72DEA: bclr #2,(a0) bset #1,(a0) cmpi.b #$E0,1(a0) bne.s loc_72E02 move.b $1F(a0),($C00011).l

loc_72E02: addq.w #8,sp rts

===========================================================================

loc_72E06: ; XREF: loc_72A64 move.b #$E0,1(a5) move.b (a4)+,$1F(a5) btst #2,(a5) bne.s locret_72E1E move.b -1(a4),($C00011).l

locret_72E1E: rts

===========================================================================

loc_72E20: ; XREF: loc_72A64 bclr #3,(a5) rts

===========================================================================

loc_72E26: ; XREF: loc_72A64 move.b (a4)+,$B(a5) rts

===========================================================================

loc_72E2C: ; XREF: loc_72A64 move.b (a4)+,d0 lsl.w #8,d0 move.b (a4)+,d0 adda.w d0,a4 subq.w #1,a4 rts

===========================================================================

loc_72E38: ; XREF: loc_72A64 moveq #0,d0 move.b (a4)+,d0 move.b (a4)+,d1 tst.b $24(a5,d0.w) bne.s loc_72E48 move.b d1,$24(a5,d0.w)

loc_72E48: subq.b #1,$24(a5,d0.w) bne.s loc_72E2C addq.w #2,a4 rts

===========================================================================

loc_72E52: ; XREF: loc_72A64 moveq #0,d0 move.b $D(a5),d0 subq.b #4,d0 move.l a4,(a5,d0.w) move.b d0,$D(a5) bra.s loc_72E2C

===========================================================================

loc_72E64: ; XREF: loc_72A64 move.b #$88,d0 move.b #$F,d1 jsr sub_7272E(pc) move.b #$8C,d0 move.b #$F,d1 bra.w sub_7272E

===========================================================================

Kos_Z80: binclude sound\z80_1.bin dc.w ((SegaPCM&$FF)<<8)+((SegaPCM&$FF00)>>8) dc.b $21 dc.w (((EndOfRom-SegaPCM)&$FF)<<8)+(((EndOfRom-SegaPCM)&$FF00)>>8) binclude sound\z80_2.bin align 2 Music81: binclude sound\music81.bin align 2 Music82: binclude sound\music82.bin align 2 Music83: binclude sound\music83.bin align 2 Music84: binclude sound\music84.bin align 2 Music85: binclude sound\music85.bin align 2 Music86: binclude sound\music86.bin align 2 Music87: binclude sound\music87.bin align 2 Music88: binclude sound\music88.bin align 2 Music89: binclude sound\music89.bin align 2 Music8A: binclude sound\music8A.bin align 2 Music8B: binclude sound\music8B.bin align 2 Music8C: binclude sound\music8C.bin align 2 Music8D: binclude sound\music8D.bin align 2 Music8E: binclude sound\music8E.bin align 2 Music8F: binclude sound\music8F.bin align 2 Music90: binclude sound\music90.bin align 2 Music91: binclude sound\music91.bin align 2 Music92: binclude sound\music92.bin align 2 Music93: binclude sound\music93.bin align 2

---------------------------------------------------------------------------
Sound effect pointers
---------------------------------------------------------------------------

SoundIndex: dc.l SoundA0, SoundA1, SoundA2 dc.l SoundA3, SoundA4, SoundA5 dc.l SoundA6, SoundA7, SoundA8 dc.l SoundA9, SoundAA, SoundAB dc.l SoundAC, SoundAD, SoundAE dc.l SoundAF, SoundB0, SoundB1 dc.l SoundB2, SoundB3, SoundB4 dc.l SoundB5, SoundB6, SoundB7 dc.l SoundB8, SoundB9, SoundBA dc.l SoundBB, SoundBC, SoundBD dc.l SoundBE, SoundBF, SoundC0 dc.l SoundC1, SoundC2, SoundC3 dc.l SoundC4, SoundC5, SoundC6 dc.l SoundC7, SoundC8, SoundC9 dc.l SoundCA, SoundCB, SoundCC dc.l SoundCD, SoundCE, SoundCF SoundD0Index: dc.l SoundD0 SoundA0: binclude sound\soundA0.bin align 2 SoundA1: binclude sound\soundA1.bin align 2 SoundA2: binclude sound\soundA2.bin align 2 SoundA3: binclude sound\soundA3.bin align 2 SoundA4: binclude sound\soundA4.bin align 2 SoundA5: binclude sound\soundA5.bin align 2 SoundA6: binclude sound\soundA6.bin align 2 SoundA7: binclude sound\soundA7.bin align 2 SoundA8: binclude sound\soundA8.bin align 2 SoundA9: binclude sound\soundA9.bin align 2 SoundAA: binclude sound\soundAA.bin align 2 SoundAB: binclude sound\soundAB.bin align 2 SoundAC: binclude sound\soundAC.bin align 2 SoundAD: binclude sound\soundAD.bin align 2 SoundAE: binclude sound\soundAE.bin align 2 SoundAF: binclude sound\soundAF.bin align 2 SoundB0: binclude sound\soundB0.bin align 2 SoundB1: binclude sound\soundB1.bin align 2 SoundB2: binclude sound\soundB2.bin align 2 SoundB3: binclude sound\soundB3.bin align 2 SoundB4: binclude sound\soundB4.bin align 2 SoundB5: binclude sound\soundB5.bin align 2 SoundB6: binclude sound\soundB6.bin align 2 SoundB7: binclude sound\soundB7.bin align 2 SoundB8: binclude sound\soundB8.bin align 2 SoundB9: binclude sound\soundB9.bin align 2 SoundBA: binclude sound\soundBA.bin align 2 SoundBB: binclude sound\soundBB.bin align 2 SoundBC: binclude sound\soundBC.bin align 2 SoundBD: binclude sound\soundBD.bin align 2 SoundBE: binclude sound\soundBE.bin align 2 SoundBF: binclude sound\soundBF.bin align 2 SoundC0: binclude sound\soundC0.bin align 2 SoundC1: binclude sound\soundC1.bin align 2 SoundC2: binclude sound\soundC2.bin align 2 SoundC3: binclude sound\soundC3.bin align 2 SoundC4: binclude sound\soundC4.bin align 2 SoundC5: binclude sound\soundC5.bin align 2 SoundC6: binclude sound\soundC6.bin align 2 SoundC7: binclude sound\soundC7.bin align 2 SoundC8: binclude sound\soundC8.bin align 2 SoundC9: binclude sound\soundC9.bin align 2 SoundCA: binclude sound\soundCA.bin align 2 SoundCB: binclude sound\soundCB.bin align 2 SoundCC: binclude sound\soundCC.bin align 2 SoundCD: binclude sound\soundCD.bin align 2 SoundCE: binclude sound\soundCE.bin align 2 SoundCF: binclude sound\soundCF.bin align 2 SoundD0: binclude sound\soundD0.bin align 2 SegaPCM: binclude sound\segapcm.bin align 2 </asm> and replace it completely with: <asm> align $8000 DriverData: dc.b $F3,$F3,$ED,$56,$C3,$89,$00,$00 dc.b $2A,$15 dc.b $00,$06,$00,$09,$08,$7E dc.b $23,$66,$6F,$08,$C9 zPtrSpec $1300 dc.b $00,$4F,$06,$00,$09,$09,$00,$00,$00 dc.b $7E,$23,$66,$6F,$C9,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00 dc.b $00,$00,$00,$00,$00,$00,$00,$00,$F3,$F5,$FD,$E5,$D9,$ED,$5F,$32 dc.b $17,$1C,$CD,$21,$01,$3A,$02,$1C,$B7,$28,$12,$3A,$04,$1C,$B7,$20 dc.b $08,$3E,$06,$32,$04,$1C,$C3,$3D,$00,$3D,$32,$04,$1C,$AF,$32,$21 dc.b $1C,$3A,$30,$1C,$E6,$7F,$4F,$06,$00,$21,$DC,$00,$09,$7E Z80_0x006E: dc.b $C3,$4C,$11 dc.b $77,$0F,$77,$0F,$77,$0F,$77,$0F,$77,$0F,$77,$0F,$77,$0F,$77 dc.b $AF,$77 Z80_0x0082: dc.b $D9,$FD,$E1,$F1,$06,$01,$C9,$31,$00,$20,$0E,$00,$06,$00 dc.b $10,$FE,$0D,$28,$F9,$CD,$29,$09,$3E,$80,$3E,$06,$32,$3E,$1C,$AF dc.b $32,$27,$1C,$32,$30,$1C,$32,$3F,$1C,$32,$28,$1C,$3E,$05,$32,$04 dc.b $1C,$FB,$C3,$62,$10,$DD,$CB,$01,$7E,$C0,$DD,$CB,$00,$56,$C0,$DD dc.b $86,$01,$DD,$CB,$01,$56,$20,$09,$32,$00,$40,$00,$79,$32,$01,$40 dc.b $C9,$D6,$04,$32,$02,$40,$00,$79,$32,$03,$40,$C9 Z80_0x00DC: Dac_Sample_Selector: dc.b ((DacBank0>>$F)),((DacBank0>>$F)),((DacBank0>>$F)),((DacBank0>>$F)) dc.b ((DacBank0>>$F)),((DacBank0>>$F)),((DacBank0>>$F)),((DacBank0>>$F)) dc.b ((DacBank0>>$F)),((DacBank0>>$F)),((DacBank0>>$F)),((DacBank0>>$F)) dc.b ((DacBank0>>$F)),((DacBank0>>$F)),((DacBank0>>$F)),((DacBank0>>$F)) dc.b ((DacBank0>>$F)),((DacBank0>>$F)),((DacBank0>>$F)),((DacBank0>>$F)) dc.b ((DacBank0>>$F)),((DacBank0>>$F)),((DacBank0>>$F)),((DacBank0>>$F)) dc.b ((DacBank0>>$F)),((DacBank0>>$F)),((DacBank0>>$F)),((DacBank1>>$F)) dc.b ((DacBank1>>$F)),((DacBank1>>$F)),((DacBank1>>$F)),((DacBank1>>$F)) dc.b ((DacBank1>>$F)),((DacBank1>>$F)),((DacBank1>>$F)),((DacBank1>>$F)) dc.b ((DacBank1>>$F)),((DacBank1>>$F)),((DacBank1>>$F)),((DacBank1>>$F)) dc.b ((DacBank1>>$F)),((DacBank1>>$F)),((DacBank1>>$F)),((DacBank2>>$F)) dc.b ((DacBank2>>$F)),((DacBank2>>$F)),((DacBank2>>$F)),((DacBank2>>$F)) dc.b ((DacBank2>>$F)),((DacBank2>>$F)),((DacBank2>>$F)),((DacBank2>>$F)) dc.b ((DacBank2>>$F)),((DacBank2>>$F)),((DacBank2>>$F)),((DacBank2>>$F)) dc.b ((DacBank2>>$F)),((DacBank2>>$F)),((DacBank2>>$F)),((DacBank2>>$F)) dc.b ((DacBank2>>$F)),((DacBank2>>$F)),((DacBank2>>$F)),((DacBank2>>$F)) dc.b ((DacBank2>>$F)),((DacBank2>>$F)),((DacBank2>>$F)),((DacBank2>>$F)) dc.b ((DacBank2>>$F)) dc.b $CD,$E8,$07,$CD,$A2,$01,$CD,$B1,$09,$CD,$62,$08,$CD,$C6,$08 dc.b $3A,$16,$1C,$FE,$29,$20,$18,$3A,$0A,$1C,$FE,$2A,$28,$04,$FE,$32 dc.b $38,$04,$AF,$32,$0A,$1C,$AF,$32,$0B,$1C,$32,$0C,$1C,$18,$1F,$3A dc.b $16,$1C,$FE,$FF,$28,$18,$21,$0A,$1C,$5E,$23,$56,$23,$7E,$B2,$B3 dc.b $28,$0C,$CD,$C7,$09,$CD,$DF,$04,$CD,$DF,$04,$CD,$DF,$04 Z80_0x016E: dc.b $3A,$3E,$1C dc.b $FE,$00 dc.b $C2 zPtrSpec Z80DefaultBankSwitch dc.b $CD zPtrSpec Z80BankSwitch0 dc.b $18,$03 Z80DefaultBankSwitch: dc.b $CD zPtrSpec Z80BankSwitch dc.b $00,$00,$00,$00,$00 Z80_0x0183: dc.b $AF,$32,$19,$1C,$3A,$16,$1C,$FE,$FF,$CC,$05,$0A,$DD dc.b $21,$40,$1C,$DD,$CB,$00,$7E,$C4,$7A,$0B,$06,$08,$DD,$21,$70,$1C dc.b $18,$1A,$3E,$01,$32,$19,$1C Z80_0x01A7: dc.b $3E, ((SndBank>>$0F)) dc.b $CD zPtrSpec Z80BankSwitch dc.b $00,$00,$00,$00,$00,$00,$00,$00,$00,$00 dc.b $DD,$21,$F0,$1D,$06,$07,$C5,$DD,$CB,$00 dc.b $7E,$C4,$E6,$01,$11,$30,$00,$DD,$19,$C1,$10,$F0,$3A,$08,$1C,$B7 dc.b $C8,$3A,$2F,$1C,$B7,$C2,$E1,$01,$3A,$08,$1C,$32,$2F,$1C,$C3,$27 dc.b $01,$3D,$32,$2F,$1C,$C9,$DD,$CB,$01,$7E,$C2,$9C,$0F,$CD,$37,$03 dc.b $20,$17,$CD,$74,$02,$DD,$CB,$00,$66,$C0,$CD,$9B,$03,$CD,$6C,$04 dc.b $CD,$C6,$03,$CD,$28,$02,$C3,$3F,$03,$DD,$CB,$00,$66,$C0,$CD,$6A dc.b $03,$DD,$7E,$1E,$B7,$28,$06,$DD,$35,$1E,$CA,$58,$03,$CD,$6C,$04 dc.b $DD,$CB,$00,$76,$C0,$CD,$C6,$03,$DD,$CB,$00,$56,$C0,$DD,$CB,$00 dc.b $46,$C2,$41,$02,$3E,$A4,$4C,$CD,$B5,$00,$3E,$A0,$4D,$CD,$B5,$00 dc.b $C9,$DD,$7E,$01,$FE,$02,$20,$EC,$06,$04,$21,$6F,$02,$C5,$7E,$23 dc.b $E5,$EB,$4E,$23,$46,$23,$EB,$DD,$6E,$0D,$DD,$66,$0E,$09,$F5,$4C dc.b $CD,$C8,$00,$F1,$D6,$04,$4D,$CD,$C8,$00,$E1,$C1,$10,$DF,$C9,$AD dc.b $AE,$AC,$A6,$C9,$DD,$5E,$03,$DD,$56,$04,$DD,$CB,$00,$8E,$DD,$CB dc.b $00,$A6,$1A,$13,$FE,$E0,$D2,$CF,$0B,$08,$CD,$58,$03,$08,$DD,$CB dc.b $00,$5E,$C2,$E5,$02,$B7,$F2,$05,$03,$D6,$81,$F2,$A3,$02,$CD,$44 dc.b $10,$18,$2E,$DD,$86,$05,$21,$88,$0A,$F5,$DF,$F1,$DD,$CB,$01,$7E dc.b $20,$19,$D5,$16,$08,$1E,$0C,$08,$AF,$08,$93,$38,$05,$08,$82,$18 dc.b $F8,$08,$83,$21,$30,$0B,$DF,$08,$B4,$67,$D1,$DD,$75,$0D,$DD,$74 dc.b $0E,$1A,$B7,$F2,$04,$03,$DD,$7E,$0C,$DD,$77,$0B,$18,$2D,$1A,$13 dc.b $DD,$77,$11,$18,$1E,$67,$1A,$13,$6F,$B4,$28,$0C,$DD,$7E,$05,$06 dc.b $00,$B7,$F2,$F6,$02,$05,$4F,$09,$DD,$75,$0D,$DD,$74,$0E,$1A,$13 dc.b $DD,$77,$11,$1A,$13,$CD,$2D,$03,$DD,$77,$0C,$DD,$73,$03,$DD,$72 dc.b $04,$DD,$7E,$0C,$DD,$77,$0B,$DD,$CB,$00,$4E,$C0,$AF,$DD,$77,$25 dc.b $DD,$77,$22,$DD,$77,$17,$DD,$7E,$1F,$DD,$77,$1E,$C9,$DD,$46,$02 dc.b $05,$C8,$4F,$81,$10,$FD,$C9,$DD,$7E,$0B,$3D,$DD,$77,$0B,$C9,$DD dc.b $7E,$0D,$DD,$B6,$0E,$C8,$DD,$7E,$00,$E6,$06,$C0,$DD,$7E,$01,$F6 dc.b $F0,$4F,$3E,$28,$CD,$C8,$00,$C9,$DD,$7E,$00,$E6,$06,$C0,$DD,$4E dc.b $01,$CB,$79,$C0,$3E,$28,$CD,$C8,$00,$C9,$DD,$7E,$18,$B7,$C8,$F8 dc.b $3D,$0E,$0A,$CF,$DF,$CD,$12,$10,$DD,$66,$1D,$DD,$6E,$1C,$11,$AE dc.b $04,$06,$04,$DD,$4E,$19,$F5,$CB,$29,$C5,$30,$08,$86,$E6,$7F,$4F dc.b $1A,$CD,$B5,$00,$C1,$13,$23,$F1,$10,$EC,$C9,$DD,$CB,$07,$7E,$C8 dc.b $DD,$CB,$00,$4E,$C0,$DD,$5E,$20,$DD,$56,$21,$DD,$E5,$E1,$06,$00 dc.b $0E,$24,$09,$EB,$ED,$A0,$ED,$A0,$ED,$A0,$7E,$CB,$3F,$12,$AF,$DD dc.b $77,$22,$DD,$77,$23,$C9,$DD,$7E,$07,$B7,$C8,$FE,$80,$20,$48,$DD dc.b $35,$24,$C0,$DD,$34,$24,$E5,$DD,$6E,$22,$DD,$66,$23,$DD,$5E,$20 dc.b $DD,$56,$21,$D5,$FD,$E1,$DD,$35,$25,$20,$17,$FD,$7E,$01,$DD,$77 dc.b $25,$DD,$7E,$26,$4F,$E6,$80,$07,$ED,$44,$47,$09,$DD,$75,$22,$DD dc.b $74,$23,$C1,$09,$DD,$35,$27,$C0,$FD,$7E,$03,$DD,$77,$27,$DD,$7E dc.b $26,$ED,$44,$DD,$77,$26,$C9,$3D,$EB,$0E,$08,$CF,$DF,$18,$03,$DD dc.b $77,$25,$E5,$DD,$4E,$25,$06,$00,$09,$7E,$E1,$CB,$7F,$CA,$5D,$04 dc.b $FE,$82,$28,$12,$FE,$80,$28,$12,$FE,$84,$28,$11,$26,$FF,$30,$1F dc.b $DD,$CB,$00,$F6,$E1,$C9,$03,$0A,$18,$D5,$AF,$18,$D2,$03,$0A,$DD dc.b $86,$22,$DD,$77,$22,$DD,$34,$25,$DD,$34,$25,$18,$C5,$26,$00,$6F dc.b $DD,$46,$22,$04,$EB,$19,$10,$FD,$DD,$34,$25,$C9,$DD,$66,$0E,$DD dc.b $6E,$0D,$06,$00,$DD,$7E,$10,$B7,$F2,$7D,$04,$06,$FF,$4F,$09,$C9 dc.b $2A,$37,$1C,$3A,$19,$1C,$B7,$28,$06,$DD,$6E,$2A,$DD,$66,$2B,$AF dc.b $B0,$C8,$11,$19,$00,$19,$10,$FD,$C9,$B0,$30,$38,$34,$3C,$50,$58 dc.b $54,$5C,$60,$68,$64,$6C,$70,$78,$74,$7C,$80,$88,$84,$8C,$40,$48 dc.b $44,$4C,$90,$98,$94,$9C,$11,$99,$04,$DD,$4E,$0A,$3E,$B4,$CD,$B5 dc.b $00,$CD,$D7,$04,$DD,$77,$1B,$06,$14,$CD,$D7,$04,$10,$FB,$DD,$75 dc.b $1C,$DD,$74,$1D,$C3,$9C,$0C,$1A,$13,$4E,$23,$CD,$B5,$00,$C9,$3A dc.b $05,$1C,$32,$09,$1C,$3A,$06,$1C,$32,$05,$1C,$3A,$07,$1C,$32,$06 dc.b $1C,$AF,$32,$07,$1C,$3A,$09,$1C,$FE,$FF,$CA,$FB,$09,$FE,$33,$DA dc.b $4A,$05,$FE,$E0,$DA,$99,$06,$FE,$E1,$DA,$29,$09,$FE,$E6,$D2,$29 dc.b $09,$D6,$E1,$21,$1C,$05,$DF,$AF,$32,$18,$1C,$E9,$45,$08,$29,$09 dc.b $A1,$09,$26,$05,$45,$08,$DD,$21,$F0,$1D,$06,$07,$3E,$01,$32,$19 dc.b $1C,$C5,$DD,$CB,$00,$7E,$C4,$45,$05,$11,$30,$00,$DD,$19,$C1,$10 dc.b $F0,$CD,$80,$06,$C9,$E5,$E5,$C3,$61,$0C,$D6,$01,$F8,$F5,$FE,$29 dc.b $C2,$CD,$05,$3A,$29,$1C,$B7,$CA,$72,$05,$AF,$32,$0A,$1C,$32,$0B dc.b $1C,$32,$0C,$1C,$32,$05,$1C,$32,$06,$1C,$32,$07,$1C,$32,$09,$1C dc.b $F1,$C9,$3A,$16,$1C,$FE,$29,$CA,$D0,$05,$AF,$32,$0A,$1C,$32,$0B dc.b $1C,$32,$0C,$1C,$32,$05,$1C,$32,$06,$1C,$32,$07,$1C,$3A,$3E,$1C dc.b $32,$2D,$1C,$3A,$08,$1C,$32,$2E,$1C,$AF,$32,$08,$1C,$21,$40,$1C dc.b $11,$F0,$1D,$01,$B0,$01,$ED,$B0,$21,$F0,$1D,$11,$30,$00,$06,$09 dc.b $7E,$E6,$7F,$CB,$D6,$77,$19,$10,$F7,$3E,$29,$32,$16,$1C,$3A,$24 dc.b $1C,$32,$2C,$1C,$2A,$37,$1C,$22,$2A,$1C,$C3,$D0,$05,$CD,$29,$09 dc.b $F1,$F5 Z80_0x05D2: dc.b $21,$48,$0B dc.b $85,$6F,$8C,$95,$67,$22,$DE,$05,$3A,$48,$0B dc.b $32,$3E,$1C Z80_0x05E3: dc.b $CD zPtrSpec Z80BankSwitch dc.b $00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00 dc.b $3E,$B6,$32,$02,$40,$00,$3E,$C0,$32,$03,$40 dc.b $F1,$0E,$04,$CF,$DF,$E5,$E5,$E7,$22,$37,$1C,$E1,$FD,$E1,$FD,$7E dc.b $05,$32,$13,$1C,$32,$24,$1C,$11,$06,$00,$19,$22,$33,$1C,$21,$85 dc.b $06,$22,$35,$1C,$11,$40,$1C,$FD,$46,$02,$FD,$7E,$04,$C5,$2A,$35 dc.b $1C,$ED,$A0,$ED,$A0,$12,$13,$22,$35,$1C,$2A,$33,$1C,$ED,$A0,$ED dc.b $A0,$ED,$A0,$ED,$A0,$22,$33,$1C,$CD,$AE,$07,$C1,$10,$DF,$FD,$7E dc.b $03,$B7,$CA,$80,$06,$47,$21,$93,$06,$22,$35,$1C,$11,$60,$1D,$FD dc.b $7E,$04,$C5,$2A,$35,$1C,$ED,$A0,$ED,$A0,$12,$13,$22,$35,$1C,$2A dc.b $33,$1C,$01,$06,$00,$ED,$B0,$22,$33,$1C,$CD,$B5,$07,$C1,$10,$E2 dc.b $AF,$32,$09,$1C,$C9,$80,$06,$80,$00,$80,$01,$80,$02,$80,$04,$80 dc.b $05,$80,$06,$80,$80,$80,$A0,$80,$C0,$D6,$33,$B7,$C2,$A7,$06,$3A dc.b $28,$1C,$EE,$01,$32,$28,$1C,$08 Z80_0x06A8: dc.b $3E, ((SndBank>>$0F)) dc.b $CD zPtrSpec Z80BankSwitch dc.b $00,$00,$00,$00,$00,$00,$00,$00,$00,$00 Z80_0x06B7: dc.b $AF,$0E,$06,$32,$19,$1C,$08,$FE,$78 dc.b $CA,$F5,$06,$FE,$89,$DA,$EF,$06,$F5,$47,$3A,$25,$1C,$90,$C2,$E4 dc.b $06,$3E,$80,$32,$26,$1C,$CF,$F1,$4F,$DF,$23,$23,$23,$7E,$32,$31 dc.b $1C,$C3,$80,$06,$AF,$32,$26,$1C,$F1,$32,$25,$1C,$C3,$F5,$06,$F5 dc.b $AF,$32,$27,$1C,$F1,$CF,$DF,$E5,$E7,$22,$39,$1C,$AF,$32,$15,$1C dc.b $E1,$E5,$FD,$E1,$FD,$7E,$02,$32,$3B,$1C,$11,$04,$00,$19,$FD,$46 dc.b $03,$78,$32,$31,$1C,$C5,$E5,$23,$4E,$CD,$78,$07,$CB,$D6,$DD,$E5 dc.b $3A,$19,$1C,$B7,$28,$03,$E1,$FD,$E5,$D1,$E1,$ED,$A0,$1A,$FE,$02 dc.b $CC,$5E,$09,$ED,$A0,$3A,$3B,$1C,$12,$13,$ED,$A0,$ED,$A0,$ED,$A0 dc.b $ED,$A0,$CD,$AE,$07,$DD,$CB,$00,$7E,$28,$0C,$DD,$7E,$01,$FD,$BE dc.b $01,$20,$04,$FD,$CB,$00,$D6,$E5,$2A,$39,$1C,$3A,$19,$1C,$B7,$28 dc.b $04,$FD,$E5,$DD,$E1,$DD,$75,$2A,$DD,$74,$2B,$CD,$58,$03,$CD,$6B dc.b $09,$E1,$C1,$10,$A0,$C3,$80,$06,$CB,$79,$20,$08,$79,$CB,$57,$28 dc.b $1A,$3D,$18,$17,$3E,$1F,$CD,$4D,$10,$3E,$FF,$32,$11,$7F,$79,$CB dc.b $3F,$CB,$3F,$CB,$3F,$CB,$3F,$CB,$3F,$C6,$02,$D6,$02,$32,$32,$1C dc.b $F5,$21,$C8,$07,$DF,$E5,$DD,$E1,$F1,$21,$D8,$07,$DF,$C9,$08,$AF dc.b $12,$13,$12,$13,$08,$EB,$36,$30,$23,$36,$C0,$23,$36,$01,$06,$24 dc.b $23,$36,$00,$10,$FB,$23,$EB,$C9,$F0,$1D,$20,$1E,$50,$1E,$80,$1E dc.b $B0,$1E,$E0,$1E,$10,$1F,$10,$1F,$D0,$1C,$00,$1D,$30,$1D,$40,$1C dc.b $60,$1D,$90,$1D,$C0,$1D,$C0,$1D,$21,$10,$1C,$7E,$B7,$C8,$FA,$F9 dc.b $07,$D1,$3D,$C0,$36,$02,$C3,$72,$09,$AF,$77,$3A,$0D,$1C,$B7,$C2 dc.b $29,$09,$DD,$21,$70,$1C,$06,$06,$3A,$11,$1C,$B7,$20,$06,$DD,$CB dc.b $00,$7E,$28,$08,$DD,$4E,$0A,$3E,$B4,$CD,$B5,$00,$11,$30,$00,$DD dc.b $19,$10,$E5,$DD,$21,$40,$1F,$06,$07,$DD,$CB,$00,$7E,$28,$0E,$DD dc.b $CB,$01,$7E,$20,$08,$DD,$4E,$0A,$3E,$B4,$CD,$B5,$00,$11,$30,$00 dc.b $DD,$19,$10,$E5,$C9,$3E,$28,$32,$0D,$1C,$3E,$06,$32,$0F,$1C,$32 dc.b $0E,$1C,$AF,$32,$40,$1C,$32,$C0,$1D,$32,$60,$1D,$32,$90,$1D,$C3 dc.b $A1,$09,$21,$0D,$1C,$7E,$B7,$C8,$FC,$52,$08,$CB,$BE,$3A,$0F,$1C dc.b $3D,$28,$04,$32,$0F,$1C,$C9,$3A,$0E,$1C,$32,$0F,$1C,$3A,$0D,$1C dc.b $3D,$32,$0D,$1C,$CA,$29,$09,$3A,$3E,$1C Z80_0x088A: dc.b $21,$00,$60 dc.b $77,$1F,$77,$1F,$77,$1F,$77,$AF,$16,$01,$72,$77,$77,$77,$77 Z80_0x089C: dc.b $DD,$21,$40,$1C dc.b $06,$06,$DD,$34,$06,$F2,$AD,$08,$DD,$35,$06,$18,$11,$DD,$CB,$00 dc.b $7E,$28,$0B,$DD,$CB,$00,$56,$20,$05,$C5,$CD,$9C,$0C,$C1,$11,$30 dc.b $00,$DD,$19,$10,$DD,$C9,$3A,$29,$1C,$B7,$C8,$3A,$3E,$1C Z80_0x08CE: dc.b $CD zPtrSpec Z80BankSwitch dc.b $00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00 Z80_0x08E0: dc.b $3A,$0E,$1C,$3D,$32,$0E,$1C,$C0,$3A,$0F,$1C,$32,$0E,$1C,$06,$05 dc.b $DD,$21,$70,$1C,$11,$30,$00,$DD,$7E,$06,$3D,$DD,$77,$06,$C5,$CD dc.b $9C,$0C,$C1,$DD,$19,$10,$F0,$3A,$29,$1C,$3D,$32,$29,$1C,$C0,$06 dc.b $03,$DD,$21,$60,$1D,$11,$30,$00,$DD,$CB,$00,$96,$DD,$19,$10,$F8 dc.b $DD,$21,$40,$1C,$DD,$CB,$00,$96,$C9,$21,$0D,$1C,$11,$0E,$1C,$01 dc.b $C6,$03,$36,$00,$ED,$B0,$AF,$32,$08,$1C,$DD,$21,$85,$06,$06,$06 dc.b $C5,$CD,$DB,$09,$CD,$6B,$09,$DD,$23,$DD,$23,$C1,$10,$F2,$06,$07 dc.b $AF,$32,$0D,$1C,$CD,$A1,$09,$0E,$00,$3E,$2B,$CD,$C8,$00,$AF,$32 dc.b $12,$1C,$4F,$3E,$27,$CD,$C8,$00,$C3,$80,$06,$3E,$90,$0E,$00,$C3 dc.b $EF,$09,$CD,$A1,$09,$C5,$F5,$06,$03,$3E,$B4,$0E,$00,$F5,$CD,$C8 dc.b $00,$F1,$3C,$10,$F8,$06,$02,$3E,$B4,$F5,$CD,$D3,$00,$F1,$3C,$10 dc.b $F8,$0E,$00,$06,$06,$3E,$28,$F5,$CD,$C8,$00,$0C,$F1,$10,$F8,$F1 dc.b $C1,$C5,$06,$04,$3E,$9F,$32,$11,$7F,$C6,$20,$10,$F9,$C1,$C3,$80 dc.b $06,$3A,$24,$1C,$21,$13,$1C,$86,$77,$D0,$21,$4B,$1C,$11,$30,$00 dc.b $06,$09,$34,$19,$10,$FC,$C9,$21,$0A,$1C,$11,$05,$1C,$ED,$A0,$ED dc.b $A0,$ED,$A0,$AF,$2B,$77,$2B,$77,$2B,$77,$C9,$CD,$EB,$09,$3E,$40 dc.b $0E,$7F,$CD,$EF,$09,$DD,$4E,$01,$C3,$64,$03,$3E,$80,$0E,$FF,$06 dc.b $04,$F5,$CD,$B5,$00,$F1,$C6,$04,$10,$F7,$C9,$CD,$29,$09,$3E,$01 dc.b $32,$3F,$1C,$E1,$C9,$AF,$32,$16,$1C,$3A,$2C,$1C,$32,$24,$1C,$3A dc.b $2E,$1C,$32,$08,$1C,$2A,$2A,$1C,$22,$37,$1C Z80_0x0A1B: dc.b $3A,$2D,$1C,$32,$3E,$1C dc.b $CD zPtrSpec Z80BankSwitch dc.b $00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00 Z80_0x0A33: dc.b $21,$F0,$1D,$11,$40,$1C,$01,$B0,$01,$ED,$B0,$3A,$40 dc.b $1C,$F6,$84,$32,$40,$1C,$DD,$21,$70,$1C,$06,$08,$DD,$7E,$00,$F6 dc.b $84,$DD,$77,$00,$DD,$CB,$01,$7E,$C2,$73,$0A,$DD,$CB,$00,$96,$DD dc.b $7E,$06,$C6,$40,$DD,$77,$06,$DD,$7E,$08,$C5,$47,$CD,$80,$04,$CD dc.b $B6,$04,$C1,$11,$30,$00,$DD,$19,$10,$D2,$3E,$40,$32,$29,$1C,$3E dc.b $02,$32,$0F,$1C,$32,$0E,$1C,$C9,$FF,$03,$FF,$03,$FF,$03,$FF,$03 dc.b $FF,$03,$FF,$03,$FF,$03,$FF,$03,$FF,$03,$F7,$03,$BE,$03,$88,$03 dc.b $56,$03,$26,$03,$F9,$02,$CE,$02,$A5,$02,$80,$02,$5C,$02,$3A,$02 dc.b $1A,$02,$FB,$01,$DF,$01,$C4,$01,$AB,$01,$93,$01,$7D,$01,$67,$01 dc.b $53,$01,$40,$01,$2E,$01,$1D,$01,$0D,$01,$FE,$00,$EF,$00,$E2,$00 dc.b $D6,$00,$C9,$00,$BE,$00,$B4,$00,$A9,$00,$A0,$00,$97,$00,$8F,$00 dc.b $87,$00,$7F,$00,$78,$00,$71,$00,$6B,$00,$65,$00,$5F,$00,$5A,$00 dc.b $55,$00,$50,$00,$4B,$00,$47,$00,$43,$00,$40,$00,$3C,$00,$39,$00 dc.b $36,$00,$33,$00,$30,$00,$2D,$00,$2B,$00,$28,$00,$26,$00,$24,$00 dc.b $22,$00,$20,$00,$1F,$00,$1D,$00,$1B,$00,$1A,$00,$18,$00,$17,$00 dc.b $16,$00,$15,$00,$13,$00,$12,$00,$11,$00,$10,$00,$00,$00,$00,$00 dc.b $84,$02,$AB,$02,$D3,$02,$FE,$02,$2D,$03,$5C,$03,$8F,$03,$C5,$03 dc.b $FF,$03,$3C,$04,$7C,$04,$C0,$04 BankSelector: dc.b ((Bank1>>$0F)),((Bank1>>$0F)),((Bank1>>$0F)),((Bank1>>$0F)) dc.b ((Bank1>>$0F)),((Bank1>>$0F)),((Bank1>>$0F)),((Bank1>>$0F)) dc.b ((Bank1>>$0F)),((Bank1>>$0F)),((Bank2>>$0F)),((Bank2>>$0F)) dc.b ((Bank2>>$0F)),((Bank2>>$0F)),((Bank2>>$0F)),((Bank2>>$0F)) dc.b ((Bank2>>$0F)),((Bank2>>$0F)),((Bank2>>$0F)),((Bank2>>$0F)) dc.b ((Bank2>>$0F)),((Bank2>>$0F)),((Bank2>>$0F)),((Bank2>>$0F)) dc.b ((Bank2>>$0F)),((Bank1>>$0F)),((Bank2>>$0F)),((Bank2>>$0F)) dc.b ((Bank3>>$0F)),((Bank3>>$0F)),((Bank3>>$0F)),((Bank3>>$0F)) dc.b ((Bank3>>$0F)),((Bank3>>$0F)),((Bank3>>$0F)),((Bank3>>$0F)) dc.b ((Bank3>>$0F)),((Bank3>>$0F)),((Bank3>>$0F)),((Bank3>>$0F)) dc.b ((Bank2>>$0F)),((Bank3>>$0F)),((Bank3>>$0F)),((Bank3>>$0F)) dc.b ((Bank3>>$0F)),((Bank0>>$0F)),((Bank2>>$0F)),((Bank0>>$0F)) dc.b ((Bank3>>$0F)),((Bank3>>$0F)) dc.b $CD,$37,$03,$C0,$DD,$5E dc.b $03,$DD,$56,$04,$1A,$13,$FE,$E0,$D2,$C5,$0B,$B7,$FA,$93,$0B,$1B dc.b $DD,$7E,$0D,$DD,$77,$0D,$FE,$80,$CA,$B5,$0B,$CB,$BF,$D5,$08,$CD dc.b $58,$03,$CD,$5E,$09,$08,$DD,$21,$40,$1C,$DD,$CB,$00,$56,$C2,$B4 dc.b $0B,$32,$30,$1C,$D1,$1A,$13,$B7,$F2,$05,$03,$1B,$DD,$7E,$0C,$DD dc.b $77,$0B,$C3,$0B,$03,$21,$CB,$0B,$C3,$D2,$0B,$13,$C3,$84,$0B,$21 dc.b $DB,$0B,$E5,$D6,$E0,$21,$DF,$0B,$DF,$1A,$E9,$13,$C3,$82,$02,$33 dc.b $0C,$59,$0C,$5D,$0C,$61,$0C,$67,$0C,$83,$0C,$85,$0C,$BD,$0C,$C3 dc.b $0C,$47,$0C,$2F,$0C,$CD,$0C,$E3,$0C,$FD,$0C,$03,$0D,$10,$0D,$4F dc.b $0D,$5D,$0D,$69,$0D,$11,$0E,$65,$0D,$30,$0E,$39,$0E,$3F,$0E,$56 dc.b $0E,$70,$0E,$83,$0E,$89,$0E,$90,$0E,$B2,$0E,$C0,$0E,$07,$0F,$0E dc.b $0F,$12,$0F,$1A,$0F,$55,$0F,$63,$0F,$72,$0F,$8D,$0F,$96,$0F,$32 dc.b $30,$1C,$C9,$0E,$3F,$DD,$7E,$0A,$A1,$D5,$EB,$B6,$DD,$77,$0A,$4F dc.b $3E,$B4,$CD,$B5,$00,$D1,$C9,$21,$27,$1C,$7E,$DD,$86,$05,$DD,$77 dc.b $05,$FE,$10,$CA,$57,$0C,$34,$1B,$C9,$DD,$77,$10,$C9,$32,$16,$1C dc.b $C9,$CD,$DB,$09,$C3,$69,$0D,$DD,$CB,$01,$7E,$28,$0D,$CB,$3F,$CB dc.b $3F,$CB,$3F,$EE,$0F,$E6,$0F,$C3,$F9,$0C,$EE,$7F,$E6,$7F,$DD,$77 dc.b $06,$18,$19,$13,$1A,$DD,$CB,$01,$7E,$C0,$DD,$86,$06,$F2,$99,$0C dc.b $EA,$97,$0C,$AF,$C3,$99,$0C,$3E,$7F,$DD,$77,$06,$D5,$11,$AE,$04 dc.b $DD,$6E,$1C,$DD,$66,$1D,$06,$04,$7E,$B7,$F2,$B0,$0C,$DD,$86,$06 dc.b $E6,$7F,$4F,$1A,$CD,$B5,$00,$13,$23,$10,$ED,$D1,$C9,$DD,$CB,$00 dc.b $CE,$1B,$C9,$CD,$2D,$03,$DD,$77,$1E,$DD,$77,$1F,$C9,$13,$C6,$28 dc.b $4F,$06,$00,$DD,$E5,$E1,$09,$7E,$3D,$CA,$DE,$0C,$13,$C9,$AF,$77 dc.b $C3,$39,$0E,$DD,$CB,$01,$7E,$C8,$DD,$CB,$00,$A6,$DD,$35,$17,$DD dc.b $86,$06,$FE,$0F,$DA,$F9,$0C,$3E,$0F,$DD,$77,$06,$C9,$D6,$40,$DD dc.b $77,$05,$C9,$CD,$0A,$0D,$CD,$C8,$00,$C9,$EB,$7E,$23,$4E,$EB,$C9 dc.b $DD,$CB,$01,$7E,$20,$30,$CD,$EB,$09,$1A,$DD,$77,$08,$B7,$F2,$3C dc.b $0D,$13,$1A,$DD,$77,$0F,$D5,$DD,$7E,$0F,$D6,$81,$0E,$04,$CF,$DF dc.b $E7,$DD,$7E,$08,$E6,$7F,$47,$CD,$8F,$04,$18,$05,$D5,$47,$CD,$80 dc.b $04,$CD,$B6,$04,$D1,$C9,$B7,$F2,$35,$0E,$13,$C3,$35,$0E,$C9,$DD dc.b $73,$20,$DD,$72,$21,$DD,$36,$07,$80,$13,$13,$13,$C9,$13,$DD,$CB dc.b $01,$7E,$20,$01,$1A,$DD,$77,$07,$C9,$DD,$CB,$00,$BE,$3E,$1F,$32 dc.b $15,$1C,$CD,$58,$03,$DD,$4E,$01,$DD,$E5,$CD,$78,$07,$3A,$19,$1C dc.b $B7,$28,$77,$AF,$32,$18,$1C,$E5,$2A,$37,$1C,$DD,$E1,$DD,$CB,$00 dc.b $96,$DD,$CB,$01,$7E,$20,$68,$DD,$CB,$00,$7E,$28,$5D,$3E,$02,$DD dc.b $BE,$01,$20,$0D,$3E,$4F,$DD,$CB,$00,$46,$20,$02,$E6,$0F,$CD,$E9 dc.b $0E,$DD,$7E,$08,$B7,$F2,$BD,$0D,$CD,$26,$0D,$18,$3A,$47,$E5 Z80_0x0DBF: dc.b $3A,$3E,$1C dc.b $CD zPtrSpec Z80BankSwitch dc.b $00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00 Z80_0x0DD4: dc.b $E1,$CD,$8F,$04,$CD,$B6,$04 Z80_0x0DDB: dc.b $3E,((SndBank>>$0F)) dc.b $CD zPtrSpec Z80BankSwitch dc.b $00,$00,$00,$00,$00,$00,$00,$00,$00,$00 dc.b $DD,$7E,$18,$B7,$F2,$FA dc.b $0D,$DD,$5E,$19,$DD,$56,$1A,$CD,$7C,$0F,$DD,$E1,$E1,$E1,$C9,$DD dc.b $CB,$00,$46,$28,$F5,$DD,$7E,$1A,$B7,$F2,$0F,$0E,$32,$11,$7F,$18 dc.b $E9,$DD,$CB,$01,$56,$C0,$3E,$DF,$32,$11,$7F,$1A,$DD,$77,$1A,$DD dc.b $CB,$00,$C6,$B7,$20,$06,$DD,$CB,$00,$86,$3E,$FF,$32,$11,$7F,$C9 dc.b $DD,$CB,$01,$7E,$C8,$DD,$77,$08,$C9,$EB,$5E,$23,$56,$1B,$C9,$13 dc.b $C6,$28,$4F,$06,$00,$DD,$E5,$E1,$09,$7E,$B7,$20,$02,$1A,$77,$13 dc.b $35,$C2,$39,$0E,$13,$C9,$4F,$13,$1A,$47,$C5,$DD,$E5,$E1,$DD,$35 dc.b $09,$DD,$4E,$09,$DD,$35,$09,$06,$00,$09,$72,$2B,$73,$D1,$1B,$C9 dc.b $DD,$E5,$E1,$DD,$4E,$09,$06,$00,$09,$5E,$23,$56,$DD,$34,$09,$DD dc.b $34,$09,$C9,$DD,$CB,$07,$BE,$1B,$C9,$DD,$86,$05,$DD,$77,$05,$C9 dc.b $3A,$26,$1C,$FE,$80,$CA,$A1,$0E,$AF,$32,$25,$1C,$32,$26,$1C,$13 dc.b $C9,$3A,$31,$1C,$3D,$32,$31,$1C,$C2,$39,$0E,$AF,$32,$26,$1C,$C3 dc.b $39,$0E,$FE,$01,$20,$05,$DD,$CB,$00,$DE,$C9,$DD,$CB,$00,$9E,$C9 dc.b $DD,$7E,$01,$FE,$02,$20,$2C,$DD,$CB,$00,$C6,$EB,$CD,$73,$02,$06 dc.b $04,$C5,$7E,$23,$E5,$21,$F7,$0E,$87,$4F,$06,$00,$09,$ED,$A0,$ED dc.b $A0,$E1,$C1,$10,$EC,$EB,$1B,$3E,$4F,$32,$12,$1C,$4F,$3E,$27,$CD dc.b $C8,$00,$C9,$13,$13,$13,$C9,$00,$00,$32,$01,$8E,$01,$E4,$01,$34 dc.b $02,$7E,$02,$C2,$02,$F0,$02,$21,$1F,$0C,$DF,$13,$1A,$E9,$32,$24 dc.b $1C,$C9,$DD,$E5,$CD,$F8,$04,$DD,$E1,$C9,$32,$11,$1C,$B7,$28,$1D dc.b $DD,$E5,$D5,$DD,$21,$40,$1C,$06,$09,$11,$30,$00,$DD,$CB,$00,$BE dc.b $CD,$5E,$03,$DD,$19,$10,$F5,$D1,$DD,$E1,$C3,$A1,$09,$DD,$E5,$D5 dc.b $DD,$21,$40,$1C,$06,$09,$11,$30,$00,$DD,$CB,$00,$FE,$DD,$19,$10 dc.b $F8,$D1,$DD,$E1,$C9,$EB,$5E,$23,$56,$23,$4E,$06,$00,$23,$EB,$ED dc.b $B0,$1B,$C9,$06,$09,$21,$42,$1C,$C5,$01,$30,$00,$77,$09,$C1,$10 dc.b $F7,$C9,$DD,$36,$18,$80,$DD,$73,$19,$DD,$72,$1A,$21,$B2,$04,$06 dc.b $04,$1A,$13,$4F,$7E,$23,$CD,$B5,$00,$10,$F6,$1B,$C9,$DD,$77,$18 dc.b $13,$1A,$DD,$77,$19,$C9,$AF,$32,$27,$1C,$1B,$C9,$CD,$37,$03,$20 dc.b $0D,$CD,$74,$02,$DD,$CB,$00,$66,$C0,$CD,$9B,$03,$18,$0C,$DD,$7E dc.b $1E,$B7,$28,$06,$DD,$35,$1E,$CA,$44,$10,$CD,$6C,$04,$CD,$C6,$03 dc.b $DD,$CB,$00,$56,$C0,$DD,$4E,$01,$7D,$E6,$0F,$B1,$32,$11,$7F,$7D dc.b $E6,$F0,$B4,$0F,$0F,$0F,$0F,$32,$11,$7F,$DD,$7E,$08,$B7,$0E,$00 dc.b $28,$09,$3D,$0E,$0A,$CF,$DF,$CD,$12,$10,$4F,$DD,$CB,$00,$66,$C0 dc.b $DD,$7E,$06,$81,$CB,$67,$28,$02,$3E,$0F,$DD,$B6,$01,$C6,$10,$DD dc.b $CB,$00,$46,$20,$04,$32,$11,$7F,$C9,$C6,$20,$32,$11,$7F,$C9,$DD dc.b $77,$17,$E5,$DD,$4E,$17,$06,$00,$09,$7E,$E1,$CB,$7F,$28,$21,$FE dc.b $83,$28,$0C,$FE,$81,$28,$13,$FE,$80,$28,$0C,$03,$0A,$18,$E0,$DD dc.b $CB,$00,$E6,$E1,$C3,$44,$10,$AF,$18,$D5,$E1,$DD,$CB,$00,$E6,$C9 dc.b $DD,$34,$17,$C9,$DD,$CB,$00,$E6,$DD,$CB,$00,$56,$C0,$3E,$1F,$DD dc.b $86,$01,$B7,$F0,$32,$11,$7F,$DD,$CB,$00,$46,$C8,$3E,$FF,$32,$11 dc.b $7F,$C9,$F3,$3E,$2B,$0E,$00,$CD,$C8,$00,$FB,$3A,$3F,$1C,$B7,$C2 dc.b $FE,$10,$3A,$30,$1C,$B7,$28,$F2,$3E,$2B,$0E,$80,$F3,$CD,$C8,$00 dc.b $FB,$FD,$21,$EE,$10,$21,$30,$1C,$7E,$3D,$CB,$FE,$21,$00,$80,$DF dc.b $0E,$80,$7E,$32,$A3,$10,$32,$C0,$10,$23,$5E,$23,$56,$23,$7E,$23 dc.b $66,$6F,$06,$0A,$FB,$10,$FE,$F3,$3E,$2A,$32,$00,$40,$7E,$07,$07 dc.b $07,$07,$E6,$0F,$32,$BA,$10,$79,$FD,$86,$00,$32,$01,$40,$4F,$06 dc.b $0A,$FB,$10,$FE,$F3,$3E,$2A,$32,$00,$40,$7E,$E6,$0F,$32,$D3,$10 dc.b $79,$FD,$86,$00,$32,$01,$40,$FB,$4F,$3A,$30,$1C,$B7,$F2,$6A,$10 dc.b $23,$1B,$7A,$B3,$C2,$A2,$10,$AF,$32,$30,$1C,$C3,$62,$10,$00,$01 dc.b $02,$04,$08,$10,$20,$40,$80,$FF,$FE,$FC,$F8,$F0,$E0,$C0,$F3,$CD dc.b $C7,$09,$3E,$2B,$32,$00,$40,$00,$3E,$80,$32,$01,$40 Z80_0x110D: dc.b $3E,((SegaPCMBank>>$0F)) dc.b $CD zPtrSpec Z80BankSwitch dc.b $00,$00,$00,$00,$00,$00,$00,$00,$00 dc.b $21 z68kPtr SegaPCM dc.b $11,$2F,$5E dc.b $3E,$2A,$32,$00,$40,$00,$7E,$32,$01,$40,$3A,$0A,$1C,$FE,$FE dc.b $28,$0C,$00,$00,$06,$0C,$10,$FE,$23,$1B,$7A,$B3,$20,$E9,$AF,$32 dc.b $3F,$1C,$21,$0D,$1C,$CD,$D3,$09,$C3,$62,$10,$FF Z80_0x114C: dc.b $21,$00,$60 dc.b $77,$0F,$77,$0F,$77,$0F,$77,$0F,$77,$0F,$77,$0F,$77,$0F,$77 dc.b $AF,$77 dc.b $C3,$82,$00 Z80BankSwitch0: Z80_0x1170: dc.b $21,$00,$60 dc.b $77 dc.b $1F dc.b $77 dc.b $1F dc.b $77 dc.b $1F dc.b $77 dc.b $AF dc.b $16,$01 dc.b $72 dc.b $77 dc.b $77 dc.b $77 dc.b $77 dc.b $C9 Z80BankSwitch: dc.b $21, $00, $60 dc.b $77 dc.b $1F dc.b $77 dc.b $1F dc.b $77 dc.b $1F dc.b $77 dc.b $1F dc.b $77 dc.b $1F dc.b $77 dc.b $1F dc.b $77 dc.b $1F dc.b $77 dc.b $1F dc.b $77 dc.b $C9 DriverDataEnd:

-------------------------------------------------------------------------------
Filler to align pointers at 1300h in Z80 Ram

dc.b 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 dc.b 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 dc.b 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 dc.b 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 dc.b 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 dc.b 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 dc.b 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 dc.b 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 dc.b 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 dc.b 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 dc.b 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 dc.b 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 dc.b 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 dc.b 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 dc.b 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 dc.b 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 dc.b 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 dc.b 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 dc.b 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 dc.b 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 dc.b 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 dc.b 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 dc.b 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 dc.b 0,0,0,0,0 DriverPointers: zPtrSpec MusicPointers zPtrSpec UniversalVoiceBank zPtrSpec MusicPointers zPtrSpec SndPointers zPtrSpec PSGNoisePointers zPtrSpec PSGTonePointers dc.w $3300

credit goes to Varion Icaria for finding this index

PSGNoisePointers: zPtrSpec PSGN_0 zPtrSpec PSGN_1 zPtrSpec PSGN_2 zPtrSpec PSGN_3 zPtrSpec PSGN_4 zPtrSpec PSGN_5 zPtrSpec PSGN_6 zPtrSpec PSGN_7

PSGN_1: incbin sound/PSGN1.bin PSGN_0: incbin sound/PSGN0.bin PSGN_2: incbin sound/PSGN2.bin PSGN_3: incbin sound/PSGN3.bin PSGN_4: incbin sound/PSGN4.bin PSGN_5: incbin sound/PSGN5.bin PSGN_6: incbin sound/PSGN6.bin PSGN_7: incbin sound/PSGN7.bin

credit goes to Varion Icaria for finding this index

PSGTonePointers: zPtrSpec PSGT_00 zPtrSpec PSGT_01 zPtrSpec PSGT_02 zPtrSpec PSGT_03 zPtrSpec PSGT_04 zPtrSpec PSGT_05 zPtrSpec PSGT_06 zPtrSpec PSGT_07 zPtrSpec PSGT_08 zPtrSpec PSGT_09 zPtrSpec PSGT_0A zPtrSpec PSGT_0B zPtrSpec PSGT_0C zPtrSpec PSGT_0D zPtrSpec PSGT_0E zPtrSpec PSGT_0F zPtrSpec PSGT_10 zPtrSpec PSGT_11 zPtrSpec PSGT_12 zPtrSpec PSGT_13 zPtrSpec PSGT_14 zPtrSpec PSGT_15 zPtrSpec PSGT_16 zPtrSpec PSGT_17 zPtrSpec PSGT_18 zPtrSpec PSGT_19 zPtrSpec PSGT_1A zPtrSpec PSGT_1B zPtrSpec PSGT_1C zPtrSpec PSGT_1D zPtrSpec PSGT_1E zPtrSpec PSGT_1F zPtrSpec PSGT_20 zPtrSpec PSGT_21 zPtrSpec PSGT_22 zPtrSpec PSGT_23 zPtrSpec PSGT_24 zPtrSpec PSGT_25 zPtrSpec PSGT_26

PSGT_00: incbin sound/PSGT00.bin PSGT_01: incbin sound/PSGT01.bin PSGT_02: incbin sound/PSGT02.bin PSGT_03: incbin sound/PSGT03.bin PSGT_04: incbin sound/PSGT04.bin PSGT_05: incbin sound/PSGT05.bin PSGT_06: incbin sound/PSGT06.bin PSGT_07: incbin sound/PSGT07.bin PSGT_08: incbin sound/PSGT08.bin PSGT_09: incbin sound/PSGT09.bin PSGT_0A: incbin sound/PSGT0A.bin PSGT_0B: incbin sound/PSGT0B.bin PSGT_0C: incbin sound/PSGT0C.bin PSGT_0D: incbin sound/PSGT0D.bin PSGT_0E: incbin sound/PSGT0E.bin PSGT_0F: incbin sound/PSGT0F.bin PSGT_10: incbin sound/PSGT10.bin PSGT_11: incbin sound/PSGT11.bin PSGT_12: incbin sound/PSGT12.bin PSGT_13: incbin sound/PSGT13.bin PSGT_14: incbin sound/PSGT14.bin PSGT_15: incbin sound/PSGT15.bin PSGT_16: incbin sound/PSGT16.bin PSGT_17: incbin sound/PSGT17.bin PSGT_18: incbin sound/PSGT18.bin PSGT_19: incbin sound/PSGT19.bin PSGT_1A: incbin sound/PSGT1A.bin PSGT_1B: incbin sound/PSGT1B.bin PSGT_1C: incbin sound/PSGT1C.bin PSGT_1D: incbin sound/PSGT1D.bin PSGT_1E: incbin sound/PSGT1E.bin PSGT_1F: incbin sound/PSGT1F.bin PSGT_20: incbin sound/PSGT20.bin PSGT_21: incbin sound/PSGT21.bin PSGT_22: incbin sound/PSGT22.bin PSGT_23: incbin sound/PSGT23.bin PSGT_24: incbin sound/PSGT24.bin PSGT_25: incbin sound/PSGT25.bin PSGT_26: incbin sound/PSGT26.bin

MusicPointers: z68kPtr Angel_Island_1_Snd z68kPtr Angel_Island_2_Snd z68kPtr Hydrocity_1_Snd z68kPtr Hydrocity_2_Snd z68kPtr Marble_Garden_1_Snd z68kPtr Marble_Garden_2_Snd z68kPtr Carnival_Night_1_Snd z68kPtr Carnival_Night_2_Snd z68kPtr Flying_Battery_1_Snd z68kPtr Flying_Battery_2_Snd z68kPtr Icecap_1_Snd z68kPtr Icecap_2_Snd z68kPtr Launch_Base_1_Snd z68kPtr Launch_Base_2_Snd z68kPtr Mushroom_Hill_1_Snd z68kPtr Mushroom_Hill_2_Snd z68kPtr Sandopolis_1_Snd z68kPtr Sandopolis_2_Snd z68kPtr Lava_Reef_1_Snd z68kPtr Lava_Reef_2_Snd z68kPtr Sky_Sanctuary_Snd z68kPtr Death_Egg_1_Snd z68kPtr Death_Egg_2_Snd z68kPtr Mini_Boss_SK_Snd z68kPtr Boss_Snd z68kPtr The_Doomsday_Snd z68kPtr Glowing_Spheres_Bonus_Stage_snd z68kPtr Special_Stage_Snd z68kPtr Slot_Machine_Bonus_Stage_snd z68kPtr Gum_Ball_Machine_Bonus_Stage_snd z68kPtr Knuckles_Theme_Snd z68kPtr Azure_Lake_Snd z68kPtr Balloon_Park_Snd z68kPtr Desert_Palace_Snd z68kPtr Chrome_Gadget_Snd z68kPtr Endless_Mine_Snd z68kPtr Title_Screen_Snd z68kPtr Credits_Snd z68kPtr Time_Game_Over_Snd z68kPtr Continue_Sound z68kPtr Level_Results_Snd z68kPtr Extra_Life_Snd z68kPtr Emerald_Snd z68kPtr Invincibility_Snd z68kPtr Competition_Menu_Snd z68kPtr Mini_Boss_Snd z68kPtr Menu_Snd z68kPtr Final_Boss_Snd z68kPtr Underwater_Timming_Snd z68kPtr Presented_by_SEGA_Snd

SndPointers: z68kPtr Sfx_34_Snd z68kPtr Sfx_35_Snd z68kPtr Sfx_36_Snd z68kPtr Sfx_37_Snd z68kPtr Sfx_38_Snd z68kPtr Sfx_39_Snd z68kPtr Sfx_3A_Snd z68kPtr Sfx_3B_Snd z68kPtr Sfx_3C_Snd z68kPtr Sfx_3D_Snd z68kPtr Sfx_3E_Snd z68kPtr Sfx_3F_Snd z68kPtr Sfx_40_Snd z68kPtr Sfx_41_Snd z68kPtr Sfx_42_Snd z68kPtr Sfx_43_Snd z68kPtr Sfx_44_Snd z68kPtr Sfx_45_Snd z68kPtr Sfx_46_Snd z68kPtr Sfx_47_Snd z68kPtr Sfx_48_Snd z68kPtr Sfx_49_Snd z68kPtr Sfx_4A_Snd z68kPtr Sfx_4B_Snd z68kPtr Sfx_4C_Snd z68kPtr Sfx_4D_Snd z68kPtr Sfx_4E_Snd z68kPtr Sfx_4F_Snd z68kPtr Sfx_50_Snd z68kPtr Sfx_51_Snd z68kPtr Sfx_52_Snd z68kPtr Sfx_53_Snd z68kPtr Sfx_54_Snd z68kPtr Sfx_55_Snd z68kPtr Sfx_56_Snd z68kPtr Sfx_57_Snd z68kPtr Sfx_58_Snd z68kPtr Sfx_59_Snd z68kPtr Sfx_5A_Snd z68kPtr Sfx_5B_Snd z68kPtr Sfx_5C_Snd z68kPtr Sfx_5D_Snd z68kPtr Sfx_5E_Snd z68kPtr Sfx_5F_Snd z68kPtr Sfx_60_Snd z68kPtr Sfx_61_Snd z68kPtr Sfx_62_Snd z68kPtr Sfx_63_Snd z68kPtr Sfx_64_Snd z68kPtr Sfx_65_Snd z68kPtr Sfx_66_Snd z68kPtr Sfx_67_Snd z68kPtr Sfx_68_Snd z68kPtr Sfx_69_Snd z68kPtr Sfx_6A_Snd z68kPtr Sfx_6B_Snd z68kPtr Sfx_6C_Snd z68kPtr Sfx_6D_Snd z68kPtr Sfx_6E_Snd z68kPtr Sfx_6F_Snd z68kPtr Sfx_70_Snd z68kPtr Sfx_71_Snd z68kPtr Sfx_72_Snd z68kPtr Sfx_73_Snd z68kPtr Sfx_74_Snd z68kPtr Sfx_75_Snd z68kPtr Sfx_76_Snd z68kPtr Sfx_77_Snd z68kPtr Sfx_78_Snd z68kPtr Sfx_79_Snd z68kPtr Sfx_7A_Snd z68kPtr Sfx_7B_Snd z68kPtr Sfx_7C_Snd z68kPtr Sfx_7D_Snd z68kPtr Sfx_7E_Snd z68kPtr Sfx_7F_Snd z68kPtr Sfx_80_Snd z68kPtr Sfx_81_Snd z68kPtr Sfx_82_Snd z68kPtr Sfx_83_Snd z68kPtr Sfx_84_Snd z68kPtr Sfx_85_Snd z68kPtr Sfx_86_Snd z68kPtr Sfx_87_Snd z68kPtr Sfx_88_Snd z68kPtr Sfx_89_Snd z68kPtr Sfx_8A_Snd z68kPtr Sfx_8B_Snd z68kPtr Sfx_8C_Snd z68kPtr Sfx_8D_Snd z68kPtr Sfx_8E_Snd z68kPtr Sfx_8F_Snd z68kPtr Sfx_90_Snd z68kPtr Sfx_91_Snd z68kPtr Sfx_92_Snd z68kPtr Sfx_93_Snd z68kPtr Sfx_94_Snd z68kPtr Sfx_95_Snd z68kPtr Sfx_96_Snd z68kPtr Sfx_97_Snd z68kPtr Sfx_98_Snd z68kPtr Sfx_99_Snd z68kPtr Sfx_9A_Snd z68kPtr Sfx_9B_Snd z68kPtr Sfx_9C_Snd z68kPtr Sfx_9D_Snd z68kPtr Sfx_9E_Snd z68kPtr Sfx_9F_Snd z68kPtr Sfx_A0_Snd z68kPtr Sfx_A1_Snd z68kPtr Sfx_A2_Snd z68kPtr Sfx_A3_Snd z68kPtr Sfx_A4_Snd z68kPtr Sfx_A5_Snd z68kPtr Sfx_A6_Snd z68kPtr Sfx_A7_Snd z68kPtr Sfx_A8_Snd z68kPtr Sfx_A9_Snd z68kPtr Sfx_AA_Snd z68kPtr Sfx_AB_Snd z68kPtr Sfx_AC_Snd z68kPtr Sfx_AD_Snd z68kPtr Sfx_AE_Snd z68kPtr Sfx_AF_Snd z68kPtr Sfx_B0_Snd z68kPtr Sfx_B1_Snd z68kPtr Sfx_B2_Snd z68kPtr Sfx_B3_Snd z68kPtr Sfx_B4_Snd z68kPtr Sfx_B5_Snd z68kPtr Sfx_B6_Snd z68kPtr Sfx_B7_Snd z68kPtr Sfx_B8_Snd z68kPtr Sfx_B9_Snd z68kPtr Sfx_BA_Snd z68kPtr Sfx_BB_Snd z68kPtr Sfx_BC_Snd z68kPtr Sfx_BD_Snd z68kPtr Sfx_BE_Snd z68kPtr Sfx_BF_Snd z68kPtr Sfx_C0_Snd z68kPtr Sfx_C1_Snd z68kPtr Sfx_C2_Snd z68kPtr Sfx_C3_Snd z68kPtr Sfx_C4_Snd z68kPtr Sfx_C5_Snd z68kPtr Sfx_C6_Snd z68kPtr Sfx_C7_Snd z68kPtr Sfx_C8_Snd z68kPtr Sfx_C9_Snd z68kPtr Sfx_CA_Snd z68kPtr Sfx_CB_Snd z68kPtr Sfx_CC_Snd z68kPtr Sfx_CD_Snd z68kPtr Sfx_CE_Snd z68kPtr Sfx_CF_Snd z68kPtr Sfx_D0_Snd z68kPtr Sfx_D1_Snd z68kPtr Sfx_D2_Snd z68kPtr Sfx_D3_Snd z68kPtr Sfx_D4_Snd z68kPtr Sfx_D5_Snd z68kPtr Sfx_D6_Snd z68kPtr Sfx_D7_Snd z68kPtr Sfx_D8_Snd z68kPtr Sfx_D9_Snd z68kPtr Sfx_DA_Snd z68kPtr Sfx_DB_Snd z68kPtr Sfx_DC_Snd z68kPtr Sfx_DC_Snd z68kPtr Sfx_DC_Snd z68kPtr Sfx_DC_Snd z68kPtr Sfx_DC_Snd DriverPointersEnd:

UniversalVoiceBank: incbin "sound/uvb.bin" UniversalVoiceBankEnd: align $8000

DacBank0: incbin "sound/dac_0.bin"

align $8000 DacBank1: incbin "sound/dac_1.bin" align $8000

DacBank2: incbin "sound/dac_2.bin" align $8000

Bank0: incbin "sound/filler.bin" Mini_Boss_Snd: incbin "sound/miniboss.snd" Final_Boss_Snd: incbin "sound/f_boss.snd" align $8000

Bank1: Angel_Island_1_Snd: incbin "sound/aiz1.snd" Angel_Island_2_Snd: incbin "sound/aiz2.snd" Hydrocity_1_Snd: incbin "sound/hcz1.snd" Hydrocity_2_Snd: incbin "sound/hcz2.snd" Marble_Garden_1_Snd: incbin "sound/mgz1.snd" Marble_Garden_2_Snd: incbin "sound/mgz2.snd" Carnival_Night_2_Snd: incbin "sound/cnz2.snd" Carnival_Night_1_Snd: incbin "sound/cnz1.snd" Flying_Battery_1_Snd: incbin "sound/fbz1.snd" Flying_Battery_2_Snd: incbin "sound/fbz2.snd" The_Doomsday_Snd: incbin "sound/tdz.snd" align $8000

Bank2: Icecap_2_Snd: incbin "sound/iz2.snd" Icecap_1_Snd: incbin "sound/iz1.snd" Launch_Base_2_Snd: incbin "sound/lbz2.snd" Launch_Base_1_Snd: incbin "sound/lbz1.snd" Mushroom_Hill_1_Snd: incbin "sound/mhz1.snd" Mushroom_Hill_2_Snd: incbin "sound/mhz2.snd" Sandopolis_1_Snd: incbin "sound/sz1.snd" Sandopolis_2_Snd: incbin "sound/sz2.snd" Lava_Reef_1_Snd: incbin "sound/lrz1.snd" Lava_Reef_2_Snd: incbin "sound/lrz2.snd" Sky_Sanctuary_Snd: incbin "sound/scz.snd" Death_Egg_1_Snd: incbin "sound/dez1.snd" Death_Egg_2_Snd: incbin "sound/dez2.snd" Mini_Boss_SK_Snd: incbin "sound/mb_sk.snd" Boss_Snd: incbin "sound/boss.snd" Glowing_Spheres_Bonus_Stage_snd: incbin "sound/gs_bs.snd" Special_Stage_Snd: incbin "sound/ss.snd" Level_Results_Snd: incbin "sound/lr.snd" Menu_Snd: incbin "sound/menu.snd" align $8000

Bank3: Slot_Machine_Bonus_Stage_snd: incbin "sound/sm_bs.snd" Gum_Ball_Machine_Bonus_Stage_snd: incbin "sound/gbm_bs.snd" Knuckles_Theme_Snd: incbin "sound/kte.snd" Azure_Lake_Snd: incbin "sound/alz.snd" Balloon_Park_Snd: incbin "sound/bpz.snd" Desert_Palace_Snd: incbin "sound/dpz.snd" Chrome_Gadget_Snd: incbin "sound/cgz.snd" Endless_Mine_Snd: incbin "sound/emz.snd" Title_Screen_Snd: incbin "sound/ts.snd" Credits_Snd: incbin "sound/credits.snd" Time_Game_Over_Snd: incbin "sound/tgovr.snd" Continue_Snd: incbin "sound/continue.snd" Extra_Life_Snd: incbin "sound/1up.snd" Emerald_Snd: incbin "sound/emerald.snd" Invincibility_Snd: incbin "sound/invcblty.snd" Competition_Menu_Snd: incbin "sound/2p_menu.snd" Underwater_Timming_Snd: incbin "sound/panic.snd" Presented_by_SEGA_Snd: incbin "sound/p_sega.snd" align $8000

SndBank: SegaPCMBank: SegaSnd: incbin "sound/sega.snd" Sfx_34_Snd: incbin "sound/sfx_34.snd" Sfx_35_Snd: incbin "sound/sfx_35.snd" Sfx_36_Snd: incbin "sound/sfx_36.snd" Sfx_37_Snd: incbin "sound/sfx_37.snd" Sfx_38_Snd: incbin "sound/sfx_38.snd" Sfx_39_Snd: incbin "sound/sfx_39.snd" Sfx_3A_Snd: incbin "sound/sfx_3A.snd" Sfx_3B_Snd: incbin "sound/sfx_3B.snd" Sfx_3C_Snd: incbin "sound/sfx_3C.snd" Sfx_3D_Snd: incbin "sound/sfx_3D.snd" Sfx_3E_Snd: incbin "sound/sfx_3E.snd" Sfx_3F_Snd: incbin "sound/sfx_3F.snd" Sfx_40_Snd: incbin "sound/sfx_40.snd" Sfx_41_Snd: incbin "sound/sfx_41.snd" Sfx_42_Snd: incbin "sound/sfx_42.snd" Sfx_43_Snd: incbin "sound/sfx_43.snd" Sfx_44_Snd: incbin "sound/sfx_44.snd" Sfx_45_Snd: incbin "sound/sfx_45.snd" Sfx_46_Snd: incbin "sound/sfx_46.snd" Sfx_47_Snd: incbin "sound/sfx_47.snd" Sfx_48_Snd: incbin "sound/sfx_48.snd" Sfx_49_Snd: incbin "sound/sfx_49.snd" Sfx_4A_Snd: incbin "sound/sfx_4A.snd" Sfx_4B_Snd: incbin "sound/sfx_4B.snd" Sfx_4C_Snd: incbin "sound/sfx_4C.snd" Sfx_4D_Snd: incbin "sound/sfx_4D.snd" Sfx_4E_Snd: incbin "sound/sfx_4E.snd" Sfx_4F_Snd: incbin "sound/sfx_4F.snd" Sfx_50_Snd: incbin "sound/sfx_50.snd" Sfx_51_Snd: incbin "sound/sfx_51.snd" Sfx_52_Snd: incbin "sound/sfx_52.snd" Sfx_53_Snd: incbin "sound/sfx_53.snd" Sfx_54_Snd: incbin "sound/sfx_54.snd" Sfx_55_Snd: incbin "sound/sfx_55.snd" Sfx_56_Snd: incbin "sound/sfx_56.snd" Sfx_57_Snd: incbin "sound/sfx_57.snd" Sfx_58_Snd: incbin "sound/sfx_58.snd" Sfx_59_Snd: incbin "sound/sfx_59.snd" Sfx_5A_Snd: incbin "sound/sfx_5A.snd" Sfx_5B_Snd: incbin "sound/sfx_5B.snd" Sfx_5C_Snd: incbin "sound/sfx_5C.snd" Sfx_5D_Snd: incbin "sound/sfx_5D.snd" Sfx_5E_Snd: incbin "sound/sfx_5E.snd" Sfx_5F_Snd: incbin "sound/sfx_5F.snd" Sfx_60_Snd: incbin "sound/sfx_60.snd" Sfx_61_Snd: incbin "sound/sfx_61.snd" Sfx_62_Snd: incbin "sound/sfx_62.snd" Sfx_63_Snd: incbin "sound/sfx_63.snd" Sfx_64_Snd: incbin "sound/sfx_64.snd" Sfx_65_Snd: incbin "sound/sfx_65.snd" Sfx_66_Snd: incbin "sound/sfx_66.snd" Sfx_67_Snd: incbin "sound/sfx_67.snd" Sfx_68_Snd: incbin "sound/sfx_68.snd" Sfx_69_Snd: incbin "sound/sfx_69.snd" Sfx_6A_Snd: incbin "sound/sfx_6A.snd" Sfx_6B_Snd: incbin "sound/sfx_6B.snd" Sfx_6C_Snd: incbin "sound/sfx_6C.snd" Sfx_6D_Snd: incbin "sound/sfx_6D.snd" Sfx_6E_Snd: incbin "sound/sfx_6E.snd" Sfx_6F_Snd: incbin "sound/sfx_6F.snd" Sfx_70_Snd: incbin "sound/sfx_70.snd" Sfx_71_Snd: incbin "sound/sfx_71.snd" Sfx_72_Snd: incbin "sound/sfx_72.snd" Sfx_73_Snd: incbin "sound/sfx_73.snd" Sfx_74_Snd: incbin "sound/sfx_74.snd" Sfx_75_Snd: incbin "sound/sfx_75.snd" Sfx_76_Snd: incbin "sound/sfx_76.snd" Sfx_77_Snd: incbin "sound/sfx_77.snd" Sfx_78_Snd: incbin "sound/sfx_78.snd" Sfx_79_Snd: incbin "sound/sfx_79.snd" Sfx_7A_Snd: incbin "sound/sfx_7A.snd" Sfx_7B_Snd: incbin "sound/sfx_7B.snd" Sfx_7C_Snd: incbin "sound/sfx_7C.snd" Sfx_7D_Snd: incbin "sound/sfx_7D.snd" Sfx_7E_Snd: incbin "sound/sfx_7E.snd" Sfx_7F_Snd: incbin "sound/sfx_7F.snd" Sfx_80_Snd: incbin "sound/sfx_80.snd" Sfx_81_Snd: incbin "sound/sfx_81.snd" Sfx_82_Snd: incbin "sound/sfx_82.snd" Sfx_83_Snd: incbin "sound/sfx_83.snd" Sfx_84_Snd: incbin "sound/sfx_84.snd" Sfx_85_Snd: incbin "sound/sfx_85.snd" Sfx_86_Snd: incbin "sound/sfx_86.snd" Sfx_87_Snd: incbin "sound/sfx_87.snd" Sfx_88_Snd: incbin "sound/sfx_88.snd" Sfx_89_Snd: incbin "sound/sfx_89.snd" Sfx_8A_Snd: incbin "sound/sfx_8A.snd" Sfx_8B_Snd: incbin "sound/sfx_8B.snd" Sfx_8C_Snd: incbin "sound/sfx_8C.snd" Sfx_8D_Snd: incbin "sound/sfx_8D.snd" Sfx_8E_Snd: incbin "sound/sfx_8E.snd" Sfx_8F_Snd: incbin "sound/sfx_8F.snd" Sfx_90_Snd: incbin "sound/sfx_90.snd" Sfx_91_Snd: incbin "sound/sfx_91.snd" Sfx_92_Snd: incbin "sound/sfx_92.snd" Sfx_93_Snd: incbin "sound/sfx_93.snd" Sfx_94_Snd: incbin "sound/sfx_94.snd" Sfx_95_Snd: incbin "sound/sfx_95.snd" Sfx_96_Snd: incbin "sound/sfx_96.snd" Sfx_97_Snd: incbin "sound/sfx_97.snd" Sfx_98_Snd: incbin "sound/sfx_98.snd" Sfx_99_Snd: incbin "sound/sfx_99.snd" Sfx_9A_Snd: incbin "sound/sfx_9A.snd" Sfx_9B_Snd: incbin "sound/sfx_9B.snd" Sfx_9C_Snd: incbin "sound/sfx_9C.snd" Sfx_9D_Snd: incbin "sound/sfx_9D.snd" Sfx_9E_Snd: incbin "sound/sfx_9E.snd" Sfx_9F_Snd: incbin "sound/sfx_9F.snd" Sfx_A0_Snd: incbin "sound/sfx_A0.snd" Sfx_A1_Snd: incbin "sound/sfx_A1.snd" Sfx_A2_Snd: incbin "sound/sfx_A2.snd" Sfx_A3_Snd: incbin "sound/sfx_A3.snd" Sfx_A4_Snd: incbin "sound/sfx_A4.snd" Sfx_A5_Snd: incbin "sound/sfx_A5.snd" Sfx_A6_Snd: incbin "sound/sfx_A6.snd" Sfx_A7_Snd: incbin "sound/sfx_A7.snd" Sfx_A8_Snd: incbin "sound/sfx_A8.snd" Sfx_A9_Snd: incbin "sound/sfx_A9.snd" Sfx_AA_Snd: incbin "sound/sfx_AA.snd" Sfx_AB_Snd: incbin "sound/sfx_AB.snd" Sfx_AC_Snd: incbin "sound/sfx_AC.snd" Sfx_AD_Snd: incbin "sound/sfx_AD.snd" Sfx_AE_Snd: incbin "sound/sfx_AE.snd" Sfx_AF_Snd: incbin "sound/sfx_AF.snd" Sfx_B0_Snd: incbin "sound/sfx_B0.snd" Sfx_B1_Snd: incbin "sound/sfx_B1.snd" Sfx_B2_Snd: incbin "sound/sfx_B2.snd" Sfx_B3_Snd: incbin "sound/sfx_B3.snd" Sfx_B4_Snd: incbin "sound/sfx_B4.snd" Sfx_B5_Snd: incbin "sound/sfx_B5.snd" Sfx_B6_Snd: incbin "sound/sfx_B6.snd" Sfx_B7_Snd: incbin "sound/sfx_B7.snd" Sfx_B8_Snd: incbin "sound/sfx_B8.snd" Sfx_B9_Snd: incbin "sound/sfx_B9.snd" Sfx_BA_Snd: incbin "sound/sfx_BA.snd" Sfx_BB_Snd: incbin "sound/sfx_BB.snd" Sfx_BC_Snd: incbin "sound/sfx_BC.snd" Sfx_BD_Snd: incbin "sound/sfx_BD.snd" Sfx_BE_Snd: incbin "sound/sfx_BE.snd" Sfx_BF_Snd: incbin "sound/sfx_BF.snd" Sfx_C0_Snd: incbin "sound/sfx_C0.snd" Sfx_C1_Snd: incbin "sound/sfx_C1.snd" Sfx_C2_Snd: incbin "sound/sfx_C2.snd" Sfx_C3_Snd: incbin "sound/sfx_C3.snd" Sfx_C4_Snd: incbin "sound/sfx_C4.snd" Sfx_C5_Snd: incbin "sound/sfx_C5.snd" Sfx_C6_Snd: incbin "sound/sfx_C6.snd" Sfx_C7_Snd: incbin "sound/sfx_C7.snd" Sfx_C8_Snd: incbin "sound/sfx_C8.snd" Sfx_C9_Snd: incbin "sound/sfx_C9.snd" Sfx_CA_Snd: incbin "sound/sfx_CA.snd" Sfx_CB_Snd: incbin "sound/sfx_CB.snd" Sfx_CC_Snd: incbin "sound/sfx_CC.snd" Sfx_CD_Snd: incbin "sound/sfx_CD.snd" Sfx_CE_Snd: incbin "sound/sfx_CE.snd" Sfx_CF_Snd: incbin "sound/sfx_CF.snd" Sfx_D0_Snd: incbin "sound/sfx_D0.snd" Sfx_D1_Snd: incbin "sound/sfx_D1.snd" Sfx_D2_Snd: incbin "sound/sfx_D2.snd" Sfx_D3_Snd: incbin "sound/sfx_D3.snd" Sfx_D4_Snd: incbin "sound/sfx_D4.snd" Sfx_D5_Snd: incbin "sound/sfx_D5.snd" Sfx_D6_Snd: incbin "sound/sfx_D6.snd" Sfx_D7_Snd: incbin "sound/sfx_D7.snd" Sfx_D8_Snd: incbin "sound/sfx_D8.snd" Sfx_D9_Snd: incbin "sound/sfx_D9.snd" Sfx_DA_Snd: incbin "sound/sfx_DA.snd" Sfx_DB_Snd: incbin "sound/sfx_DB.snd" Sfx_DC_Snd: incbin "sound/sfx_DC.snd" </asm>

Driver data files

Then unpack this into the sound folder, and remove the original files since we no longer need them anymore:

Download.svg Download The Sonic 3 Driver data files
File: s3driverdata.7z (131 kB) (info)

Enabling Sonic 2 / 3 Level Music Memory

Doing this is optional as it has little to do with the driver itself, but is a very useful and quick hack that makes life a lot easier for the more painful phase of using a massively different sound system than before, fixing the freaken sound. Sonic 1 uses a second index for restoring music as opposed to actually memorizing it like later sonic games do.

First we will locate: <asm> Level_PlayBgm: lea (MusicList).l,a1 ; load music playlist move.b (a1,d0.w),d0 ; add d0 to a1 bsr.w PlaySound ; play music move.b #$34,($FFFFD080).w ; load title card object </asm>

and insert a new line to make it read: <asm> Level_PlayBgm: lea (MusicList).l,a1 ; load music playlist move.b (a1,d0.w),d0 ; add d0 to a1 move.w d0,($FFFFFF90).w ; store level music bsr.w PlaySound ; play music move.b #$34,($FFFFD080).w ; load title card object </asm>

Now we will locate: <asm> move.b ($FFFFFE10).w,d0 cmpi.w #$103,($FFFFFE10).w ; check if level is SBZ3 bne.s Obj01_PlayMusic moveq #5,d0 ; play SBZ music

Obj01_PlayMusic: lea (MusicList2).l,a1 move.b (a1,d0.w),d0 jsr (PlaySound).l ; play normal music </asm>

seems the invincibility stars conflict with music memory, so we will just make it use music list 1, so the result is: <asm> move.b ($FFFFFE10).w,d0 cmpi.w #$103,($FFFFFE10).w ; check if level is SBZ3 bne.s Obj01_PlayMusic moveq #5,d0 ; play SBZ music

Obj01_PlayMusic: lea (MusicList).l,a1 ; load music playlist move.b (a1,d0.w),d0 ; add d0 to a1 move.w d0,($FFFFFF90).w ; store level music jsr (PlaySound).l ; play normal music </asm>

then remove: <asm>

---------------------------------------------------------------------------
Music to play after invincibility wears off
---------------------------------------------------------------------------

MusicList2: binclude misc\muslist2.bin </asm> now we want to fix the underwater counter music restore code, so locate: <asm> ResumeMusic: ; XREF: Obj64_Wobble; Sonic_Water; Obj0A_ReduceAir cmpi.w #$C,($FFFFFE14).w bhi.s loc_140AC move.w #$82,d0 ; play LZ music cmpi.w #$103,($FFFFFE10).w ; check if level is 0103 (SBZ3) bne.s loc_140A6 move.w #$86,d0 ; play SBZ music

loc_140A6: jsr (PlaySound).l </asm> and replace it with: <asm> ResumeMusic: ; XREF: Obj64_Wobble; Sonic_Water; Obj0A_ReduceAir cmpi.w #$C,($FFFFFE14).w bhi.s loc_140AC move.w ($FFFFFF90).w,d0  ;resume music jsr (PlaySound).l </asm> that sets up music memory for later.

Fixing the Music Playlist

Okay, so we now have working Sound/Music, but we have yet to fix the music playlist it is still pointing to sound effects.

Open misc\muslist1.bin in your favorite hex editor.

You will find that it reads:

Hex Data
81 82 83 84 85 86 8D 00

Pick some new music for your game.


I prefer to use:

Hex Data
01 04 13 0D 07 16 30 00

Once you rebuild your rom, you will have some music on the levels, but sound effects and some other musics unrelated to the playlist will need fixing. This part is much easier fixing if you applied the Sonic 2 memory fix to your hack, otherwise edit misc/muslist2.bin and make the exact same changes.

Fixing the Sneaker

We need to fix the sneaker in a different way than we normally do, because sonic3 uses a different means for speeding up or slowing down the music then its predecessors do. first we will locate: <asm> Obj2E_ChkShoes: cmpi.b #3,d0 ; does monitor contain speed shoes? bne.s Obj2E_ChkShield move.b #1,($FFFFFE2E).w ; speed up the BG music move.w #$4B0,($FFFFD034).w ; time limit for the power-up move.w #$C00,($FFFFF760).w ; change Sonic"s top speed move.w #$18,($FFFFF762).w move.w #$80,($FFFFF764).w move.w #$E2,d0 jmp (PlaySound).l ; Speed up the music </asm> note that sonic1 plays a special sound to make the music speed up, our new driver does not do that, so we will change it to read: <asm> Obj2E_ChkShoes: cmpi.b #3,d0 ; does monitor contain speed shoes? bne.s Obj2E_ChkShield move.b #1,($FFFFFE2E).w ; speed up the BG music move.w #$4B0,($FFFFD034).w ; time limit for the power-up move.w #$C00,($FFFFF760).w ; change Sonic"s top speed move.w #$18,($FFFFF762).w move.w #$80,($FFFFF764).w move.w #8,d0 jmp (SetTempo).l ; Speed up the music </asm> that speeds the music up properly, but we need to tell it how to slow the music back down. So we find: <asm> Obj01_ChkShoes: tst.b ($FFFFFE2E).w ; does Sonic have speed shoes? beq.s Obj01_ExitChk ; if not, branch tst.w $34(a0) ; check time remaining beq.s Obj01_ExitChk subq.w #1,$34(a0) ; subtract 1 from time bne.s Obj01_ExitChk move.w #$600,($FFFFF760).w ; restore Sonic"s speed move.w #$C,($FFFFF762).w ; restore Sonic"s acceleration move.w #$80,($FFFFF764).w ; restore Sonic"s deceleration move.b #0,($FFFFFE2E).w ; cancel speed shoes move.w #$E3,d0 jmp (PlaySound).l ; run music at normal speed </asm> note that sonic1 also uses another sound to return the music to normal speed, sonic3 doesn't, so we will correct the sneaker wearing off effect, by changin it to: <asm> Obj01_ChkShoes: tst.b ($FFFFFE2E).w ; does Sonic have speed shoes? beq.s Obj01_ExitChk ; if not, branch tst.w $34(a0) ; check time remaining beq.s Obj01_ExitChk subq.w #1,$34(a0) ; subtract 1 from time bne.s Obj01_ExitChk move.w #$600,($FFFFF760).w ; restore Sonic"s speed move.w #$C,($FFFFF762).w ; restore Sonic"s acceleration move.w #$80,($FFFFF764).w ; restore Sonic"s deceleration move.b #0,($FFFFFE2E).w ; cancel speed shoes move.w #$0,d0 jmp (SetTempo).l ; run music at normal speed </asm>

Fixing the screen transition sound effects

Sega Screen Part 1

Don't we want music to fade out properly when changing screens? Well if that is true, then you are reading in the right place, first off, go and find: <asm> SegaScreen: ; XREF: GameModeArray move.b #$E4,d0 bsr.w PlaySound_Special ; stop music </asm>

we want it to change to: <asm> SegaScreen: ; XREF: GameModeArray move.b #$E1,d0 bsr.w PlaySound_Special ; Sonic 3 prefers to fade out rather than stop the music. </asm>

Title Screen playback fix

Good, the sega logo screen does with music what we want it to! now to fix the Title Screen, locate: <asm> TitleScreen: ; XREF: GameModeArray move.b #$E4,d0 bsr.w PlaySound_Special ; stop music </asm> and change it to: <asm> TitleScreen: ; XREF: GameModeArray move.b #$E1,d0 bsr.w PlaySound_Special ; Sonic 3 prefers to fade out rather than stop the music. </asm>

Ending Sequence music fix

Good, the title screen transition effect should be fixed now, but we still have a ways to go, so now lets fix the ending sequence transitioning, locate: <asm> EndingSequence: ; XREF: GameModeArray move.b #$E4,d0 bsr.w PlaySound_Special ; stop music </asm> and change it to: <asm> EndingSequence: ; XREF: GameModeArray move.b #$E1,d0 bsr.w PlaySound_Special ; Sonic 3 prefers to fade out rather than stop the music. </asm>

Fix the level select sound

Now that the screens fade music as they should, shouldn't we fix the rest of the fades throughout the game? I would think so, so lets do just that, locate: <asm> move.b #$E0,d0 bsr.w PlaySound_Special ; fade out music rts

===========================================================================
---------------------------------------------------------------------------
Level select - level pointers
---------------------------------------------------------------------------

</asm> and change it to: <asm> move.b #$E1,d0 bsr.w PlaySound_Special ; fade out music rts

===========================================================================
---------------------------------------------------------------------------
Level select - level pointers
---------------------------------------------------------------------------

</asm>

Music fade out on demo exit ala Sonic 3

That fixes a spot in the level select, which we will work on later. For now locate: <asm> loc_33E4: ; XREF: Demo andi.b #$80,($FFFFF605).w ; is Start button pressed? bne.w Title_ChkLevSel ; if yes, branch tst.w ($FFFFF614).w bne.w loc_33B6 move.b #$E0,d0 bsr.w PlaySound_Special ; fade out music </asm> and change it to: <asm> loc_33E4: ; XREF: Demo andi.b #$80,($FFFFF605).w ; is Start button pressed? bne.w Title_ChkLevSel ; if yes, branch tst.w ($FFFFF614).w bne.w loc_33B6 move.b #$E1,d0 bsr.w PlaySound_Special ; fade out music </asm>

Fade out music in prep of level

now find: <asm> Level: ; XREF: GameModeArray bset #7,($FFFFF600).w ; add $80 to screen mode (for pre level sequence) tst.w ($FFFFFFF0).w bmi.s loc_37B6 move.b #$E0,d0 bsr.w PlaySound_Special ; fade out music </asm> and change it to: <asm> Level: ; XREF: GameModeArray bset #7,($FFFFF600).w ; add $80 to screen mode (for pre level sequence) tst.w ($FFFFFFF0).w bmi.s loc_37B6 move.b #$E1,d0 bsr.w PlaySound_Special ; fade out music </asm>

Continue screen fade out

now find: <asm> Obj81_GetUp: ; XREF: Obj81_Animate addq.b #2,$24(a0) move.l #Map_Sonic,4(a0) move.w #$780,2(a0) move.b #$1E,$1C(a0) ; use "getting up" animation clr.w $14(a0) subq.w #8,$C(a0) move.b #$E0,d0 bsr.w PlaySound_Special ; fade out music </asm> and change it to: <asm> Obj81_GetUp: ; XREF: Obj81_Animate addq.b #2,$24(a0) move.l #Map_Sonic,4(a0) move.w #$780,2(a0) move.b #$1E,$1C(a0) ; use "getting up" animation clr.w $14(a0) subq.w #8,$C(a0) move.b #$E1,d0 bsr.w PlaySound_Special ; fade out music </asm> Okay, that should fix all the music fades between screens, but still there are yet more fixes to be made.

Fixing the SEGA sound

Want to hear the SEGA PCM when you should? Well this section is for you then. Go find: <asm> Sega_WaitPallet: move.b #2,($FFFFF62A).w bsr.w DelayProgram bsr.w PalCycle_Sega bne.s Sega_WaitPallet

move.b #$E1,d0 bsr.w PlaySound_Special ; play "SEGA" sound move.b #$14,($FFFFF62A).w bsr.w DelayProgram move.w #$1E,($FFFFF614).w </asm> and change it to: <asm> Sega_WaitPallet: move.b #2,($FFFFF62A).w bsr.w DelayProgram bsr.w PalCycle_Sega bne.s Sega_WaitPallet

move.b #$FF,d0 bsr.w PlaySound_Special ; play "SEGA" sound move.b #$14,($FFFFF62A).w bsr.w DelayProgram move.w #$1E,($FFFFF614).w </asm> That should fix the sega pcm sample on the sega logo screen.

Fixing the Title Screen music

Want to get rid of that weird sound effect on the title screen? Then we need to fix the music. Find: <asm> move.b #$8A,d0 ; play title screen music bsr.w PlaySound_Special move.b #0,($FFFFFFFA).w ; disable debug mode move.w #$178,($FFFFF614).w ; run title screen for $178 frames lea ($FFFFD080).w,a1 moveq #0,d0 move.w #7,d1

Title_ClrObjRam2: </asm>

and change it to: <asm> move.b #$25,d0 ; play title screen music bsr.w PlaySound_Special move.b #0,($FFFFFFFA).w ; disable debug mode move.w #$178,($FFFFF614).w ; run title screen for $178 frames lea ($FFFFD080).w,a1 moveq #0,d0 move.w #7,d1

Title_ClrObjRam2: </asm>

That fixes the title screen's music so that it plays Sonic 3 Title Screen music, or you can pick another music if you so choose.

Fixing the Special Stage music

Now that the title screen plays the right music, lets fix the Special Stage music. We simply want to locate: <asm> SS_ClrNemRam: move.l d0,(a1)+ dbf d1,SS_ClrNemRam ; clear Nemesis buffer

clr.b ($FFFFF64E).w clr.w ($FFFFFE02).w moveq #$A,d0 bsr.w PalLoad1 ; load special stage pallet jsr (SS_Load).l move.l #0,($FFFFF700).w move.l #0,($FFFFF704).w move.b #9,($FFFFD000).w ; load special stage Sonic object bsr.w PalCycle_SS clr.w ($FFFFF780).w ; set stage angle to "upright" move.w #$40,($FFFFF782).w ; set stage rotation speed move.w #$89,d0 bsr.w PlaySound ; play special stage BG music move.w #0,($FFFFF790).w lea (Demo_Index).l,a1 moveq #6,d0 lsl.w #2,d0 movea.l (a1,d0.w),a1 move.b 1(a1),($FFFFF792).w subq.b #1,($FFFFF792).w clr.w ($FFFFFE20).w clr.b ($FFFFFE1B).w move.w #0,($FFFFFE08).w move.w #1800,($FFFFF614).w tst.b ($FFFFFFE2).w ; has debug cheat been entered? beq.s SS_NoDebug ; if not, branch btst #6,($FFFFF604).w ; is A button pressed? beq.s SS_NoDebug ; if not, branch move.b #1,($FFFFFFFA).w ; enable debug mode </asm> and change it to: <asm> SS_ClrNemRam: move.l d0,(a1)+ dbf d1,SS_ClrNemRam ; clear Nemesis buffer

clr.b ($FFFFF64E).w clr.w ($FFFFFE02).w moveq #$A,d0 bsr.w PalLoad1 ; load special stage pallet jsr (SS_Load).l move.l #0,($FFFFF700).w move.l #0,($FFFFF704).w move.b #9,($FFFFD000).w ; load special stage Sonic object bsr.w PalCycle_SS clr.w ($FFFFF780).w ; set stage angle to "upright" move.w #$40,($FFFFF782).w ; set stage rotation speed move.w #$1C,d0 bsr.w PlaySound ; play special stage BG music move.w #0,($FFFFF790).w lea (Demo_Index).l,a1 moveq #6,d0 lsl.w #2,d0 movea.l (a1,d0.w),a1 move.b 1(a1),($FFFFF792).w subq.b #1,($FFFFF792).w clr.w ($FFFFFE20).w clr.b ($FFFFFE1B).w move.w #0,($FFFFFE08).w move.w #1800,($FFFFF614).w tst.b ($FFFFFFE2).w ; has debug cheat been entered? beq.s SS_NoDebug ; if not, branch btst #6,($FFFFF604).w ; is A button pressed? beq.s SS_NoDebug ; if not, branch move.b #1,($FFFFFFFA).w ; enable debug mode </asm> Now we have Sonic 3 Special Stage music on the special stage. Or you could choose a different song of your choice.

Fixing the Ending Sequence music

Now it's time to fix the music for the ending sequence. Find: <asm> End_LoadData: moveq #$1C,d0 bsr.w RunPLC_ROM ; load ending sequence patterns jsr (Hud_Base).l bsr.w LevelSizeLoad bsr.w DeformBgLayer bset #2,($FFFFF754).w bsr.w MainLoadBlockLoad bsr.w LoadTilesFromStart move.l #Col_GHZ,($FFFFF796).w ; load collision index move #$2300,sr lea (Kos_EndFlowers).l,a0 ; load extra flower patterns lea ($FFFF9400).w,a1 ; RAM address to buffer the patterns bsr.w KosDec moveq #3,d0 bsr.w PalLoad1 ; load Sonic"s pallet move.w #$8B,d0 bsr.w PlaySound ; play ending sequence music btst #6,($FFFFF604).w ; is button A pressed? beq.s End_LoadSonic ; if not, branch move.b #1,($FFFFFFFA).w ; enable debug mode </asm> and change it to: <asm> End_LoadData: moveq #$1C,d0 bsr.w RunPLC_ROM ; load ending sequence patterns jsr (Hud_Base).l bsr.w LevelSizeLoad bsr.w DeformBgLayer bset #2,($FFFFF754).w bsr.w MainLoadBlockLoad bsr.w LoadTilesFromStart move.l #Col_GHZ,($FFFFF796).w ; load collision index move #$2300,sr lea (Kos_EndFlowers).l,a0 ; load extra flower patterns lea ($FFFF9400).w,a1 ; RAM address to buffer the patterns bsr.w KosDec moveq #3,d0 bsr.w PalLoad1 ; load Sonic"s pallet move.w #$32,d0 bsr.w PlaySound ; play ending sequence music btst #6,($FFFFF604).w ; is button A pressed? beq.s End_LoadSonic ; if not, branch move.b #1,($FFFFFFFA).w ; enable debug mode </asm> That makes it so that Sonic 3 ending sequence music plays. Or you could choose a different music.

Fixing the Credits music

Time to fix the credits music, but it needs to be fixed in multiple places. First we find: <asm> LevSel_Credits: ; XREF: LevelSelect move.b #$1C,($FFFFF600).w ; set screen mode to $1C (Credits) move.b #$91,d0 bsr.w PlaySound_Special ; play credits music move.w #0,($FFFFFFF4).w rts </asm> and change it to: <asm> LevSel_Credits: ; XREF: LevelSelect move.b #$1C,($FFFFF600).w ; set screen mode to $1C (Credits) move.b #$26,d0 bsr.w PlaySound_Special ; play credits music move.w #0,($FFFFFFF4).w rts </asm> then we find: <asm> End_MainLoop: bsr.w PauseGame move.b #$18,($FFFFF62A).w bsr.w DelayProgram addq.w #1,($FFFFFE04).w bsr.w End_MoveSonic jsr (ObjectsLoad).l bsr.w DeformBgLayer jsr (BuildSprites).l jsr (ObjPosLoad).l bsr.w PalCycle_Load bsr.w OscillateNumDo bsr.w ChangeRingFrame cmpi.b #$18,($FFFFF600).w ; is scene number $18 (ending)? beq.s loc_52DA ; if yes, branch move.b #$1C,($FFFFF600).w ; set scene to $1C (credits) move.b #$91,d0 bsr.w PlaySound_Special ; play credits music move.w #0,($FFFFFFF4).w ; set credits index number to 0 rts </asm> and change it to: <asm> End_MainLoop: bsr.w PauseGame move.b #$18,($FFFFF62A).w bsr.w DelayProgram addq.w #1,($FFFFFE04).w bsr.w End_MoveSonic jsr (ObjectsLoad).l bsr.w DeformBgLayer jsr (BuildSprites).l jsr (ObjPosLoad).l bsr.w PalCycle_Load bsr.w OscillateNumDo bsr.w ChangeRingFrame cmpi.b #$18,($FFFFF600).w ; is scene number $18 (ending)? beq.s loc_52DA ; if yes, branch move.b #$1C,($FFFFF600).w ; set scene to $1C (credits) move.b #$26,d0 bsr.w PlaySound_Special ; play credits music move.w #0,($FFFFFFF4).w ; set credits index number to 0 rts </asm>

That fixes the credits music with Sonic 3 credits music, otherwise you could use a different song if you choose.

Fixing Special Event sound

Chaos Emerald

Time to fix sound for events that only happen in certain situations, i.e. end of level, game over / time over, extra life and such. first we will start with the Chaos Emerald Collection SFX. Go and find: <asm> Obj09_NoEmer: move.w #$93,d0 jsr (PlaySound_Special).l ; play emerald music moveq #0,d4 rts </asm> and change it to: <asm> Obj09_NoEmer: move.w #$2B,d0 jsr (PlaySound_Special).l ; play emerald music moveq #0,d4 rts </asm>

Game Over / Time Over

Next, we will start with Game Over / Time Over, go and find: <asm> loc_138C2: move.w #$8F,d0 jsr (PlaySound).l ; play game over music moveq #3,d0 jmp (LoadPLC).l ; load game over patterns </asm> and change it to: <asm> loc_138C2: move.w #$27,d0 jsr (PlaySound).l ; play game over music moveq #3,d0 jmp (LoadPLC).l ; load game over patterns </asm>

"Sonic has Passed" Music

That causes the Game Over and Time Over screens to use its Sonic 3 version or you could choose a different song if you wish. Now we will go on to End of level Results. Find: <asm> move.w ($FFFFFE20).w,d0 mulu.w #10,d0 ; multiply rings by 10 move.w d0,($FFFFF7D4).w ; set rings bonus move.w #$8E,d0 jsr (PlaySound_Special).l ; play end-of-level music lea ($FFFFD000).w,a1 moveq #0,d0 move.w #$7FF,d1

SS_EndClrObjRam: </asm> and change it to: <asm> move.w ($FFFFFE20).w,d0 mulu.w #10,d0 ; multiply rings by 10 move.w d0,($FFFFF7D4).w ; set rings bonus move.w #$29,d0 jsr (PlaySound_Special).l ; play end-of-level music lea ($FFFFD000).w,a1 moveq #0,d0 move.w #$7FF,d1

SS_EndClrObjRam: </asm> now find: <asm> loc_ECD0: add.w d0,d0 move.w TimeBonuses(pc,d0.w),($FFFFF7D2).w ; set time bonus move.w ($FFFFFE20).w,d0 ; load number of rings mulu.w #10,d0 ; multiply by 10 move.w d0,($FFFFF7D4).w ; set ring bonus move.w #$8E,d0 jsr (PlaySound_Special).l ; play "Sonic got through" music </asm> and change it to: <asm> loc_ECD0: add.w d0,d0 move.w TimeBonuses(pc,d0.w),($FFFFF7D2).w ; set time bonus move.w ($FFFFFE20).w,d0 ; load number of rings mulu.w #10,d0 ; multiply by 10 move.w d0,($FFFFF7D4).w ; set ring bonus move.w #$29,d0 jsr (PlaySound_Special).l ; play "Sonic got through" music </asm>

1up Sound

That fixes the End of Level and end of Special Stage results music by using modern version, but you could use a different song if you wish. Next we will fix the Extra Life sound, so find: <asm> loc_9CA4: addq.b #1,($FFFFFE12).w ; add 1 to the number of lives you have addq.b #1,($FFFFFE1C).w ; add 1 to the lives counter move.w #$88,d0 ; play extra life music </asm> and change it to: <asm> loc_9CA4: addq.b #1,($FFFFFE12).w ; add 1 to the number of lives you have addq.b #1,($FFFFFE1C).w ; add 1 to the lives counter move.w #$2A,d0 ; play extra life music </asm> now find: <asm> ExtraLife: addq.b #1,($FFFFFE12).w ; add 1 to the number of lives you have addq.b #1,($FFFFFE1C).w ; add 1 to the lives counter move.w #$88,d0 jmp (PlaySound).l ; play extra life music </asm> and change it to: <asm> ExtraLife: addq.b #1,($FFFFFE12).w ; add 1 to the number of lives you have addq.b #1,($FFFFFE1C).w ; add 1 to the lives counter move.w #$2A,d0 jmp (PlaySound).l ; play extra life music </asm> now find: <asm> Obj09_Get1Up: addq.b #1,($FFFFFE12).w ; add 1 to number of lives addq.b #1,($FFFFFE1C).w ; add 1 to lives counter move.w #$88,d0 jsr (PlaySound).l ; play extra life music moveq #0,d4 rts </asm> and change it to: <asm> Obj09_Get1Up: addq.b #1,($FFFFFE12).w ; add 1 to number of lives addq.b #1,($FFFFFE1C).w ; add 1 to lives counter move.w #$2A,d0 jsr (PlaySound).l ; play extra life music moveq #0,d4 rts </asm>

Stars Monitor

That fixes the extra life sound with the Sonic 3 version, though I am sure you could use a different one in a different slot if such thing exists. Time to fix the invincibility music, so find: <asm> Obj2E_ChkInvinc: cmpi.b #5,d0 ; does monitor contain invincibility? bne.s Obj2E_ChkRings move.b #1,($FFFFFE2D).w ; make Sonic invincible move.w #$4B0,($FFFFD032).w ; time limit for the power-up move.b #$38,($FFFFD200).w ; load stars object ($3801) move.b #1,($FFFFD21C).w move.b #$38,($FFFFD240).w ; load stars object ($3802) move.b #2,($FFFFD25C).w move.b #$38,($FFFFD280).w ; load stars object ($3803) move.b #3,($FFFFD29C).w move.b #$38,($FFFFD2C0).w ; load stars object ($3804) move.b #4,($FFFFD2DC).w tst.b ($FFFFF7AA).w ; is boss mode on? bne.s Obj2E_NoMusic ; if yes, branch move.w #$87,d0 jmp (PlaySound).l ; play invincibility music </asm> and change it to: <asm> Obj2E_ChkInvinc: cmpi.b #5,d0 ; does monitor contain invincibility? bne.s Obj2E_ChkRings move.b #1,($FFFFFE2D).w ; make Sonic invincible move.w #$4B0,($FFFFD032).w ; time limit for the power-up move.b #$38,($FFFFD200).w ; load stars object ($3801) move.b #1,($FFFFD21C).w move.b #$38,($FFFFD240).w ; load stars object ($3802) move.b #2,($FFFFD25C).w move.b #$38,($FFFFD280).w ; load stars object ($3803) move.b #3,($FFFFD29C).w move.b #$38,($FFFFD2C0).w ; load stars object ($3804) move.b #4,($FFFFD2DC).w tst.b ($FFFFF7AA).w ; is boss mode on? bne.s Obj2E_NoMusic ; if yes, branch move.w #$2C,d0 jmp (PlaySound).l ; play invincibility music </asm>

Extra Continue sound

That fixes the invincibility sound with the Sonic 3 version, but you could choose a different one if you wish. Next we will fix the get a continue sound, so find: <asm> Obj7E_Continue: ; XREF: Obj7E_Index move.b #4,($FFFFD6DA).w move.b #$14,($FFFFD6E4).w move.w #$BF,d0 jsr (PlaySound_Special).l ; play continues music addq.b #2,$24(a0) move.w #360,$1E(a0) ; set time delay to 6 seconds bra.w DisplaySprite </asm> and change it to: <asm> Obj7E_Continue: ; XREF: Obj7E_Index move.b #4,($FFFFD6DA).w move.b #$14,($FFFFD6E4).w move.w #$AC,d0 jsr (PlaySound_Special).l ; play continues music addq.b #2,$24(a0) move.w #360,$1E(a0) ; set time delay to 6 seconds bra.w DisplaySprite </asm> then find: <asm> Obj09_GetCont: jsr (CollectRing).l cmpi.w #50,($FFFFFE20).w ; check if you have 50 rings bcs.s Obj09_NoCont bset #0,($FFFFFE1B).w bne.s Obj09_NoCont addq.b #1,($FFFFFE18).w ; add 1 to number of continues move.w #$BF,d0 jsr (PlaySound).l ; play extra continue sound </asm> and change it to: <asm> Obj09_GetCont: jsr (CollectRing).l cmpi.w #50,($FFFFFE20).w ; check if you have 50 rings bcs.s Obj09_NoCont bset #0,($FFFFFE1B).w bne.s Obj09_NoCont addq.b #1,($FFFFFE18).w ; add 1 to number of continues move.w #$AC,d0 jsr (PlaySound).l ; play extra continue sound </asm>

Continue screen music

That fixes the extra continue sound that plays on both the End Result screen and in the Special Stage. How about fixing the music for the continue screen itself? That is what we are doing next, so find: <asm> jsr (ContScrCounter).l ; run countdown (start from 10) moveq #$12,d0 bsr.w PalLoad1 ; load continue screen pallet move.b #$90,d0 bsr.w PlaySound ; play continue music </asm> and change it to: <asm> jsr (ContScrCounter).l ; run countdown (start from 10) moveq #$12,d0 bsr.w PalLoad1 ; load continue screen pallet move.b #$28,d0 bsr.w PlaySound ; play continue music </asm>

Special Stage entrance/exit

That fixes the Continue Screen music. Though you could choose a different song if you wish. Time to fix the special stage entry sound, so find: <asm> SpecialStage: ; XREF: GameModeArray move.w #$CA,d0 bsr.w PlaySound_Special ; play special stage entry sound </asm> and change it to: <asm> SpecialStage: ; XREF: GameModeArray move.w #$AF,d0 bsr.w PlaySound_Special ; play special stage entry sound </asm> then find: <asm> SS_NormalExit: bsr.w PauseGame move.b #$C,($FFFFF62A).w bsr.w DelayProgram jsr (ObjectsLoad).l jsr (BuildSprites).l bsr.w RunPLC_RAM tst.w ($FFFFFE02).w beq.s SS_NormalExit tst.l ($FFFFF680).w bne.s SS_NormalExit move.w #$CA,d0 bsr.w PlaySound_Special ; play special stage exit sound bsr.w Pal_MakeFlash rts </asm> and change it to: <asm> SS_NormalExit: bsr.w PauseGame move.b #$C,($FFFFF62A).w bsr.w DelayProgram jsr (ObjectsLoad).l jsr (BuildSprites).l bsr.w RunPLC_RAM tst.w ($FFFFFE02).w beq.s SS_NormalExit tst.l ($FFFFF680).w bne.s SS_NormalExit move.w #$AF,d0 bsr.w PlaySound_Special ; play special stage exit sound bsr.w Pal_MakeFlash rts </asm>

Boss music

On entry and exit, the Special Stage should now play the correct sound. Time to fix the boss music, so find: <asm> loc_6ED0: move.w #$8C,d0 bsr.w PlaySound ; play boss music </asm> and change it to: <asm> loc_6ED0: move.w #$19,d0 bsr.w PlaySound ; play boss music </asm> then find: <asm> loc_6F4A: move.w #$8C,d0 bsr.w PlaySound ; play boss music </asm> and change it to: <asm> loc_6F4A: move.w #$19,d0 bsr.w PlaySound ; play boss music </asm> then find: <asm> loc_70D0: move.w #$8C,d0 bsr.w PlaySound ; play boss music </asm> and change it to: <asm> loc_70D0: move.w #$19,d0 bsr.w PlaySound ; play boss music </asm> then find: <asm> loc_7144: move.w #$8C,d0 bsr.w PlaySound ; play boss music </asm> and change it to: <asm> loc_7144: move.w #$19,d0 bsr.w PlaySound ; play boss music </asm> then find: <asm> loc_71EC: move.w #$8C,d0 bsr.w PlaySound ; play boss music </asm> and change it to: <asm> loc_71EC: move.w #$19,d0 bsr.w PlaySound ; play boss music </asm>

GHZ3 music restore, the modern way

I not that long ago remembered that since Sonic 1 does not have music memory support, the game's way of playing the previous song is hard coded, so we need to fix that since we added Memory Support earlier, so find: <asm> loc_179E0: clr.w $12(a0) move.w #$81,d0 jsr (PlaySound).l ; play GHZ music </asm> and change it to: <asm> loc_179E0: clr.w $12(a0) move.w ($FFFFFF90).w,d0 jsr (PlaySound).l ; play GHZ music </asm>

LZ3 music restore, the modern way

Now find: <asm> loc_18112: move.w #$82,d0 jsr (PlaySound).l ; play LZ music </asm> and change it to: <asm> loc_18112: move.w ($FFFFFF90).w,d0 jsr (PlaySound).l ; play LZ music </asm>

MZ3 music restore, the modern way

Now find: <asm> loc_1856C: clr.w $12(a0) move.w #$83,d0 jsr (PlaySound).l ; play MZ music </asm> and change it to: <asm> loc_1856C: clr.w $12(a0) move.w ($FFFFFF90).w,d0 jsr (PlaySound).l ; play MZ music </asm>

SLZ3 music restore, the modern way

Now find: <asm> loc_18BB4: clr.w $12(a0) move.w #$84,d0 jsr (PlaySound).l ; play SLZ music </asm> and change it to: <asm> loc_18BB4: clr.w $12(a0) move.w ($FFFFFF90).w,d0 jsr (PlaySound).l ; play SLZ music </asm>

SYZ3 music restore, the modern way

Find: <asm> loc_194E0: clr.w $12(a0) move.w #$85,d0 jsr (PlaySound).l ; play SYZ music </asm> and change it to: <asm> loc_194E0: clr.w $12(a0) move.w ($FFFFFF90).w,d0 jsr (PlaySound).l ; play SYZ music </asm>

SBZ2 cutscene, Sonic & Knuckles style

That fixes the boss music, though you could choose different music per-level if you wish within this part of the how-to. Next we will fix the cutscene just before SBZ3, and I would choose to have that music be SBZ music, to have an effect like the cut scenes in S&K. So find: <asm> Obj3A_SBZ2: ; XREF: Obj3A_ChkPos2 cmpi.b #4,$1A(a0) bne.w DeleteObject addq.b #2,$24(a0) clr.b ($FFFFF7CC).w ; unlock controls move.w #$8D,d0 jmp (PlaySound).l ; play FZ music </asm> and change it to: <asm> Obj3A_SBZ2: ; XREF: Obj3A_ChkPos2 cmpi.b #4,$1A(a0) bne.w DeleteObject addq.b #2,$24(a0) clr.b ($FFFFF7CC).w ; unlock controls move.w ($FFFFFF90).w,d0 jmp (PlaySound).l ; play level music </asm>

Air countdown music

That causes the game to use whatever music the level started with, but now we need to fix the air counter music, so find: <asm> move.w #$92,d0 jsr (PlaySound).l ; play countdown music

loc_13F02: </asm> and change it to: <asm> move.w #$31,d0 jsr (PlaySound).l ; play countdown music

loc_13F02: </asm> This uses the sonic 3 version of the underwater counter music, or you can use a custom one in a location of your own choice. Now lets fix the sound effects.

Fixing the sound effects so that they sound right, or at least close to right

So now we have all the music and a few sounds fixed, but what about the general sound effects (A0 - CF in sonic 1). Sound effects in sonic 3 start at 33 and end at DC, so lets fix them in sonic 1 order.

Quick Reference

If your disassembly has variables/constants defined for the sound effects, all you will have to do is compare this chart. If not, follow the steps underneath to change each and every reference.

Sound Effect Sonic 1 Sonic 3
Jump $A0 $62
Lamppost $A1 $63
Death $A3 $35
Skid $A4 $36
Hit Spikes $A6 $37
Push $A7 $69
Special Stage Goal $A8 $6A
Special Stage Item $A9 $6B
Splash $AA $6C
Hit Boss $AC $6E
Bubble $AD $38
Fireball $AE $70
Shield $AF $71
Saw $B0 $D8
Electric $B1 $79
Drown $B2 $3B
Flamethrower $B3 $48
Bumper $B4 $AA
Ring $B5 $33
Spikes Move $B6 $52
Rumbling $B7 $6F
Collapse $B9 $59
Special Stage Glass $BA $B5
Door Opening $BB $58
Teleport $BC $73
Chain Stomp (MZ) $BD $5F
Roll $BE $3C
Continue $BF $AC
Basaran $C0 $47
Break Item $C1 $3D
Warning $C2 $A9
Giant Ring $C3 $B3
Bomb $C4 $B4 (or $3D)
"Ca-ching" $C5 $B0
Lose Rings $C6 $B9
Chain Rise (MZ) $C7 $D2
Burning $C8 $D5
Bonus $C9 $8C
Special Stage Start $CA $AF
Wall Smash $CB $59
Spring $CC $B1
Switch $CD $8C
Ring (Left Speaker) $CE $33
Signpost $CF Doesn't exist, $5E is close
Waterfall $D0 $DB, sounds wonky

Detailed instructions for replacing hard-coded sounds, starting with the jump sound, find:

Sound $A0

<asm> move.w #$A0,d0 jsr (PlaySound_Special).l ; play jumping sound move.b #$13,$16(a0) move.b #9,$17(a0) btst #2,$22(a0) bne.s loc_13490 move.b #$E,$16(a0) move.b #7,$17(a0) move.b #2,$1C(a0) ; use "jumping" animation bset #2,$22(a0) addq.w #5,$C(a0)

locret_1348E: </asm> and change it to: <asm> move.w #$62,d0 jsr (PlaySound_Special).l ; play jumping sound move.b #$13,$16(a0) move.b #9,$17(a0) btst #2,$22(a0) bne.s loc_13490 move.b #$E,$16(a0) move.b #7,$17(a0) move.b #2,$1C(a0) ; use "jumping" animation bset #2,$22(a0) addq.w #5,$C(a0)

locret_1348E: </asm> then find: <asm> move.w #$A0,d0 jsr (PlaySound_Special).l ; play jumping sound

Obj09_NoJump: </asm> and change it to: <asm> move.w #$62,d0 jsr (PlaySound_Special).l ; play jumping sound

Obj09_NoJump: </asm>

Sound $A1

The jump sound should now be what it is supposed to be, so we fix the lamp post next, so find: <asm> Obj79_HitLamp: move.w ($FFFFD008).w,d0 sub.w 8(a0),d0 addq.w #8,d0 cmpi.w #$10,d0 bcc.w locret_16F90 move.w ($FFFFD00C).w,d0 sub.w $C(a0),d0 addi.w #$40,d0 cmpi.w #$68,d0 bcc.s locret_16F90 move.w #$A1,d0 jsr (PlaySound_Special).l ; play lamppost sound </asm> and change it to: <asm> Obj79_HitLamp: move.w ($FFFFD008).w,d0 sub.w 8(a0),d0 addq.w #8,d0 cmpi.w #$10,d0 bcc.w locret_16F90 move.w ($FFFFD00C).w,d0 sub.w $C(a0),d0 addi.w #$40,d0 cmpi.w #$68,d0 bcc.s locret_16F90 move.w #$63,d0 jsr (PlaySound_Special).l ; play lamppost sound </asm>

Sound $A2

Sound $A2 is not used in Sonic 1, so it will be skipped.

Sound $A3

that makes the lamp post sound correct, so lets fix the normal damage sound. Find: <asm> Hurt_ChkSpikes: move.w #0,$14(a0) move.b #$1A,$1C(a0) move.w #$78,$30(a0) move.w #$A3,d0 ; load normal damage sound </asm> and change it to: <asm> Hurt_ChkSpikes: move.w #0,$14(a0) move.b #$1A,$1C(a0) move.w #$78,$30(a0) move.w #$35,d0 ; load normal damage sound </asm> then find: <asm> move.w #$A3,d0 ; play normal death sound cmpi.b #$36,(a2) ; check if you were killed by spikes bne.s Kill_Sound move.w #$A6,d0 ; play spikes death sound

Kill_Sound: </asm> and change it to: <asm> move.w #$35,d0 ; play normal death sound cmpi.b #$36,(a2) ; check if you were killed by spikes bne.s Kill_Sound move.w #$A6,d0 ; play spikes death sound

Kill_Sound: </asm>

Sound $A4

Seems we have the hurt sound working, but now we fix the skid and stop sound, so find: <asm> move.w #$A4,d0 jsr (PlaySound_Special).l ; play stopping sound

locret_130E8: </asm> and change it to: <asm> move.w #$36,d0 jsr (PlaySound_Special).l ; play stopping sound

locret_130E8: </asm> then find: <asm> move.w #$A4,d0 jsr (PlaySound_Special).l ; play stopping sound

locret_1314E: </asm> and change it to: <asm> move.w #$36,d0 jsr (PlaySound_Special).l ; play stopping sound

locret_1314E: </asm>

Sound $A5

Now Sonic skids right, but we need to fix another sound. Find: <asm> move.w #$A5,d0 jsr (PlaySound_Special).l ; play explosion sound

Obj24_Animate: ; XREF: Obj24_Index </asm> and change it to: <asm> move.w #$67,d0 jsr (PlaySound_Special).l ; play explosion sound

Obj24_Animate: ; XREF: Obj24_Index </asm>

Sound $A6

Now find: <asm> move.w #$A6,d0 ; load spikes damage sound

Hurt_Sound: jsr (PlaySound_Special).l moveq #-1,d0 rts </asm> and change it to: <asm> move.w #$37,d0 ; load spikes damage sound

Hurt_Sound: jsr (PlaySound_Special).l moveq #-1,d0 rts </asm> Now find: <asm> move.w #$A3,d0 ; play normal death sound cmpi.b #$36,(a2) ; check if you were killed by spikes bne.s Kill_Sound move.w #$A6,d0 ; play spikes death sound

Kill_Sound: jsr (PlaySound_Special).l </asm> and change it to: <asm> move.w #$35,d0 ; play normal death sound cmpi.b #$36,(a2) ; check if you were killed by spikes bne.s Kill_Sound move.w #$37,d0 ; play spikes death sound

Kill_Sound: jsr (PlaySound_Special).l </asm>

Sound $A7

Now find: <asm> loc_C294: lea ($FFFFD000).w,a1 add.w d0,8(a1) move.w d1,$14(a1) move.w #0,$10(a1) move.w d0,-(sp) move.w #$A7,d0 jsr (PlaySound_Special).l ; play pushing sound </asm> and change it to: <asm> loc_C294: lea ($FFFFD000).w,a1 add.w d0,8(a1) move.w d1,$14(a1) move.w #0,$10(a1) move.w d0,-(sp) move.w #$69,d0 jsr (PlaySound_Special).l ; play pushing sound </asm>

Sound $A8

Now find: <asm> move.w #$A8,d0 jsr (PlaySound_Special).l ; play Special Stage "GOAL" sound

Obj4A_Display: jmp (DisplaySprite).l </asm> and change it to: <asm> move.w #$6A,d0 jsr (PlaySound_Special).l ; play Special Stage "GOAL" sound

Obj4A_Display: jmp (DisplaySprite).l </asm> Now find: <asm> move.w #$A8,d0 jsr (PlaySound_Special).l ; play special stage GOAL sound

locret_1B60C: rts </asm> and change it to: <asm> move.w #$6A,d0 jsr (PlaySound_Special).l ; play special stage GOAL sound

locret_1B60C: rts </asm> Now find: <asm> Obj09_GOAL: cmpi.b #$27,d0 ; is the item a "GOAL"? bne.s Obj09_UPblock addq.b #2,$24(a0) ; run routine "Obj09_ExitStage" move.w #$A8,d0 ; change item jsr (PlaySound_Special).l ; play "GOAL" sound rts </asm> and change it to: <asm> Obj09_GOAL: cmpi.b #$27,d0 ; is the item a "GOAL"? bne.s Obj09_UPblock addq.b #2,$24(a0) ; run routine "Obj09_ExitStage" move.w #$6A,d0 ; change item jsr (PlaySound_Special).l ; play "GOAL" sound rts </asm>

Sound $A9

Now find: <asm> Obj09_UPsnd: move.w #$A9,d0 jmp (PlaySound_Special).l ; play up/down sound </asm> and change it to: <asm> Obj09_UPsnd: move.w #$6B,d0 jmp (PlaySound_Special).l ; play up/down sound </asm> then find: <asm> Obj09_DOWNsnd: move.w #$A9,d0 jmp (PlaySound_Special).l ; play up/down sound </asm> and change it to: <asm> Obj09_DOWNsnd: move.w #$6B,d0 jmp (PlaySound_Special).l ; play up/down sound </asm> then find: <asm> Obj09_RevStage: neg.w ($FFFFF782).w ; reverse stage rotation move.w #$A9,d0 jmp (PlaySound_Special).l ; play sound </asm> and change it to: <asm> Obj09_RevStage: neg.w ($FFFFF782).w ; reverse stage rotation move.w #$6B,d0 jmp (PlaySound_Special).l ; play sound </asm>

Sound $AA

Now find: <asm> move.w #$AA,d0 jmp (PlaySound_Special).l ; play splash sound

===========================================================================

Obj01_OutWater: </asm> and change it to: <asm> move.w #$6C,d0 jmp (PlaySound_Special).l ; play splash sound

===========================================================================

Obj01_OutWater: </asm> then find: <asm> loc_12E0E: move.w #$AA,d0 jmp (PlaySound_Special).l ; play splash sound

End of function Sonic_Water

</asm> and change it to: <asm> loc_12E0E: move.w #$57,d0 jmp (PlaySound_Special).l ; play splash sound

End of function Sonic_Water

</asm>

Sound $AB

Sound $AB is not used in Sonic 1, so we will skip it.

Sound $AC

Now we will find: <asm> bne.s locret_1784A tst.b $3E(a0) bne.s Obj3D_ShipFlash move.b #$20,$3E(a0) ; set number of times for ship to flash move.w #$AC,d0 jsr (PlaySound_Special).l ; play boss damage sound

Obj3D_ShipFlash: </asm> and change it to: <asm> bne.s locret_1784A tst.b $3E(a0) bne.s Obj3D_ShipFlash move.b #$20,$3E(a0) ; set number of times for ship to flash move.w #$6E,d0 jsr (PlaySound_Special).l ; play boss damage sound

Obj3D_ShipFlash: </asm> then we will find: <asm> loc_17F48: tst.b $3D(a0) bne.s loc_17F8E tst.b $22(a0) bmi.s loc_17F92 tst.b $20(a0) bne.s locret_17F8C tst.b $3E(a0) bne.s loc_17F70 move.b #$20,$3E(a0) move.w #$AC,d0 jsr (PlaySound_Special).l </asm> and change it to: <asm> loc_17F48: tst.b $3D(a0) bne.s loc_17F8E tst.b $22(a0) bmi.s loc_17F92 tst.b $20(a0) bne.s locret_17F8C tst.b $3E(a0) bne.s loc_17F70 move.b #$20,$3E(a0) move.w #$6E,d0 jsr (PlaySound_Special).l </asm> then find: <asm> loc_1833E: move.w $38(a0),$C(a0) move.w $30(a0),8(a0) cmpi.b #4,$25(a0) bcc.s locret_18390 tst.b $22(a0) bmi.s loc_18392 tst.b $20(a0) bne.s locret_18390 tst.b $3E(a0) bne.s loc_18374 move.b #$28,$3E(a0) move.w #$AC,d0 jsr (PlaySound_Special).l ; play boss damage sound </asm> and change it to: <asm> loc_1833E: move.w $38(a0),$C(a0) move.w $30(a0),8(a0) cmpi.b #4,$25(a0) bcc.s locret_18390 tst.b $22(a0) bmi.s loc_18392 tst.b $20(a0) bne.s locret_18390 tst.b $3E(a0) bne.s loc_18374 move.b #$28,$3E(a0) move.w #$6E,d0 jsr (PlaySound_Special).l ; play boss damage sound </asm>

then find: <asm> loc_189FE: cmpi.b #6,$25(a0) bcc.s locret_18A44 tst.b $22(a0) bmi.s loc_18A46 tst.b $20(a0) bne.s locret_18A44 tst.b $3E(a0) bne.s loc_18A28 move.b #$20,$3E(a0) move.w #$AC,d0 jsr (PlaySound_Special).l ; play boss damage sound </asm> and change it to: <asm> loc_189FE: cmpi.b #6,$25(a0) bcc.s locret_18A44 tst.b $22(a0) bmi.s loc_18A46 tst.b $20(a0) bne.s locret_18A44 tst.b $3E(a0) bne.s loc_18A28 move.b #$20,$3E(a0) move.w #$6E,d0 jsr (PlaySound_Special).l ; play boss damage sound </asm> then find: <asm> loc_19202: move.w 8(a0),d0 subi.w #$2C00,d0 lsr.w #5,d0 move.b d0,$34(a0) cmpi.b #6,$25(a0) bcc.s locret_19256 tst.b $22(a0) bmi.s loc_19258 tst.b $20(a0) bne.s locret_19256 tst.b $3E(a0) bne.s loc_1923A move.b #$20,$3E(a0) move.w #$AC,d0 jsr (PlaySound_Special).l ; play boss damage sound </asm> and change it to: <asm> loc_19202: move.w 8(a0),d0 subi.w #$2C00,d0 lsr.w #5,d0 move.b d0,$34(a0) cmpi.b #6,$25(a0) bcc.s locret_19256 tst.b $22(a0) bmi.s loc_19258 tst.b $20(a0) bne.s locret_19256 tst.b $3E(a0) bne.s loc_1923A move.b #$20,$3E(a0) move.w #$6E,d0 jsr (PlaySound_Special).l ; play boss damage sound </asm> then find: <asm> loc_19F6A: move.w d0,($FFFFD010).w tst.b $35(a0) bne.s loc_19F88 subq.b #1,$21(a0) move.b #$64,$35(a0) move.w #$AC,d0 jsr (PlaySound_Special).l ; play boss damage sound </asm> and change it to: <asm> loc_19F6A: move.w d0,($FFFFD010).w tst.b $35(a0) bne.s loc_19F88 subq.b #1,$21(a0) move.b #$64,$35(a0) move.w #$6E,d0 jsr (PlaySound_Special).l ; play boss damage sound </asm> Now find: <asm> loc_1A1D4: ; XREF: off_19E80 bset #0,$22(a0) jsr (SpeedToPos).l tst.w $30(a0) bne.s loc_1A1FC tst.b $20(a0) bne.s loc_1A216 move.w #$1E,$30(a0) move.w #$AC,d0 jsr (PlaySound_Special).l ; play boss damage sound </asm> and change it to: <asm> loc_1A1D4: ; XREF: off_19E80 bset #0,$22(a0) jsr (SpeedToPos).l tst.w $30(a0) bne.s loc_1A1FC tst.b $20(a0) bne.s loc_1A216 move.w #$1E,$30(a0) move.w #$6E,d0 jsr (PlaySound_Special).l ; play boss damage sound </asm>

Sound $AD

Lets fix the air bubble sound, so locate: <asm> bsr.w ResumeMusic ; cancel countdown music move.w #$AD,d0 jsr (PlaySound_Special).l ; play collecting bubble sound lea ($FFFFD000).w,a1 </asm> Should not be very hard to do, it is part of Object 64's wobble routine, and there is a single line it it to change so that it is like this: <asm> bsr.w ResumeMusic ; cancel countdown music move.w #$38,d0 jsr (PlaySound_Special).l ; play collecting bubble sound lea ($FFFFD000).w,a1 </asm>

Sound $AE

Now find: <asm> Obj14_PlaySnd: move.w #$AE,d0 jsr (PlaySound_Special).l ; play lava ball sound </asm> and change it to: <asm> Obj14_PlaySnd: move.w #$70,d0 jsr (PlaySound_Special).l ; play lava ball sound </asm> then find: <asm> Obj62_Sound: move.w #$AE,d0 jsr (PlaySound_Special).l ; play lava ball sound </asm> then change it to: <asm> Obj62_Sound: move.w #$70,d0 jsr (PlaySound_Special).l ; play lava ball sound </asm> then find: <asm> loc_1870A: move.b #$1E,$29(a0) move.w #$AE,d0 jsr (PlaySound_Special).l ; play lava sound </asm> and change it to: <asm> loc_1870A: move.b #$1E,$29(a0) move.w #$70,d0 jsr (PlaySound_Special).l ; play lava sound </asm>

Sound $AF

Now find: <asm> Obj2E_ChkShield: cmpi.b #4,d0 ; does monitor contain a shield? bne.s Obj2E_ChkInvinc move.b #1,($FFFFFE2C).w ; give Sonic a shield move.b #$38,($FFFFD180).w ; load shield object ($38) move.w #$AF,d0 jmp (PlaySound).l ; play shield sound </asm> and change it to: <asm> Obj2E_ChkShield: cmpi.b #4,d0 ; does monitor contain a shield? bne.s Obj2E_ChkInvinc move.b #1,($FFFFFE2C).w ; give Sonic a shield move.b #$38,($FFFFD180).w ; load shield object ($38) move.w #$71,d0 jmp (PlaySound).l ; play shield sound </asm>

Sound $B0

Now find: <asm> loc_15A46: tst.b 1(a0) bpl.s locret_15A60 move.w ($FFFFFE04).w,d0 andi.w #$F,d0 bne.s locret_15A60 move.w #$B0,d0 jsr (PlaySound_Special).l ; play saw sound </asm> and change it to: <asm> loc_15A46: tst.b 1(a0) bpl.s locret_15A60 move.w ($FFFFFE04).w,d0 andi.w #$F,d0 bne.s locret_15A60 move.w #$D8,d0 jsr (PlaySound_Special).l ; play saw sound </asm> Now find: <asm> loc_15A96: tst.b 1(a0) bpl.s locret_15AB0 move.b ($FFFFFE64).w,d0 cmpi.b #$18,d0 bne.s locret_15AB0 move.w #$B0,d0 jsr (PlaySound_Special).l ; play saw sound </asm> and change it to: <asm> loc_15A96: tst.b 1(a0) bpl.s locret_15AB0 move.b ($FFFFFE64).w,d0 cmpi.b #$18,d0 bne.s locret_15AB0 move.w #$D8,d0 jsr (PlaySound_Special).l ; play saw sound </asm> Now find: <asm> move.w #$B0,d0 jsr (PlaySound_Special).l ; play saw sound

loc_15B02: addq.l #4,sp </asm> and change it to: <asm> move.w #$D8,d0 jsr (PlaySound_Special).l ; play saw sound

loc_15B02: addq.l #4,sp </asm> Now find: <asm> move.w #$B0,d0 jsr (PlaySound_Special).l ; play saw sound

loc_15B74: addq.l #4,sp </asm> and change it to: <asm> move.w #$D8,d0 jsr (PlaySound_Special).l ; play saw sound

loc_15B74: addq.l #4,sp </asm>

Sound $B1

The next sound is a little different. Sonic 1 uses the same sound effect for both the shocker orb thingies and the balls of lightning in the final boss, but the Sonic 3 driver has a couple of sound effects that I see fitting better. Shocker orbs will use the sound used for a certain badnik in Carnival Night, because it sounds better in my opinion, while the balls of lightning from final boss will use the sound used for Knux being shocked in Hidden palace. This is how Sonic 3D: Flickies Island used similar sound effects, so we will find: <asm> Obj6E_Shock: ; XREF: Obj6E_Index move.w ($FFFFFE04).w,d0 and.w $34(a0),d0 bne.s Obj6E_Animate move.b #1,$1C(a0) ; run "shocking" animation tst.b 1(a0) bpl.s Obj6E_Animate move.w #$B1,d0 jsr (PlaySound_Special).l ; play electricity sound </asm> and change it to: <asm> Obj6E_Shock: ; XREF: Obj6E_Index move.w ($FFFFFE04).w,d0 and.w $34(a0),d0 bne.s Obj6E_Animate move.b #1,$1C(a0) ; run "shocking" animation tst.b 1(a0) bpl.s Obj6E_Animate move.w #$79,d0 jsr (PlaySound_Special).l ; play cnz shock and teleport sound </asm> then find: <asm> loc_1A020: move.w #$B1,d0 jmp (PlaySound_Special).l ; play electricity sound </asm> and change it to: <asm> loc_1A020: move.w #$78,d0 jmp (PlaySound_Special).l ; play shock knux sound </asm>

Sound $B2

The next sound is a lot more like the others, it is the drowning sound. We will locate: <asm> Obj0A_ReduceAir: subq.w #1,($FFFFFE14).w ; subtract 1 from air remaining bcc.w Obj0A_GoMakeItem ; if air is above 0, branch bsr.w ResumeMusic move.b #$81,($FFFFF7C8).w ; lock controls move.w #$B2,d0 </asm> and change it to: <asm> Obj0A_ReduceAir: subq.w #1,($FFFFFE14).w ; subtract 1 from air remaining bcc.w Obj0A_GoMakeItem ; if air is above 0, branch bsr.w ResumeMusic move.b #$81,($FFFFF7C8).w ; lock controls move.w #$3B,d0 </asm>

Sound $B3

Now find: <asm> move.w #$B3,d0 jsr (PlaySound_Special).l ; play flame sound

loc_E57A: </asm> and change it to: <asm> move.w #$48,d0 jsr (PlaySound_Special).l ; play flame sound

loc_E57A: </asm>

Sound $B4

Now find: <asm> move.w #$B4,d0 jsr (PlaySound_Special).l ; play bumper sound lea ($FFFFFC00).w,a2 moveq #0,d0 move.b $23(a0),d0 beq.s Obj47_Score cmpi.b #$8A,2(a2,d0.w) ; has bumper been hit $8A times? bcc.s Obj47_Display ; if yes, Sonic gets no points addq.b #1,2(a2,d0.w)

Obj47_Score: </asm> and change it to: <asm> move.w #$AA,d0 jsr (PlaySound_Special).l ; play bumper sound lea ($FFFFFC00).w,a2 moveq #0,d0 move.b $23(a0),d0 beq.s Obj47_Score cmpi.b #$8A,2(a2,d0.w) ; has bumper been hit $8A times? bcc.s Obj47_Display ; if yes, Sonic gets no points addq.b #1,2(a2,d0.w)

Obj47_Score: </asm> and find: <asm> Obj09_BumpSnd: move.w #$B4,d0 jmp (PlaySound_Special).l ; play bumper sound

===========================================================================

</asm> and change it to: <asm> Obj09_BumpSnd: move.w #$AA,d0 jmp (PlaySound_Special).l ; play bumper sound

===========================================================================

</asm>

Sound $B5

Now find: <asm> Title_PlayRing: move.b #1,(a0,d1.w) ; activate cheat move.b #$B5,d0 ; play ring sound when code is entered bsr.w PlaySound_Special </asm> and change it to: <asm> Title_PlayRing: move.b #1,(a0,d1.w) ; activate cheat move.b #$33,d0 ; play ring sound when code is entered bsr.w PlaySound_Special </asm> then find: <asm> CollectRing: ; XREF: Obj25_Collect addq.w #1,($FFFFFE20).w ; add 1 to rings ori.b #1,($FFFFFE1D).w ; update the rings counter move.w #$B5,d0 ; play ring sound </asm> and change it to: <asm> CollectRing: ; XREF: Obj25_Collect addq.w #1,($FFFFFE20).w ; add 1 to rings ori.b #1,($FFFFFE1D).w ; update the rings counter move.w #$33,d0 ; play ring sound </asm> then find: <asm> Obj2E_RingSound: move.w #$B5,d0 jmp (PlaySound).l ; play ring sound </asm> and change it to: <asm> Obj2E_RingSound: move.w #$33,d0 jmp (PlaySound).l ; play ring sound </asm>

Sound $B6

Now find: <asm> move.w #$B6,d0 jsr (PlaySound_Special).l ; play "spikes moving" sound bra.s locret_CFE6

===========================================================================

loc_CFA4: </asm> and change it to: <asm> move.w #$52,d0 jsr (PlaySound_Special).l ; play "spikes moving" sound bra.s locret_CFE6

===========================================================================

loc_CFA4: </asm>

Sound $B7

Now find: <asm> move.w #$B7,d0 bsr.w PlaySound_Special ; play sound $B7 (rumbling)

loc_3D54: </asm> and change it to: <asm> move.w #$6F,d0 bsr.w PlaySound_Special ; play sound $6F (rumbling)

loc_3D54: </asm> Now find: <asm> move.w #$B7,d0 bsr.w PlaySound_Special ; play rumbling sound

loc_6F28: </asm> and change it to: <asm> move.w #$6F,d0 bsr.w PlaySound_Special ; play rumbling sound

loc_6F28: </asm> Now find: <asm> move.w #$B7,d0 jsr (PlaySound_Special).l ; play rumbling sound

loc_19F10: </asm> and change it to: <asm> move.w #$6F,d0 jsr (PlaySound_Special).l ; play rumbling sound

loc_19F10: </asm>

Sound $B8

Sound $B8 is not used in Sonic 1, so we will skip it.

Sound $B9

Now find: <asm> loc_84F2: bsr.w DisplaySprite move.w #$B9,d0 jmp (PlaySound_Special).l ; play collapsing sound </asm> and we change it to: <asm> loc_84F2: bsr.w DisplaySprite move.w #$59,d0 jmp (PlaySound_Special).l ; play collapsing sound </asm>

Sound $BA

Note: the breaking and collapsing sounds in Sonic 3 are the same.
now we will find: <asm> Obj09_GlassSnd: move.w #$BA,d0 jmp (PlaySound_Special).l ; play glass block sound </asm> and change it to: <asm> Obj09_GlassSnd: move.w #$B5,d0 jmp (PlaySound_Special).l ; play glass block sound </asm>

Sound $BB

Now find: <asm> move.w #$BB,d0 jsr (PlaySound_Special).l ; play door sound

Obj0C_Solid: </asm> and change it to: <asm> move.w #$58,d0 jsr (PlaySound_Special).l ; play door sound

Obj0C_Solid: </asm>

Now find: <asm> move.w #$BB,d0 jsr (PlaySound_Special).l ; play door sound

Obj69_Animate: </asm> and change it to: <asm> move.w #$58,d0 jsr (PlaySound_Special).l ; play door sound

Obj69_Animate: </asm>

Sound $BC

Note: this sound effect is used differently in Sonic 3 but is the closest to what we have here
Now we find: <asm> move.w #$BC,d0 jsr (PlaySound_Special).l ; play teleport sound

locret_16796: rts </asm> and change it to: <asm> move.w #$73,d0 jsr (PlaySound_Special).l ; play teleport sound

locret_16796: rts </asm>

Sound $BD

Now find: <asm> move.w #$BD,d0 jsr (PlaySound_Special).l ; play stomping sound

Obj31_Restart: </asm> and change it to: <asm> move.w #$5F,d0 jsr (PlaySound_Special).l ; play stomping sound

Obj31_Restart: </asm> Now find: <asm> move.w #$BD,d0 jsr (PlaySound_Special).l ; play stomping sound

loc_B97C: bra.w Obj31_Restart </asm> and change it to: <asm> move.w #$5F,d0 jsr (PlaySound_Special).l ; play stomping sound

loc_B97C: bra.w Obj31_Restart </asm>

Sound $BE

note: this stomp sound is very different, though it is a stomping sound, the one from MGZ to be exact
Now find: <asm> move.w #$BE,d0 jsr (PlaySound_Special).l ; play rolling sound tst.w $14(a0) bne.s locret_133E8 move.w #$200,$14(a0)

locret_133E8: rts </asm> and change it to: <asm> move.w #$3C,d0 jsr (PlaySound_Special).l ; play rolling sound tst.w $14(a0) bne.s locret_133E8 move.w #$200,$14(a0)

locret_133E8: rts </asm> Now find: <asm> move.w #$BE,d0 jsr (PlaySound_Special).l ; play Sonic rolling sound

locret_1675C: rts </asm> and change it to: <asm> move.w #$53,d0 jsr (PlaySound_Special).l ; sonic & knuckles begin teleportation

locret_1675C: rts </asm>

Sound $BF

This sound should already be fixed if you were following the guide, please refer to special event sounds if it isn't by now.

Sound $C0

Seems the Sonic 3 driver does not have a sound for this, since the bat robot in CNZ (Sonic 3) does not sound anywhere close to the MZ (sonic 1) variant, we will use a similar but close sound.
Lets look at the code: <asm> Obj55_PlaySnd: ; XREF: Obj55_Index2 move.b ($FFFFFE0F).w,d0 andi.b #$F,d0 bne.s loc_101A0 move.w #$C0,d0 jsr (PlaySound_Special).l ; play flapping sound </asm> and change it to: <asm> Obj55_PlaySnd: ; XREF: Obj55_Index2 move.b ($FFFFFE0F).w,d0 andi.b #$F,d0 bne.s loc_101A0 move.w #$47,d0 jsr (PlaySound_Special).l ; play flapping sound </asm>

Sound $C1

now we will find: <asm> Obj27_Main: ; XREF: Obj27_Index addq.b #2,$24(a0) move.l #Map_obj27,4(a0) move.w #$5A0,2(a0) move.b #4,1(a0) move.b #1,$18(a0) move.b #0,$20(a0) move.b #$C,$19(a0) move.b #7,$1E(a0) ; set frame duration to 7 frames move.b #0,$1A(a0) move.w #$C1,d0 jsr (PlaySound_Special).l ; play breaking enemy sound </asm> and change it to: <asm> Obj27_Main: ; XREF: Obj27_Index addq.b #2,$24(a0) move.l #Map_obj27,4(a0) move.w #$5A0,2(a0) move.b #4,1(a0) move.b #1,$18(a0) move.b #0,$20(a0) move.b #$C,$19(a0) move.b #7,$1E(a0) ; set frame duration to 7 frames move.b #0,$1A(a0) move.w #$3D,d0 jsr (PlaySound_Special).l ; play breaking enemy sound </asm>

Sound $C2

The warning sound that you hear every so often under water "ding, ding" will be fixed by finding: <asm> Obj0A_WarnSound: ; XREF: Obj0A_Countdown move.w #$C2,d0 jsr (PlaySound_Special).l ; play "ding-ding" warning sound </asm> and changing it to: <asm> Obj0A_WarnSound: ; XREF: Obj0A_Countdown move.w #$A9,d0 jsr (PlaySound_Special).l ; play "ding-ding" warning sound </asm>

Sound $C3

The Special Stage ring sound. Find:

<asm> Obj4B_PlaySnd: move.w #$C3,d0 jsr (PlaySound_Special).l ; play giant ring sound bra.s Obj4B_Animate </asm> and changing it to: <asm> Obj4B_PlaySnd: move.w #$B3,d0 jsr (PlaySound_Special).l ; play giant ring sound bra.s Obj4B_Animate </asm>

Sound $C4

For this one, you can use a Sonic 3/S&K/S3K exploding sound (monitor/badnik pop), or use the classic, with is $B4, both work in a sonic game and either one could be useful in the hack, it is up to you. For that reason, I will provide two different versions of this step.

Classic version

Still want the old school sound with the sonic 3 driver?
find: <asm> Obj3F_Main: ; XREF: Obj3F_Index addq.b #2,$24(a0) move.l #Map_obj3F,4(a0) move.w #$5A0,2(a0) move.b #4,1(a0) move.b #1,$18(a0) move.b #0,$20(a0) move.b #$C,$19(a0) move.b #7,$1E(a0) move.b #0,$1A(a0) move.w #$C4,d0 jmp (PlaySound_Special).l ; play exploding bomb sound </asm> and change it to: <asm> Obj3F_Main: ; XREF: Obj3F_Index addq.b #2,$24(a0) move.l #Map_obj3F,4(a0) move.w #$5A0,2(a0) move.b #4,1(a0) move.b #1,$18(a0) move.b #0,$20(a0) move.b #$C,$19(a0) move.b #7,$1E(a0) move.b #0,$1A(a0) move.w #$B4,d0 jmp (PlaySound_Special).l ; play exploding bomb sound </asm>

Sonic3/k version (my favorite)

Want the new sound?
Find: <asm> Obj3F_Main: ; XREF: Obj3F_Index addq.b #2,$24(a0) move.l #Map_obj3F,4(a0) move.w #$5A0,2(a0) move.b #4,1(a0) move.b #1,$18(a0) move.b #0,$20(a0) move.b #$C,$19(a0) move.b #7,$1E(a0) move.b #0,$1A(a0) move.w #$C4,d0 jmp (PlaySound_Special).l ; play exploding bomb sound </asm> and change it to: <asm> Obj3F_Main: ; XREF: Obj3F_Index addq.b #2,$24(a0) move.l #Map_obj3F,4(a0) move.w #$5A0,2(a0) move.b #4,1(a0) move.b #1,$18(a0) move.b #0,$20(a0) move.b #$C,$19(a0) move.b #7,$1E(a0) move.b #0,$1A(a0) move.w #$3D,d0 jmp (PlaySound_Special).l ; play monitor destruction sound like sonic3/k </asm> You are probably wondering, why use this sound here? The LRZ exploding rock uses it and Asteron (Sonic 2, MTZ) uses it, and besides, it is used in the Eggman defeat routine and the Egg Prison destruction routine. The result, the Eggman defeat sounds as it does in Sonic 3, so time to update the Eggmobile now if you so choose so that it fits better with this sound improvement.

Sound $C5

The ker-ching sound is in Sonic 3, so lets modify the End Of Results bonus checker to play it.
find: <asm> Obj3A_ChkBonus: tst.w d0 ; is there any bonus? bne.s Obj3A_AddBonus ; if yes, branch move.w #$C5,d0 jsr (PlaySound_Special).l ; play "ker-ching" sound addq.b #2,$24(a0) cmpi.w #$501,($FFFFFE10).w bne.s Obj3A_SetDelay addq.b #4,$24(a0) </asm> and change it to: <asm> Obj3A_ChkBonus: tst.w d0 ; is there any bonus? bne.s Obj3A_AddBonus ; if yes, branch move.w #$B0,d0 jsr (PlaySound_Special).l ; play "ker-ching" sound addq.b #2,$24(a0) cmpi.w #$501,($FFFFFE10).w bne.s Obj3A_SetDelay addq.b #4,$24(a0) </asm>

then find: <asm> loc_C8C4: ; XREF: Obj7E_RingBonus move.w #$C5,d0 jsr (PlaySound_Special).l ; play "ker-ching" sound addq.b #2,$24(a0) move.w #180,$1E(a0) ; set time delay to 3 seconds cmpi.w #50,($FFFFFE20).w ; do you have at least 50 rings? bcs.s locret_C8EA ; if not, branch move.w #60,$1E(a0) ; set time delay to 1 second addq.b #4,$24(a0) ; goto "Obj7E_Continue" routine </asm> and change it to: <asm> loc_C8C4: ; XREF: Obj7E_RingBonus move.w #$B0,d0 jsr (PlaySound_Special).l ; play "ker-ching" sound addq.b #2,$24(a0) move.w #180,$1E(a0) ; set time delay to 3 seconds cmpi.w #50,($FFFFFE20).w ; do you have at least 50 rings? bcs.s locret_C8EA ; if not, branch move.w #60,$1E(a0) ; set time delay to 1 second addq.b #4,$24(a0) ; goto "Obj7E_Continue" routine </asm>

Sound $C6

Fixing this sound will make sonic's ring loss sound right, so locate: <asm> Obj37_ResetCounter: ; XREF: Obj37_Loop move.w #0,($FFFFFE20).w ; reset number of rings to zero move.b #$80,($FFFFFE1D).w ; update ring counter move.b #0,($FFFFFE1B).w move.w #$C6,d0 jsr (PlaySound_Special).l ; play ring loss sound </asm> and change it to: <asm> Obj37_ResetCounter: ; XREF: Obj37_Loop move.w #0,($FFFFFE20).w ; reset number of rings to zero move.b #$80,($FFFFFE1D).w ; update ring counter move.b #0,($FFFFFE1B).w move.w #$B9,d0 jsr (PlaySound_Special).l ; play ring loss sound </asm>

Sound $C7

Remember the giant weight with spikes under it that goes up and crashes down in MZ? We are going to fix the sound now.
find: <asm> loc_B872: tst.w $32(a0) beq.s loc_B8A0 move.b ($FFFFFE0F).w,d0 andi.b #$F,d0 bne.s loc_B892 tst.b 1(a0) bpl.s loc_B892 move.w #$C7,d0 jsr (PlaySound_Special).l ; play rising chain sound </asm> and change it to: <asm> loc_B872: tst.w $32(a0) beq.s loc_B8A0 move.b ($FFFFFE0F).w,d0 andi.b #$F,d0 bne.s loc_B892 tst.b 1(a0) bpl.s loc_B892 move.w #$D2,d0 jsr (PlaySound_Special).l ; play rising chain sound </asm> and then find: <asm> loc_B902: move.b ($FFFFFE0F).w,d0 andi.b #$F,d0 bne.s loc_B91C tst.b 1(a0) bpl.s loc_B91C move.w #$C7,d0 jsr (PlaySound_Special).l ; play rising chain sound </asm> and change it to: <asm> loc_B902: move.b ($FFFFFE0F).w,d0 andi.b #$F,d0 bne.s loc_B91C tst.b 1(a0) bpl.s loc_B91C move.w #$D2,d0 jsr (PlaySound_Special).l ; play rising chain sound </asm>

Sound $C8

Once again, Sonic 3 has 2 sounds for this one. (one used in the spiked weight in LRZ, the other from the lava waterfalls also in LRZ) we will put them both where they belong)
First we will make the MZ lava spouts use the lava waterfall sound (yes, that one): <asm> Obj4D_PlaySnd: move.w #$C8,d0 jsr (PlaySound_Special).l ; play flame sound </asm> and yes change the code to: <asm> Obj4D_PlaySnd: move.w #$D5,d0 jsr (PlaySound_Special).l ; play flame sound </asm> now for the other sound: <asm> Obj35_Main: ; XREF: Obj35_Index addq.b #2,$24(a0) move.l #Map_obj14,4(a0) move.w #$345,2(a0) move.w 8(a0),$2A(a0) move.b #4,1(a0) move.b #1,$18(a0) move.b #$8B,$20(a0) move.b #8,$19(a0) move.w #$C8,d0 jsr (PlaySound_Special).l ; play flame sound tst.b $28(a0) beq.s loc_B238 addq.b #2,$24(a0) bra.w Obj35_Move </asm> and it should be changed to: <asm> Obj35_Main: ; XREF: Obj35_Index addq.b #2,$24(a0) move.l #Map_obj14,4(a0) move.w #$345,2(a0) move.w 8(a0),$2A(a0) move.b #4,1(a0) move.b #1,$18(a0) move.b #$8B,$20(a0) move.b #8,$19(a0) move.w #$7F,d0 jsr (PlaySound_Special).l ; play flame sound tst.b $28(a0) beq.s loc_B238 addq.b #2,$24(a0) bra.w Obj35_Move </asm>

Sound $C9

The hidden points sound is no longer in Sonic 3, but the Hey Ho (MHZ Miniboss) has a similar sound that is used, so it probably will have to work until you replace a sound effect.
Find: <asm> move.w #$C9,d0 jsr (PlaySound_Special).l ; play bonus sound moveq #0,d0 move.b $28(a0),d0 add.w d0,d0 move.w Obj7D_Points(pc,d0.w),d0 ; load bonus points array jsr (AddPoints).l

Obj7D_ChkDel: </asm> and change it to: <asm> move.w #$8C,d0 jsr (PlaySound_Special).l ; play bonus sound moveq #0,d0 move.b $28(a0),d0 add.w d0,d0 move.w Obj7D_Points(pc,d0.w),d0 ; load bonus points array jsr (AddPoints).l

Obj7D_ChkDel: </asm>

Sound $CA

This sound should already be fixed by now. (it was fixed with Special Event sounds)

Sound $CB

Remember that I said Sonic 3 has only 1 version of this sound above?
The crumbling sound from above and smashing sound in Sonic 3 are identical, so find: <asm> loc_197D4: move.w #$CB,d0 jmp (PlaySound_Special).l ; play smashing sound </asm> and change it to: <asm> loc_197D4: move.w #$59,d0 jmp (PlaySound_Special).l ; play smashing sound </asm> then find: <asm> Obj83_BreakSnd: move.w #$CB,d0 jsr (PlaySound_Special).l ; play smashing sound jmp (DisplaySprite).l </asm> and change it to: <asm> Obj83_BreakSnd: move.w #$59,d0 jsr (PlaySound_Special).l ; play smashing sound jmp (DisplaySprite).l </asm> Now find: <asm> Smash_PlaySnd: move.w #$CB,d0 jmp (PlaySound_Special).l ; play smashing sound

End of function SmashObject

</asm> and change it to: <asm> Smash_PlaySnd: move.w #$59,d0 jmp (PlaySound_Special).l ; play smashing sound

End of function SmashObject

</asm>

Sound $CC

The Spring Sound now, find: <asm> Obj41_BounceUp: ; XREF: Obj41_Up addq.b #2,$24(a0) addq.w #8,$C(a1) move.w $30(a0),$12(a1) ; move Sonic upwards bset #1,$22(a1) bclr #3,$22(a1) move.b #$10,$1C(a1) ; use "bouncing" animation move.b #2,$24(a1) bclr #3,$22(a0) clr.b $25(a0) move.w #$CC,d0 jsr (PlaySound_Special).l ; play spring sound </asm> and change it to: <asm> Obj41_BounceUp: ; XREF: Obj41_Up addq.b #2,$24(a0) addq.w #8,$C(a1) move.w $30(a0),$12(a1) ; move Sonic upwards bset #1,$22(a1) bclr #3,$22(a1) move.b #$10,$1C(a1) ; use "bouncing" animation move.b #2,$24(a1) bclr #3,$22(a0) clr.b $25(a0) move.w #$B1,d0 jsr (PlaySound_Special).l ; play spring sound </asm> then find: <asm> loc_DC56: bclr #5,$22(a0) bclr #5,$22(a1) move.w #$CC,d0 jsr (PlaySound_Special).l ; play spring sound </asm> and change it to: <asm> loc_DC56: bclr #5,$22(a0) bclr #5,$22(a1) move.w #$B1,d0 jsr (PlaySound_Special).l ; play spring sound </asm> then find: <asm> Obj41_BounceDwn: ; XREF: Obj41_Dwn addq.b #2,$24(a0) subq.w #8,$C(a1) move.w $30(a0),$12(a1) neg.w $12(a1) ; move Sonic downwards bset #1,$22(a1) bclr #3,$22(a1) move.b #2,$24(a1) bclr #3,$22(a0) clr.b $25(a0) move.w #$CC,d0 jsr (PlaySound_Special).l ; play spring sound </asm> and change it to: <asm> Obj41_BounceDwn: ; XREF: Obj41_Dwn addq.b #2,$24(a0) subq.w #8,$C(a1) move.w $30(a0),$12(a1) neg.w $12(a1) ; move Sonic downwards bset #1,$22(a1) bclr #3,$22(a1) move.b #2,$24(a1) bclr #3,$22(a0) clr.b $25(a0) move.w #$B1,d0 jsr (PlaySound_Special).l ; play spring sound </asm> then we will use the MHZ version of this one because it makes sense: <asm> Obj5E_Spring: move.b d1,$3A(a1) move.b d1,$3A(a0) cmp.b $1A(a1),d1 beq.s loc_1192C bclr #3,$22(a1) beq.s loc_1192C clr.b $25(a1) move.b #2,$24(a1) lea ($FFFFD000).w,a2 move.w $12(a0),$12(a2) neg.w $12(a2) bset #1,$22(a2) bclr #3,$22(a2) clr.b $3C(a2) move.b #$10,$1C(a2) ; change Sonic"s animation to "spring" ($10) move.b #2,$24(a2) move.w #$CC,d0 jsr (PlaySound_Special).l ; play spring sound </asm> which gets changed to: <asm> Obj5E_Spring: move.b d1,$3A(a1) move.b d1,$3A(a0) cmp.b $1A(a1),d1 beq.s loc_1192C bclr #3,$22(a1) beq.s loc_1192C clr.b $25(a1) move.b #2,$24(a1) lea ($FFFFD000).w,a2 move.w $12(a0),$12(a2) neg.w $12(a2) bset #1,$22(a2) bclr #3,$22(a2) clr.b $3C(a2) move.b #$10,$1C(a2) ; change Sonic"s animation to "spring" ($10) move.b #2,$24(a2) move.w #$AE,d0 jsr (PlaySound_Special).l ; play spring sound </asm>

Sound $CD

Find: <asm> loc_BDC8: tst.b (a3) bne.s loc_BDD6 move.w #$CD,d0 jsr (PlaySound_Special).l ; play switch sound </asm> and change it to: <asm> loc_BDC8: tst.b (a3) bne.s loc_BDD6 move.w #$5B,d0 jsr (PlaySound_Special).l ; play switch sound </asm> then find: <asm> Obj3A_AddBonus: ; XREF: Obj3A_ChkBonus jsr (AddPoints).l move.b ($FFFFFE0F).w,d0 andi.b #3,d0 bne.s locret_C692 move.w #$CD,d0 jmp (PlaySound_Special).l ; play "blip" sound </asm> and change it to: <asm> Obj3A_AddBonus: ; XREF: Obj3A_ChkBonus jsr (AddPoints).l move.b ($FFFFFE0F).w,d0 andi.b #3,d0 bne.s locret_C692 move.w #$5B,d0 jmp (PlaySound_Special).l ; play "blip" sound </asm> then find: <asm> Obj7E_RingBonus: ; XREF: Obj7E_Index bsr.w DisplaySprite move.b #1,($FFFFF7D6).w ; set ring bonus update flag tst.w ($FFFFF7D4).w ; is ring bonus = zero? beq.s loc_C8C4 ; if yes, branch subi.w #10,($FFFFF7D4).w ; subtract 10 from ring bonus moveq #10,d0 ; add 10 to score jsr (AddPoints).l move.b ($FFFFFE0F).w,d0 andi.b #3,d0 bne.s locret_C8EA move.w #$CD,d0 jmp (PlaySound_Special).l ; play "blip" sound </asm> and change it to: <asm> Obj7E_RingBonus: ; XREF: Obj7E_Index bsr.w DisplaySprite move.b #1,($FFFFF7D6).w ; set ring bonus update flag tst.w ($FFFFF7D4).w ; is ring bonus = zero? beq.s loc_C8C4 ; if yes, branch subi.w #10,($FFFFF7D4).w ; subtract 10 from ring bonus moveq #10,d0 ; add 10 to score jsr (AddPoints).l move.b ($FFFFFE0F).w,d0 andi.b #3,d0 bne.s locret_C8EA move.w #$5B,d0 jmp (PlaySound_Special).l ; play "blip" sound </asm>

Sound $CE

This sound's usage was defined in the old 68k driver and fixes itself.

Sound $CF

The old sound for the end sign is no longer in Sonic 3, but a similar (unused) sound does exist, so find: <asm> Obj0D_Touch: ; XREF: Obj0D_Index move.w ($FFFFD008).w,d0 sub.w 8(a0),d0 bcs.s locret_EBBA cmpi.w #$20,d0 ; is Sonic within $20 pixels of the signpost? bcc.s locret_EBBA ; if not, branch move.w #$CF,d0 jsr (PlaySound).l ; play signpost sound clr.b ($FFFFFE1E).w ; stop time counter move.w ($FFFFF72A).w,($FFFFF728).w ; lock screen position addq.b #2,$24(a0) </asm> and change it to: <asm> Obj0D_Touch: ; XREF: Obj0D_Index move.w ($FFFFD008).w,d0 sub.w 8(a0),d0 bcs.s locret_EBBA cmpi.w #$20,d0 ; is Sonic within $20 pixels of the signpost? bcc.s locret_EBBA ; if not, branch move.w #$5E,d0 jsr (PlaySound).l ; play signpost sound clr.b ($FFFFFE1E).w ; stop time counter move.w ($FFFFF72A).w,($FFFFF728).w ; lock screen position addq.b #2,$24(a0) </asm>

Sound $D0

This one is the hard one, Sonic 1's timing of the waterfalls is not right, so the water sound will have pauses in it. I will look into it and update the code when I get it working right.
for now, find: <asm> loc_3F9A: clr.b $15(a1) move.b #$1B,$1C(a1) ; use Sonic"s "sliding" animation move.b #1,($FFFFF7CA).w ; lock controls (except jumping) move.b ($FFFFFE0F).w,d0 andi.b #$1F,d0 bne.s locret_3FBE move.w #$D0,d0 jsr (PlaySound_Special).l ; play water sound </asm> and change it to: <asm> loc_3F9A: clr.b $15(a1) move.b #$1B,$1C(a1) ; use Sonic"s "sliding" animation move.b #1,($FFFFF7CA).w ; lock controls (except jumping) move.b ($FFFFFE0F).w,d0 andi.b #$1F,d0 bne.s locret_3FBE move.w #$DB,d0 jsr (PlaySound_Special).l ; play water sound </asm> then find: <asm> Obj49_PlaySnd: ; XREF: Obj49_Index move.b ($FFFFFE0F).w,d0 andi.b #$3F,d0 bne.s Obj49_ChkDel move.w #$D0,d0 jsr (PlaySound_Special).l ; play waterfall sound </asm> and change it to: <asm> Obj49_PlaySnd: ; XREF: Obj49_Index move.b ($FFFFFE0F).w,d0 andi.b #$3F,d0 bne.s Obj49_ChkDel move.w #$DB,d0 jsr (PlaySound_Special).l ; play waterfall sound </asm> then find: <asm> LZWind_Loop: move.w 8(a1),d0 cmp.w (a2),d0 bcs.w loc_3EF4 cmp.w 4(a2),d0 bcc.w loc_3EF4 move.w $C(a1),d2 cmp.w 2(a2),d2 bcs.s loc_3EF4 cmp.w 6(a2),d2 bcc.s loc_3EF4 move.b ($FFFFFE0F).w,d0 andi.b #$3F,d0 bne.s loc_3E90 move.w #$D0,d0 jsr (PlaySound_Special).l ; play rushing water sound </asm> and change it to: <asm> LZWind_Loop: move.w 8(a1),d0 cmp.w (a2),d0 bcs.w loc_3EF4 cmp.w 4(a2),d0 bcc.w loc_3EF4 move.w $C(a1),d2 cmp.w 2(a2),d2 bcs.s loc_3EF4 cmp.w 6(a2),d2 bcc.s loc_3EF4 move.b ($FFFFFE0F).w,d0 andi.b #$3F,d0 bne.s loc_3E90 move.w #$DB,d0 jsr (PlaySound_Special).l ; play rushing water sound </asm>

Now all that is left, is fixing the level select so that it plays the data select music upon entry and allows selection of sounds $00 - $FF.

Utilizing new sounds in existing badniks

here, we delve a little into object editing and how to effectively use the Sonic 3 sound system, because you have already decided to use it, right? Well, if you hadn't, then why are you here?
Using sounds in Sonic 3 is very similar to older games, just the sound numbers are changed thus why the strange stuff you may have encountered earlier and why you will have to fix the Level Select later. here is how the sounds line up:

Type Numbers in Sonic 1/Sonic 2 Numbers in Sonic 3+
Broken/Error $00 - $7F N/A
Emty/Null $80 $00
Music $81 - $9F $01 - $32
Sound Effects/Control $A0 - $FF $33 - $FF

As you probably had noticed if you actually had a brain, the sound effects are in a larger range that encompassed the entire old range of sounds, music included, which would explain why the game would have sounded drunk when you first got the driver working and chose to test it before continuing this tutorial.

Buzz Bomber

The buzz bomber fires at sonic, and most enemies in Sonic 3 tend to make a certain sound when they fire at sonic, so lets add that one to the buzz bomber, so why don't we locate the firing routine: <asm> loc_98AA: add.w d0,8(a1) move.b $22(a0),$22(a1) move.w #$E,$32(a1) move.l a0,$3C(a1) move.b #1,$34(a0) ; set to "already fired" to pralign 2t refiring move.w #$3B,$32(a0) move.b #2,$1C(a0) ; use "firing" animation </asm> and add these lines right under it: <asm> move.w #$4D,d0 jmp PlaySound ; play firing sound </asm>

Now our buzz bomber has sound!

Crabmeat

The Crabmeat badnik can have a sound too, if we add it in a similar manner, so lets do it! Crabmeat throws something with both claws, but so does Monkey Dude in AIZ, so lets use that sound. Lets find the Crabmeat throwing routine: <asm> Obj1F_MakeFire: ; XREF: Obj1F_WaitFire move.w #$3B,$30(a0) move.b #6,$1C(a0) ; use firing animation bsr.w SingleObjLoad bne.s Obj1F_MakeFire2 _move.b #$1F,0(a1) ; load left fireball move.b #6,$24(a1) move.w 8(a0),8(a1) subi.w #$10,8(a1) move.w $C(a0),$C(a1) move.w #-$100,$10(a1)

Obj1F_MakeFire2: bsr.w SingleObjLoad bne.s locret_9618 _move.b #$1F,0(a1) ; load right fireball move.b #6,$24(a1) move.w 8(a0),8(a1) addi.w #$10,8(a1) move.w $C(a0),$C(a1) move.w #$100,$10(a1) </asm> Two throwing routines? Of course, one for each claw, so we will have to update them both: <asm> Obj1F_MakeFire: ; XREF: Obj1F_WaitFire move.w #$3B,$30(a0) move.b #6,$1C(a0) ; use firing animation bsr.w SingleObjLoad bne.s Obj1F_MakeFire2 _move.b #$1F,0(a1) ; load left fireball move.b #6,$24(a1) move.w 8(a0),8(a1) subi.w #$10,8(a1) move.w $C(a0),$C(a1) move.w #-$100,$10(a1) move.b #$51,d0 jsr PlaySound ;play throwing sound

Obj1F_MakeFire2: bsr.w SingleObjLoad bne.s locret_9618 _move.b #$1F,0(a1) ; load right fireball move.b #6,$24(a1) move.w 8(a0),8(a1) addi.w #$10,8(a1) move.w $C(a0),$C(a1) move.w #$100,$10(a1) move.b #$51,d0 jsr PlaySound ;play throwing sound </asm> Finally, an audiable Crabmeat.

Orbinaught

Looks like this one can have sound too, it also throws something at sonic, so lets locate the firing/throwing routine: <asm> Obj60_FireOrb: move.w #-$200,$10(a0) ; move orb to the left (quickly) btst #0,$22(a1) beq.s Obj60_Display2 neg.w $10(a0) </asm> What? There is only one, when the last had two? Yes, that is right, the same routine is used four times, so just simply add these lines after what is above: <asm> move.b #$51,d0 jsr PlaySound ;play throwing sound </asm>

Ball Hog

Ball Hog also can have sound added, so lets find the throwing routine: <asm> loc_8C0A: add.w d0,8(a1) addi.w #$C,$C(a1) move.b $28(a0),$28(a1) ; copy object type from Ball Hog </asm> and add after it: <asm> move.b #$51,d0 jsr PlaySound ;play throwing sound </asm>

Fixing the sound test on the level select

Now, we'll fix the level select to suit the Sonic 3 driver.

Music upon entry of level select

Optionally, you can do what Sonic 2 Beta (Simon Wai to Beta 5) does and play music upon entering the Level Select. If you'd rather not do it, skip this step.

Locate: <asm> LevelSelect: move.b #4,($FFFFF62A).w bsr.w DelayProgram bsr.w LevSelControls bsr.w RunPLC_RAM tst.l ($FFFFF680).w bne.s LevelSelect andi.b #$F0,($FFFFF605).w ; is A, B, C, or Start pressed? beq.s LevelSelect ; if not, branch move.w ($FFFFFF82).w,d0 cmpi.w #$14,d0 ; have you selected item $14 (sound test)? bne.s LevSel_Level_SS ; if not, go to Level/SS subroutine move.w ($FFFFFF84).w,d0 addi.w #$80,d0 tst.b ($FFFFFFE3).w ; is Japanese Credits cheat on? beq.s LevSel_NoCheat ; if not, branch cmpi.w #$9F,d0 ; is sound $9F being played? beq.s LevSel_Ending ; if yes, branch cmpi.w #$9E,d0 ; is sound $9E being played? beq.s LevSel_Credits ; if yes, branch </asm> and add before the label: <asm> move.w #$2F,d0 jsr PlaySound </asm>

The result should look like this: <asm> bsr.w LevSelTextLoad move.w #$2F,d0 jsr PlaySound

---------------------------------------------------------------------------
Level Select
---------------------------------------------------------------------------

LevelSelect: move.b #4,($FFFFF62A).w bsr.w DelayProgram bsr.w LevSelControls bsr.w RunPLC_RAM tst.l ($FFFFF680).w bne.s LevelSelect andi.b #$F0,($FFFFF605).w ; is A, B, C, or Start pressed? beq.s LevelSelect ; if not, branch move.w ($FFFFFF82).w,d0 cmpi.w #$14,d0 ; have you selected item $14 (sound test)? bne.s LevSel_Level_SS ; if not, go to Level/SS subroutine move.w ($FFFFFF84).w,d0 addi.w #$80,d0 tst.b ($FFFFFFE3).w ; is Japanese Credits cheat on? beq.s LevSel_NoCheat ; if not, branch cmpi.w #$9F,d0 ; is sound $9F being played? beq.s LevSel_Ending ; if yes, branch cmpi.w #$9E,d0 ; is sound $9E being played? beq.s LevSel_Credits ; if yes, branch </asm>

fixing the sound test

Okay, there is a lot that needs fixing here, the Sound Test seems to be set up for the old driver not the new one, first off lets look at part 1 of the level select code: <asm> LevelSelect: move.b #4,($FFFFF62A).w bsr.w DelayProgram bsr.w LevSelControls bsr.w RunPLC_RAM tst.l ($FFFFF680).w bne.s LevelSelect andi.b #$F0,($FFFFF605).w ; is A, B, C, or Start pressed? beq.s LevelSelect ; if not, branch move.w ($FFFFFF82).w,d0 cmpi.w #$14,d0 ; have you selected item $14 (sound test)? bne.s LevSel_Level_SS ; if not, go to Level/SS subroutine move.w ($FFFFFF84).w,d0 addi.w #$80,d0 tst.b ($FFFFFFE3).w ; is Japanese Credits cheat on? beq.s LevSel_NoCheat ; if not, branch cmpi.w #$9F,d0 ; is sound $9F being played? beq.s LevSel_Ending ; if yes, branch cmpi.w #$9E,d0 ; is sound $9E being played? beq.s LevSel_Credits ; if yes, branch

LevSel_NoCheat: cmpi.w #$94,d0 ; is sound $80-$94 being played? bcs.s LevSel_PlaySnd ; if yes, branch cmpi.w #$A0,d0 ; is sound $95-$A0 being played? bcs.s LevelSelect ; if yes, branch

LevSel_PlaySnd: bsr.w PlaySound_Special bra.s LevelSelect

===========================================================================

LevSel_Ending: ; XREF: LevelSelect move.b #$18,($FFFFF600).w ; set screen mode to $18 (Ending) move.w #$600,($FFFFFE10).w ; set level to 0600 (Ending) rts

===========================================================================

LevSel_Credits: ; XREF: LevelSelect move.b #$1C,($FFFFF600).w ; set screen mode to $1C (Credits) move.b #$26,d0 bsr.w PlaySound_Special ; play credits music move.w #0,($FFFFFFF4).w rts

===========================================================================

LevSel_Level_SS: ; XREF: LevelSelect add.w d0,d0 move.w LSelectPointers(pc,d0.w),d0 ; load level number bmi.w LevelSelect cmpi.w #$700,d0 ; check if level is 0700 (Special Stage) bne.s LevSel_Level ; if not, branch move.b #$10,($FFFFF600).w ; set screen mode to $10 (Special Stage) clr.w ($FFFFFE10).w ; clear level move.b #3,($FFFFFE12).w ; set lives to 3 moveq #0,d0 move.w d0,($FFFFFE20).w ; clear rings move.l d0,($FFFFFE22).w ; clear time move.l d0,($FFFFFE26).w ; clear score rts

===========================================================================

LevSel_Level: ; XREF: LevSel_Level_SS andi.w #$3FFF,d0 move.w d0,($FFFFFE10).w ; set level number

PlayLevel: ; XREF: ROM:00003246?j ... move.b #$C,($FFFFF600).w ; set screen mode to $0C (level) move.b #3,($FFFFFE12).w ; set lives to 3 moveq #0,d0 move.w d0,($FFFFFE20).w ; clear rings move.l d0,($FFFFFE22).w ; clear time move.l d0,($FFFFFE26).w ; clear score move.b d0,($FFFFFE16).w ; clear special stage number move.b d0,($FFFFFE57).w ; clear emeralds move.l d0,($FFFFFE58).w ; clear emeralds move.l d0,($FFFFFE5C).w ; clear emeralds move.b d0,($FFFFFE18).w ; clear continues move.b #$E1,d0 bsr.w PlaySound_Special ; fade out music rts

===========================================================================
---------------------------------------------------------------------------
Level select - level pointers
---------------------------------------------------------------------------

LSelectPointers: incbin misc/ls_point.bin align 2 </asm> Since the Japanese Credits Easter Egg is in no need of use, we'll remove it. We're also going to fix the gaps in the Sound Test too. <asm> LevelSelect: move.b #4,($FFFFF62A).w bsr.w DelayProgram bsr.w LevSelControls bsr.w RunPLC_RAM tst.l ($FFFFF680).w bne.s LevelSelect andi.b #$F0,($FFFFF605).w ; is A, B, C, or Start pressed? beq.s LevelSelect ; if not, branch move.w ($FFFFFF82).w,d0 cmpi.w #$14,d0 ; have you selected item $14 (sound test)? bne.s LevSel_Level_SS ; if not, go to Level/SS subroutine move.w ($FFFFFF84).w,d0 bsr.w PlaySound_Special bra.s LevelSelect

===========================================================================

LevSel_Level_SS: ; XREF: LevelSelect add.w d0,d0 move.w LSelectPointers(pc,d0.w),d0 ; load level number bmi.w LevelSelect cmpi.w #$700,d0 ; check if level is 0700 (Special Stage) bne.s LevSel_Level ; if not, branch move.b #$10,($FFFFF600).w ; set screen mode to $10 (Special Stage) clr.w ($FFFFFE10).w ; clear level move.b #3,($FFFFFE12).w ; set lives to 3 moveq #0,d0 move.w d0,($FFFFFE20).w ; clear rings move.l d0,($FFFFFE22).w ; clear time move.l d0,($FFFFFE26).w ; clear score rts

===========================================================================

LevSel_Level: ; XREF: LevSel_Level_SS andi.w #$3FFF,d0 move.w d0,($FFFFFE10).w ; set level number

PlayLevel: ; XREF: ROM:00003246?j ... move.b #$C,($FFFFF600).w ; set screen mode to $0C (level) move.b #3,($FFFFFE12).w ; set lives to 3 moveq #0,d0 move.w d0,($FFFFFE20).w ; clear rings move.l d0,($FFFFFE22).w ; clear time move.l d0,($FFFFFE26).w ; clear score move.b d0,($FFFFFE16).w ; clear special stage number move.b d0,($FFFFFE57).w ; clear emeralds move.l d0,($FFFFFE58).w ; clear emeralds move.l d0,($FFFFFE5C).w ; clear emeralds move.b d0,($FFFFFE18).w ; clear continues move.b #$E1,d0 bsr.w PlaySound_Special ; fade out music rts

===========================================================================
---------------------------------------------------------------------------
Level select - level pointers
---------------------------------------------------------------------------

LSelectPointers: incbin misc/ls_point.bin align 2 </asm> Now lets look at the next part of the level select: <asm> LevSelControls: ; XREF: LevelSelect move.b ($FFFFF605).w,d1 andi.b #3,d1 ; is up/down pressed and held? bne.s LevSel_UpDown ; if yes, branch subq.w #1,($FFFFFF80).w ; subtract 1 from time to next move bpl.s LevSel_SndTest ; if time remains, branch

LevSel_UpDown: move.w #$B,($FFFFFF80).w ; reset time delay move.b ($FFFFF604).w,d1 andi.b #3,d1 ; is up/down pressed? beq.s LevSel_SndTest ; if not, branch move.w ($FFFFFF82).w,d0 btst #0,d1 ; is up pressed? beq.s LevSel_Down ; if not, branch subq.w #1,d0 ; move up 1 selection bcc.s LevSel_Down moveq #$14,d0 ; if selection moves below 0, jump to selection $14

LevSel_Down: btst #1,d1 ; is down pressed? beq.s LevSel_Refresh ; if not, branch addq.w #1,d0 ; move down 1 selection cmpi.w #$15,d0 bcs.s LevSel_Refresh moveq #0,d0 ; if selection moves above $14, jump to selection 0

LevSel_Refresh: move.w d0,($FFFFFF82).w ; set new selection bsr.w LevSelTextLoad ; refresh text rts

===========================================================================

LevSel_SndTest: ; XREF: LevSelControls cmpi.w #$14,($FFFFFF82).w ; is item $14 selected? bne.s LevSel_NoMove ; if not, branch move.b ($FFFFF605).w,d1 andi.b #$C,d1 ; is left/right pressed? beq.s LevSel_NoMove ; if not, branch move.w ($FFFFFF84).w,d0 btst #2,d1 ; is left pressed? beq.s LevSel_Right ; if not, branch subq.w #1,d0 ; subtract 1 from sound test bcc.s LevSel_Right moveq #$4F,d0 ; if sound test moves below 0, set to $4F

LevSel_Right: btst #3,d1 ; is right pressed? beq.s LevSel_Refresh2 ; if not, branch addq.w #1,d0 ; add 1 to sound test cmpi.w #$50,d0 bcs.s LevSel_Refresh2 moveq #0,d0 ; if sound test moves above $4F, set to 0

LevSel_Refresh2: move.w d0,($FFFFFF84).w ; set sound test number bsr.w LevSelTextLoad ; refresh text

LevSel_NoMove: rts </asm> Seems that we have now located the code that limits the level select to $80 - $CF, so we fix it: <asm> LevSelControls: ; XREF: LevelSelect move.b ($FFFFF605).w,d1 andi.b #3,d1 ; is up/down pressed and held? bne.s LevSel_UpDown ; if yes, branch subq.w #1,($FFFFFF80).w ; subtract 1 from time to next move bpl.s LevSel_SndTest ; if time remains, branch

LevSel_UpDown: move.w #$B,($FFFFFF80).w ; reset time delay move.b ($FFFFF604).w,d1 andi.b #3,d1 ; is up/down pressed? beq.s LevSel_SndTest ; if not, branch move.w ($FFFFFF82).w,d0 btst #0,d1 ; is up pressed? beq.s LevSel_Down ; if not, branch subq.w #1,d0 ; move up 1 selection bcc.s LevSel_Down moveq #$14,d0 ; if selection moves below 0, jump to selection $14

LevSel_Down: btst #1,d1 ; is down pressed? beq.s LevSel_Refresh ; if not, branch addq.w #1,d0 ; move down 1 selection cmpi.w #$15,d0 bcs.s LevSel_Refresh moveq #0,d0 ; if selection moves above $14, jump to selection 0

LevSel_Refresh: move.w d0,($FFFFFF82).w ; set new selection bsr.w LevSelTextLoad ; refresh text rts

===========================================================================

LevSel_SndTest: ; XREF: LevSelControls cmpi.w #$14,($FFFFFF82).w ; is item $14 selected? bne.s LevSel_NoMove ; if not, branch move.b ($FFFFF605).w,d1 andi.b #$C,d1 ; is left/right pressed? beq.s LevSel_NoMove ; if not, branch move.w ($FFFFFF84).w,d0 btst #2,d1 ; is left pressed? beq.s LevSel_Right ; if not, branch subq.w #1,d0 ; subtract 1 from sound test bcc.s LevSel_Right moveq #$FF,d0 ; if sound test moves below 0, set to $4F

LevSel_Right: btst #3,d1 ; is right pressed? beq.s LevSel_Refresh2 ; if not, branch addq.w #1,d0 ; add 1 to sound test cmpi.w #$100,d0 bcs.s LevSel_Refresh2 moveq #0,d0 ; if sound test moves above $4F, set to 0

LevSel_Refresh2: move.w d0,($FFFFFF84).w ; set sound test number bsr.w LevSelTextLoad ; refresh text

LevSel_NoMove: rts </asm> Thought it was fixed already? Well even though it works right, the display is still wrong, so we need to fix it. so lets go to: <asm> loc_3550: move.l #$6C300003,($C00004).l ; screen position (sound test) move.w ($FFFFFF84).w,d0 addi.w #$80,d0 move.b d0,d2 lsr.b #4,d0 bsr.w LevSel_ChgSnd move.b d2,d0 bsr.w LevSel_ChgSnd rts </asm> and remove this line: <asm> addi.w #$80,d0 </asm> I hope you make good use of this driver and make many great hacks.

Credits

I give credit where it is due:

  • Esrael for the original port of the Sonic 3 Driver to Sonic 2 Beta, which I fixed up.
  • Tornado for the original guide on SSRG
  • Selbi for posting info on most of, but not all the sound test values which I had to finish.
SCHG How-To Guide: Sonic the Hedgehog (16-bit)
Fixing Bugs
Fix Demo Playback | Fix a Race Condition with Pattern Load Cues | Fix the SEGA Sound | Display the Press Start Button Text | Fix the Level Select Menu | Fix the Hidden Points Bug | Fix Accidental Deletion of Scattered Rings | Fix Ring Timers | Fix the Walk-Jump Bug | Correct Drowning Bugs | Fix the Death Boundary Bug | Fix the Camera Follow Bug | Fix Song Restoration Bugs | Fix the HUD Blinking | Fix the Level Select Graphics Bug | Fix a remember sprite related bug
Changing Design Choices
Change Spike Behavior | Collide with Water After Being Hurt | Fix Special Stage Jumping Physics | Improve the Fade In\Fade Out Progression Routines | Fix Scattered Rings' Underwater Physics | Remove the Speed Cap | Port the REV01 Background Effects | Port Sonic 2's Level Art Loader | Retain Rings Between Acts | Add Sonic 2 (Simon Wai Prototype) Level Select | Improve ObjectMove Subroutines | Port Sonic 2 Level Select
Adding Features
Add Spin Dash ( Part 1 / Part 2 / Part 3 / Part 4 ) | Add Eggman Monitor | Add Super Sonic | Add the Air Roll
Sound Features
Expand the Sound Index | Play Different Songs Per Act | Port Sonic 2 Final Sound Driver | Port Sonic 3's Sound Driver | Port Flamewing's Sonic 3 & Knuckles Sound Driver | Change The SEGA Sound
Extending the Game
Load Chunks From ROM | Add Extra Characters | Make an Alternative Title Screen | Use Dynamic Tilesets | Make GHZ Load Alternate Art | Make Ending Load Alternate Art | Add a New Zone | Set Up the Goggle Monitor | Add New Moves | Add a Dynamic Collision System | Dynamic Special Stage Walls System | Extend Sprite Mappings and Art Limit | Enigma Credits | Use Dynamic Palettes
Miscellaneous
Convert the Hivebrain 2005 Disassembly to ASM68K
Split Disassembly Guides
Set Up a Split Disassembly | Basic Level Editing | Basic Art Editing | Basic ASM Editing (Spin Dash)