Time for action - creating random sounds
In FMOD, we have the ability to add multiple tracks to individual sound definitions. This can be used to good measure when creating random sound volumes. This example will demonstrate how to create a sound definition with multiple sound files and how to randomly play these within your level.
Open the FMOD project created in the previous example
mygame_environment.fdp
.Create a new sound event and name it
random_bats_oneshot
.Switch to the Sound Defs view in FMOD.
Right-click in the Sound Defs list and select the Add sound def… option.
Name the new Sound Def file as bat_flying_cave.
Select the bat_flying_cave sound def, and in the Sounds window, right-click and select the Add sound file… option.
Add the three provided
.wav
files named bat_flying_cave_01.wav , bat_flying_cave_02.wav, and bat_flying_cave_03.wav.Keep the Play Percentage set to 33.33%, as it gives all sound files an equal chance to play.
The final results of the project and it's settings are seen...