I'd like to put the music and sound effects for FamiTone into different banks because one bank will probably not be enough for my new soundtrack and I don't want to mirror the sound effects in every music bank.
Since I don't know much about music drivers, I need to ask:
Is it a mundane issue to switch the bank in the FamiToneUpdate function because processing music and processing sound effects are clearly separated?
Or would this be more complicated because variables that point to music and sound are used in a mix?
For example, at the start of the FamiToneUpdate function there's this piece of code:
So, would it be enough to switch to the sound bank right before the actual @update_sound: label? (The music bank is of course already set before the function gets called.)
Or wouldn't this work because variables that point into the music ROM are still referred after @update_sound:?
Since I don't know much about music drivers, I need to ask:
Is it a mundane issue to switch the bank in the FamiToneUpdate function because processing music and processing sound effects are clearly separated?
Or would this be more complicated because variables that point to music and sound are used in a mix?
For example, at the start of the FamiToneUpdate function there's this piece of code:
Code:
lda FT_SONG_SPEED ;speed 0 means that no music is playing currently
bmi @pause ;bit 7 set is the pause flag
bne @update
@pause:
jmp @update_sound
@update:
bmi @pause ;bit 7 set is the pause flag
bne @update
@pause:
jmp @update_sound
@update:
So, would it be enough to switch to the sound bank right before the actual @update_sound: label? (The music bank is of course already set before the function gets called.)
Or wouldn't this work because variables that point into the music ROM are still referred after @update_sound:?