Creating and Editing Drum Instruments; Fixing the Boop
Perhaps you've inserted a song now using the Native Instrument Map and found that you got a lot of booping sounds, or maybe that you had a song that you wanted to use but couldn't get the percussion just right. Or, perhaps you wanted to insert a few new sound effects, or you're hacking FE12 music and wanted to get the guitar from Tearing Shadows working. You've come to the right place. Here you'll learn the basics of the structure of a Drum instrument, and how to create and edit your own.
Drum instruments have the structure like this, as I outlined earlier in the tutorial.
80 00 00 00 XX XX XX 08 00 00 00 00
The 0x80 tells the game that it's a Drum, and then the pointer after that points to another array of instruments that the drum uses for each note. For instance, if that XX XX XX 08 were D6 E7 A1 08, then at $A1E7D6 we'd have this:
08 3C 00 D0 YY YY YY 08 FF 00 FF CC
08 3C 00 E6 XX XX XX 08 FF 00 FF CC
00 3C 00 A2 ZZ ZZ ZZ 08 FF 00 FF CC
08 3C 00 F0 YX YX YX 08 FF 00 FF CC
00 3C 00 88 YZ YZ YZ 08 FF 00 FF CC
[and so on]
What does this data actually mean, though? Well...
08 3C 00 D0 YY YY YY 08 FF 00 FF CC // play this sample for C0
08 3C 00 E6 XX XX XX 08 FF 00 FF CC // play this sample for C#0
00 3C 00 A2 ZZ ZZ ZZ 08 FF 00 FF CC // play this sample for D0
08 3C 00 F0 YX YX YX 08 FF 00 FF CC // play this sample for D#0
00 3C 00 88 YZ YZ YZ 08 FF 00 FF CC // play this sample for E0
[and so on]
Now, you'll have noticed that unlike typical Direct instruments, these samples can sometimes have a 0x08 at the beginning. Before, I said that this makes them play at a fixed rate of 13768 Hz, which is the game's default playback for all samples. This is because (likely for space-saving reasons) the samples in FE7 were inserted at a high frequency and then had that frequency lowered by the game's software, which would allow them to save on a bit of storage space. It isn't terribly important, but do keep in mind that this is something you need to change if you want to alter the pitch of the drum samples. This is shown by the box, "Fixed Frequency" in Sappy.
The 0x3C can be very important here, as well, since it's the only time the game pays attention to them. As I said in the beginning, 0x3C is 60, which corresponds to a middle C. This means that the game plays the sample at a (technically) unaltered pitch. However, if there is a 08 in front of it, the game will still ignore the 3C. If you change the 08 to a 00 and then change the 3C to another pitch, you'll hear the difference. This is shown by the dropdown menu "Base Note" in Sappy.
The fourth byte in the sequence is the "Forced pan" value that you can see in Sappy. If you don't want any forced pan at all, change this to 00. Otherwise, pan can be calculated by [desired pan between 0-127] + 0x80. If you are inputting this directly into Sappy, just put in your desired value.
Finally, there is the pointer to the sample, of course. I'm sure you worked this out on your own.
This is how the Drum editor looks in Sappy.
If you hit Edit...
Looks familiar, right?
Occasionally you will see these things. These are the offenders of the "boop" sound. This is instrument 22 in Drum instrument 127. I want you to look at this list, now:
This means that instrument 22 is equivalent to A1; therefore, if you're getting boops, it could be because you have A1s playing in your MIDI. This list is unfortunately not standardised and thus some MIDI editors and other lists may actually list C0 as C -2 and B9 as B7, or something like that. That's something you'll have to figure out on your own.
Remember in a previous chapter how I showed you how to replace a Direct instrument, and transplant it from another song? The sample principle applies here. Let's say your song has G3 Toms. Well, FE7 doesn't have G3 toms, but it sure does have F3 toms. So you could copy over the parameters from instrument 42 to instrument 44 and that would also solve your boop problem; not to mention, you'd be rid of the problem forever.
One thing that is also fantastic is this Wikipedia page here. It's a bit of a cheat sheet that gives you a rough guide as to which keys correspond to what drum sounds. Keep in mind that FE games don't use the entire array and thus have some blank entries but if you need a better visual guide, this is super useful.