Music Insertion with AddmusicK
Table of contents:
- Introduction
- Requirements
- Music Insertion
- Adding the music into the levels/Overworld
- Frequently Asked Questions
Introduction
In this tutorial I pretend to teach you how to insert custom music into your ROM, using of AddmusicK.
If you are one of these people that refuse to chnage, you might be wondering, "Well, what does it do better than Addmusic 4.05/M?". If that's the case, then I tell you:
If you are one of these people that refuse to chnage, you might be wondering, "Well, what does it do better than Addmusic 4.05/M?". If that's the case, then I tell you:
- 100% real hardware and emulator compatibility.
- Graphical User interface, in case you don't like/fear using the command line.
- Compatibility with Addmusic 4.05 and M music formats.
- SA-1 compatibility.
- More commands that allow for better sonding music.
- Frees one SFX bank, by moving the jump SFX to $1DFC.
- No header dilemma, so you can play OW music on levels and viceversa!
- (For porters) Ability to generate .spc files without inserting the song to your ROM via the "Porter Mode" as well as a directive to add SPC tags without having to use another program.
- (For SPC hackers) Easy to modify 65816 and SPC ASM.
And what do I need?
Well, not much, really:
- The latest version of AddmusicK
- A Super Mario World ROM, preferrably without code from other Addmusics.
- Custom music of your choice.
- If you plan to use the GUI instead of the command line, .NET Framework.
- A bit of patience.
Well, how do I insert my music, then?
First Steps
The first step that you need to before inserting any song is, of course, downloading it. Once you have done it, open the zip and extract the .txt file (not the spc, not the brr, just the txt) on the music folder.


Not too much to say, really.
Sampled Songs
If your song uses samples, then you have to do some extra steps:

- Open the .txt file.
- Search for a line that says #path FolderName. If one doesn't exist, then you can put the samples in the samples folder. If there is one, then put the samples on samples/FolderName instead.

The #path directive. Now you can have clean folders!
Sample Groups
If your song includes an Addmusic_sample groups.txt file as well, then you'll have to perform the following steps

After doing that, open the Addmusic_list.txt file and go the end of the file. Add a new line, and type a number (in hex) from 29 to FD, followed by one or two spaces, and the name of the song.

Now, from here on, you can either open the command line (AddmusicK.exe) or the GUI (AMKGUI.exe).
- Open the Addmusic_sample groups.txt that came with your song, and copy its contents.
- Open the Addmusic_sample groups.txt that comes with AddmusicK, scroll to the bottom, and in a new line copy its contents.

Sample groups allow for a different set of samples to be inserted, be original or custom.
After doing that, open the Addmusic_list.txt file and go the end of the file. Add a new line, and type a number (in hex) from 29 to FD, followed by one or two spaces, and the name of the song.

You can put songs inside a folder too.
Now, from here on, you can either open the command line (AddmusicK.exe) or the GUI (AMKGUI.exe).
Using the command line
Simply double click AddmusicK.exe, then type your ROM name.
Press Enter, and if you did everything right, then you should see a line saying "Sucess!". Not too hard, right?

Press Enter, and if you did everything right, then you should see a line saying "Sucess!". Not too hard, right?

You're winner! Some people think the command line is scary, but it's not.
Using the GUI
Open AMKGUI.exe. Here, you can see a lot of useful options, including the ability to add songs directly without modifying the Addmusic_list file, playing a song without inseting it, or enabling Porter mode (explained at the start).
For now, just click Run, and a window will pop. Search for your ROM file, and the tool will do the rest. It everything goes right, then you will see a window like this:

Also you might've noticed that AddmusicK generates a .msc file. Don't worry about it, what this file does is showing the names of the songs when on the Bypass music dialog.
For now, just click Run, and a window will pop. Search for your ROM file, and the tool will do the rest. It everything goes right, then you will see a window like this:

Good. I prefer the command line personally, but this one's neat too.
Also you might've noticed that AddmusicK generates a .msc file. Don't worry about it, what this file does is showing the names of the songs when on the Bypass music dialog.
Cool beans, now how do I put them in my levels/OW?
It's not really hard! Open your ROM in Lunar Magic, and go to the level where you want to add a custom song. Press the Bypass music and time limit settings dialog button (
) and search for the song you inserted. That's where the msc file comes handy, as it'll display the custom song names. Select it, click Ok, and save.

