Sound and Music
This page is part of the Essential Series modding tutorials. It covers everything about sounds: exporting and importing the game's sound and music using Industrial Park, using JAW data, music events and asset types such as SFX and SDFX.
In BFBB, sounds are stored in SND (sound effects), SNDS (music and voices) and SNDI (headers) assets usually in HOP files. Most of the game's sounds (effects and voices) are in each individual level that uses them, but music is contained in MNU5.HIP. The difference between SND and SNDS is that SND are loaded completely before being played, while SNDS are loaded from the disc as they are being played. The files use a system in which a part of the sound data (the header) is in the SNDI asset, while the rest is in the SND/SNDS. When importing/exporting sounds, Industrial Park will handle this separation for you.
You can use the Asset Data Editor for SND and SNDS sounds to preview sounds; this only works on a few sound formats, but not all of them. For this function to work, you must first click on Download vgmstream, under the Tools tool strip menu to download a vgmstream release from its page to your Resources folder. The tool is used to play the sounds. To stop a sound, click on the Stop Sound also under Tools, otherwise the sound will only stop if you close Industrial Park.
To export a SND or SNDS asset, navigate to it in Industrial Park's Archive Editor and click Edit Data. Click Export Sound Data and a file browser dialog will open, allowing you to save the sound.
- If you're using a Xbox archive, this is a WAV sound which can be played immediately.
- On GameCube (BFBB and Scooby), it's a DSP file which you can use this Audacity fork with DSP support (or another tool of your choice) to import and convert to other formats such as WAV or MP3.
- On GameCube (Movie/Incredibles/ROTU), this is a FSB3 file.
- On PS2, this is a VAG file.
To import a custom audio file, it must be:
- On Xbox, a WAV file.
- On GameCube (BFBB and Scooby), a mono DSP file which you can export from the Audacity version linked above (or another tool of your choice).
- On GameCube (Movie/Incredibles/ROTU), a FSB3 file.
- On PS2, a VAG file.
One option is to use the Import Multiple Assets dialog, which you can find in an Archive Editor's Edit tool strip menu. Make sure you have a SRAM layer selected, then open the dialog, select the asset type you want to import (SND for sound effects, SNDS for music or voices), click on Import Raw Data and choose any amount of files to import. Industrial Park will automatically split the header from it and place it in the SNDI file.
Another option is to use an existing SND/SNDS asset. Check the "Trim header and send it to SNDI" checkbox in the Asset Data Editor and click on Import Sound Data. You can also do this on an asset you duplicated/renamed. Choose your source file in the file browser dialog and Industrial Park will automatically split the header from it and place it in the SNDI file.
To import a sound that will loop ingame, first you need to extract a sound from the original game that already loops. For example, mnu4_Bub_amb_loop.DSP from MNU4.
Import the looped sound into Audacity. You'll see something like this:
Now, import your custom sound. Make sure it is mono, as BFBB only accepts mono sounds.
Once you have the sound, you can adjust the arrow highlighted in green to set the start and end points of the loop.
Now, export the file as Mono DSP and import it as detailed above.
Jaw Data is contained in the JAW asset and refers to lip-syncing data for character mouths. You can use this plugin to create jaw data from an audio file in Audacity; then use the Import Jaw Data button in the Asset Data Editor for the sound asset to import it. This video contains a guide on doing that.
If you want a music track to play, you can send the PlayMusic event to any dispatcher with the number of the song on the first argument (the game always uses a dispatcher called MUSIC_DISP, and so can you if you wish, but it's not necessary). Note that this cannot be done on ScenePrepare, as you have to wait at least one frame before PlayMusic actually works. An alternative way is to make a timer that runs on ScenePrepare and expires in 0.1 seconds before sending PlayMusic to a dispatcher on Expired. These are the possible values for the argument:
- 00 - Bikini Bototm
- 01 - Jellyfish Fields
- 02 - Downtown Bikini Bottom
- 03 - Goo Lagoon
- 04 - Poseidome
- 05 - Rock Bottom
- 06 - Mermalair
- 07 - Silence (Sand Mountain has no unique track!)
- 08 - Industrial Park
- 09 - Kelp Forest
- 10 - Flying Dutchman Graveyard
- 11 - SpongeBob's Dream
- 12 - Chum Bucket Lab
- 15 - Slide
- 16 - Ambush
Sound Effects (Scooby and BFBB)
While SND and SNDS are the audio files themselves, SFX is the asset type used to play sounds ingame in Scooby and BFBB.
There are two SFX templates in Industrial Park:
- SFX_OnEvent is meant for sounds which play when an event is triggered. The position and radius values do not matter for this asset, as the SFX will play when you sent the Play event to it from another asset.
- SFX_OnRadius for sounds which play when you are inside the radius of the SFX trigger. The sound will start playing at a lower volume when the player is in the outer radius and will be in maximum volume when the player is in the inner radius. Both radiuses and the position are editable. Note that this already comes with a ScenePrepare => Play event in the SFX. You can remove it and use the Play event later in your level to make the SFX only active later, if you want to.
You can also take a look at other SFX assets already present in the game. The settings (SFX Flags 08 and 09) are not yet known, but you can copy them from existing assets to see what effect that has on them.
- Play: send this to a SFX to play the sound. In the case of OnRadius SFX, the sound will only play when you are in the radius.
- Stop: send this to a SFX to stop the sound.
SFX as Custom Music
SFX assets can be used to play custom music in your stage, if you wish to add new music without replacing one of the existing music tracks (they are SNDS assets located in MNU4.HIP). This process is a bit hacky and not very intuitive, so this is how it's done:
- Follow the process detailed above to import your song as a new SNDS asset in your level's HOP. You probably want to make sure it's a looping sound.
- Place a SFX_OnEvent template. Set the SNDS asset ID of your song as the Sound_AssetID. The Flags09 property should be set to C0.
- Place a Timer template. Set the time to 0.1. Add two links to it:
- ScenePrepare => Run, with the timer itself as the target asset.
- Expired => PlayMusic, with any dispatcher as the target asset and 7 as the value of the first argument. You can place a new Dispatcher template just for this if you'd like.
- The previous step will make it so no song will play in the level (7 is actually the value for the Sand Mountain song, which doesn't exist in the game).
- Now, the game should play your custom song instead of the original stage's.
Sound Effects (Movie, Incredibles and ROTU)
There are two templates you need to place in Industrial Park to use custom sound effects: a Sound Effect (SDFX) and a Sound Group (SGRP). Note that, if the sound effect you want to use already exists in the stage, there possibly already is a Sound Group for it, so you can start at step #3.
- Place a SoundGroup template. In the asset data editor for it, edit the SGRP_Entries field and change the Sound_AssetID of the first entry to the asset ID of the SND or SNDS you want to use.
- You can also edit the InnerRadius and OuterRadius properties. The sound will start playing at a lower volume when the player is in the outer radius and will be in maximum volume when the player is in the inner radius.
- Place a SDFX template. In the asset data editor, set the SoundGroup_AssetID to the SGRP you want to use. You can move the SDFX to the position where you want the sound to play.
For the sound to start playing, you must send the Play event to the SDFX. You can add a ScenePrepare => Play link to the SDFX itself if you want it to start playing already at level start.
If you want, you can attach the sound to an entity (such as a platform or a boulder) instead of using the SDFX's actual position. To do this, set the Emitter_AssetID in the SDFX to the entity's asset ID, and the SoundEffectFlags field to 4.
You can also take a look at other SDFX and SGRP assets already present in the game. Not all settings of these assets are known, but you can copy them from existing assets to see what effect that has on them.