Game: F1 (Europe), Formula One (US)
Publisher: Domark
Developer: Lankhor
Composer: Tiertex
This one has some extra gain, but I have another archive at the original volume at hand just in case.
Special thanks to ValleyBell for telling me where to edit the ROM to handle music playback.
New set: F1
-
- New Around Here
- Posts: 9
- Joined: Sun May 01, 2016 10:55 pm
New set: F1
You do not have the required permissions to view the files attached to this post.
-
- Board Regular
- Posts: 128
- Joined: Mon Aug 30, 2010 7:10 am
So, let me post some hacking information.
We're looking at "F1 World Championship (E) [!].bin" and "F1 World Championship (U) [!].bin" (GoodGen names). Note that "F1 World Championship Edition" is a different game. We're talking about F1 / Formula One.
Music is played using this code:
The song ID is passed in register D0.
Both versions of the ROM (E and U) have Sound API calls at the same addresses.
0032F2 plays a song (song ID in D0, 00 - stop music, 01..04 - play song, 05 - invalid)
0032F6 play a sound effect? (not referenced by the game - there are no menu SFX, takes a 2-byte value in D0)
0032FA controls the music volume (volume in D0, mode in D1, the game always uses mode 00/volume F0)
0032FE pause music
003302 resume music
Racing effects are handled by a separate Z80 sound driver.
Now let's have some "useful" stuff. Disassembly offsets are for the (E) version.
For the menu music, it cycles through 3 songs (1, 3 and 4). The current menu song number for the look-up-table is stored at RAM offset E382/83.
Now let's summarize the important offsets:
We're looking at "F1 World Championship (E) [!].bin" and "F1 World Championship (U) [!].bin" (GoodGen names). Note that "F1 World Championship Edition" is a different game. We're talking about F1 / Formula One.
Music is played using this code:
Code: Select all
4EB9 0000 32F2 jsr $32F2.l
Both versions of the ROM (E and U) have Sound API calls at the same addresses.
0032F2 plays a song (song ID in D0, 00 - stop music, 01..04 - play song, 05 - invalid)
0032F6 play a sound effect? (not referenced by the game - there are no menu SFX, takes a 2-byte value in D0)
0032FA controls the music volume (volume in D0, mode in D1, the game always uses mode 00/volume F0)
0032FE pause music
003302 resume music
Racing effects are handled by a separate Z80 sound driver.
Now let's have some "useful" stuff. Disassembly offsets are for the (E) version.
Code: Select all
play title theme:
0D52BE 303C 0002 MOVE.W #2, D0 ; D0 = song 2
0D52C2 4EB9 0000 32F2 JSR $0032F2.l ; call PlayMusic
play menu music:
0D79AA 3039 00FF E382 MOVE.W $FFE382.l, D0 ; get menu music number
...
0D79C0 103B 00C6 MOVE.B -$3A(PC,D0.w), D0 ; get song ID from table at 0D7988
0D79C4 4EB9 0000 32F2 JSR $0032F2.l ; call PlayMusic
For the menu music, it cycles through 3 songs (1, 3 and 4). The current menu song number for the look-up-table is stored at RAM offset E382/83.
Now let's summarize the important offsets:
Code: Select all
EU US Description
0032F2 0032F2 offset for PlayMusic call
0D52C1 0D5639 song ID for the title screen
0D7988 0D7DDA look-up-table for menu songs