For the Overworld, the process is similar. Click the Edit submap music selection dialog button (
once again), select your map to the left, and the song to your right. Press Ok and save.

Open your emulator. It's time!
If everything went well, you will notice two things:
If everything worked, yay! Now you know how to insert custom music. If for some reason it didn't work, check below to see what could've gone wrong. Or make a post on this thread, and I'll try to help you.


You probably have seen this box already.
For the Overworld, the process is similar. Click the Edit submap music selection dialog button (


Not too different, to be fair.
Open your emulator. It's time!
If everything went well, you will notice two things:
- The music on the intro level changed to the grassland song.
- The song you chose plays correcly on the level.
If everything worked, yay! Now you know how to insert custom music. If for some reason it didn't work, check below to see what could've gone wrong. Or make a post on this thread, and I'll try to help you.
Now it's time for THE FREQUENTLY ASKED QUESTIONS
1. Why does the intro song change to the grassland?
2. I applied a hex edit to change the title screen/intro level, but after reapplying AddmusicK, the changes are lost! What do?
3. How do I change the Nintendo Presents sound? The hex edit ain't doing no thing...
4. Im getting an error that says: ‘Echo buffer exceeded total space in ARAM’. What can I do?
5.- If I beat or die with 100 seconds or less in the timer, the music keeps sped up!
That's because AddmusicK changes the order of the songs, as well as allowing for the intro level to use a custom song.
2. I applied a hex edit to change the title screen/intro level, but after reapplying AddmusicK, the changes are lost! What do?
Go to the asm/SNES folder, open the Tweaks.asm (this is called UserDefines.asm in newer AddMusicK) file in any text editor of your choice. Once there, search for the following lines:
!Welcome = #$13
!Title = #$15
And change the numbers to the song you want to use. Welcome is the intro level, and Title is the titlescreen. Save and reapply AddmusicK.
!Welcome = #$13
!Title = #$15
And change the numbers to the song you want to use. Welcome is the intro level, and Title is the titlescreen. Save and reapply AddmusicK.
3. How do I change the Nintendo Presents sound? The hex edit ain't doing no thing...
AddmusicK modifies the Nintendo Presents song to be a song instead of a sound effect. This means that you have to either:
!NintPresents = #$1E ; Note that this is a song, not a sound effect!
And change the number to the song of your choice. Save and reapply AddmusicK.
For the second choice, search for this on tweaks.asm once again:
org $0093C0
LDA.b !NintPresents
STA $1DFB|!SA1Addr2
Change the $1DFB to the SFX mirror of your choice. You can find these, along with the sound effect numbers, here. Once you did that, you can follow the steps from step 1, taking into account that !NintPresents is a sound effect number instead.
- Use a song or convert your SFX to one
- Change the SFX mirror to allow a sound effect.
!NintPresents = #$1E ; Note that this is a song, not a sound effect!
And change the number to the song of your choice. Save and reapply AddmusicK.
For the second choice, search for this on tweaks.asm once again:
org $0093C0
LDA.b !NintPresents
STA $1DFB|!SA1Addr2
Change the $1DFB to the SFX mirror of your choice. You can find these, along with the sound effect numbers, here. Once you did that, you can follow the steps from step 1, taking into account that !NintPresents is a sound effect number instead.
4. Im getting an error that says: ‘Echo buffer exceeded total space in ARAM’. What can I do?
This error means that there is not enough space on ARAM for adding new songs. Open the song that tells you the error. There are three possible solutions, try them one by one:
- Search for a line that says #default, and change it to #optimized. Reapply AddmusicK. If it didn't work, try step 2.
- Search for a line starting with $F1 $XX $YY $ZZ, where $XX $YY $ZZ are hexadecimal numbers. Lower $XX by one, and reapply AddmusicK. If it doesn't work, try lowering it more, until it's $01.
- Worst case scenario, the song is way too big for your hack. You'll have to remove global songs for it to be inserted.
5.- If I beat or die with 100 seconds or less in the timer, the music keeps sped up!
Simply add #option TempoImmunity after the first line of your level end/death song.