Obtain the custom music you with to use. A large collection of songs to use may be obtained here. Please note that MIDI, MP3, WAV, and other files will not work! Only the file types obtained at that link are guaranteed to work.
Download the song and save the whole ZIP file in the folder labelled "music".
Right click the ZIP folder and select "Extract All" if you're using Windows. If you are not using Windows or this option is not available for whatever reason, create a new folder in your "music" folder (named whatever you want) and copy the contents of the ZIP file into this new folder. You can delete the ZIP file at this point if you wish.
Go into the folder you just created and open up the text file inside. Don't worry if you don't understand what's going on inside, it's not important. For now, just type "#am4" (without quotes) at the top of the file. Make sure it's on its own line. If this was a song for AddmusicM, use "#amm" instead. Now save the file.
If your song is sampled, there is one extra step. Just below the "#am4" you just typed, copy and paste this in there:
#samples
{
"XXXXXXXX.bnk"
}
where XXXXXXXX.bnk is the name of the bank file that was included in your song. So, for example,
#samples
{
"samples.bnk"
}
Save your file again.
Run "AMKGUI" (if you cannot, see below for manual instructions). To add a new song, simply drag and drop the text file that's in the folder you just created into AMKGUI. The song will be inserted after your currently selected song. Alternatively, you can click the "Add new song" button, navigate to the folder you created earlier, and select the text file that contains the music (e.g. "SMB1 Theme.txt"). You can change or remove songs as well by clicking on their appropriate buttons.
When you have made the changes you want, hit the "Run" button, then select your ROM. After a few moments, a window showing the results given by AddmusicK will appear. If it says that the insertion was successful, then you can just close the program and continue. Otherwise, see below for solutions to common problems.
You can now use custom music. A file named
Once you have your song in its own folder in the "music" folder, open up "Addmusic_list.txt".
Add a new line at the bottom of the file, type in an unused number, and then the song's filename (including the folder you put it in). For example, "My Song/My Song.txt" (without the quotes). This will be the song number that you will use in Lunar Magic.
Run the program. You will be prompted for your ROM name. Make sure that your ROM is in the same directory as the program and that its name does not contain any spaces, then type in the name and hit ENTER.
Some text will appear on the screen describing details of each song you've inserted. Examine it if you like, then exit the program.
Open up your song's text file.
Look for a line or lines that look like sXX_10_14_13_12_16_15_FF or something similar.
At the top of the file, add the following text:
#samples
{
#default
#AMM
"sample10.brr"
"sample14.brr"
"sample13.brr"
"sample12.brr"
"sample16.brr"
"sample15.brr"
}
Where "sample10.brr" is the sample in blist.txt at slot 10, "sample14.brr" is the sample in blist.txt at slot 14, etc. The order of the samples must be in the order that the sXX line specified, so be careful!
Delete the sXX line, save the file, and then exit.
Copy the sample files (probably in a folder named "brr" or "samples") into your sample folder.
10 Trumpet.brr 11 Strings.brr 12 Bass.brr 13 Snare.brr 14 Cymbal.brr 15 Organ.brr 16 Choir.brr
#samples
{
#default
#AMM
"Trumpet.brr"
"Strings.brr"
"Cymbal.brr"
"Bass.brr"
}
Open the offending file. Find the text "#default" and replace it with "#optimized". If this text does not exist (and the text "#samples" also does not exist), then add the following to the top of the file:
#samples
{
#optimized
}
Otherwise, move on to the next step.
Find something that looks like "$F1 $XX $YY $ZZ", where XX YY and ZZ are numbers. Decrease $XX until you don't get any more errors. This may make the song sound a bit different, however.
If you've reached this step, this song is simply too big for your hack. You will either have to delete some sound effects, or remove a global song (explained in the advanced section). This should hopefully never happen, however.
levelinit0
", "levelinit1
", etc. Go to the label that corresponds to the level you want echoey sound effects in. For example, for level 105 you'd go to "levelinit105
".
RTS
:
LDA #$06
STA $1DFA
levelinit105:
LDA #$06
STA $1DFA
RTS
levelinit106:
RTS
Return to the main page