-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Change the song the Etecoons sing #593
Comments
Okay, all the RAM addresses shown in that disassembly are locations in the SPC engine itself, not locations in the main SNES RAM. That means we can't easily expand the instruction list for this sound effect and will have to squeeze ourselves into the space between the The instruction list starts with a pointer for each voice the sound effects use (the vanilla song uses only one) and each voice must end with a terminator of |
Other ROM locations:
This suggests that editing the location 0x279709 to have the value 0x3F9F (little-endian) and reloading (and hard-resetting) the game will replace the uncharged power beam sound effect with the Etecoon song. |
I should find a better way to write this out:
Edit: Apparently $48 is C-7, so the above note labels might be three octaves and one semitone lower than what actually plays. As long as they agree with each other in key and sound similar in octave to the original theme, we're probably fine. |
Here it is again with an ADSR envelope so we don't need the reverb notes and can maybe pack in a second voice:
|
For testing two voices with the uncharged power beam shot, alter address 0x279674 from $AB to $C1. This will screw up a bunch of other sound effects, so change it back as soon as you're done. With this, though, the SMB1 theme gets a bassline:
|
I played down to Hell so I could hear it with the real sample and it seems like we don't really need the ADSR after all. The lead voice did better with a slight boost over the bassline, so here's what I ended up with:
This sounds good enough to me to slip in as a weird Easter egg. We can add randomness in the following release. |
Change the Etecoons' song to SMB1. Closes #593
Bear with me on this one.
The song the Etecoons sing in the room called "Hell" is identified here as sound 0x35 in sound library 2. That sound effect is shown in this disassembly as a series of twelve staccato, reverberating notes, followed by a single sustained note.
There's a whole lot of free space in that bank. We could maybe program in a different song, then modify the pointer to that sound effect to point at it. We could program in a couple of songs and point at one of them when the ROM is generated. It's probably too much to let users define songs in the YAML, but first things first.
Try the intro to the first music you hear in Super Mario Bros and see what happens! Step one will be to figure out where this table lives in the ROM and point sound 0x35 at a different sound effect. It looks like the table starts at $39B3, minus an offset of $1500 that was added by the disassembly, plus an offset of $CF8104, where the SPC engine is written to the ROM. (This suggests that the table starts at $CFA5B7 and the 0x35th entry would be an additional 0x34 words (0x68 bytes) on, at $CFA61F.)
The text was updated successfully, but these errors were encountered: