Swish Pack 1

Package containing 256 oneshot sounds (wave/16-bit/44kHz/mono/stereo format) of various swishes, swooshes, flyby’s for wide range of usages in game audio, trailers productions and more. Most of them are recordings of physical objects but there also many designed in digital domain from the scratch (destined for sci-fi objects and events).

Link for Swish Pack 1 in Unity3D Asset Store.

sound tip of the day: layer two or more swish samples together to get fatter sound for weapon brandish.

Footsteps in Unity3D

This is footsteps sounds testing area where you can walk on various surfaces and hear different versions of sound.

The footstep sound set is determined by collision with terrain and objects. The footsteps script examines whether the Player is walking on the Terrain or the other object. If  Terrain is detected under the Player’s foot version of the footsteps is determined by examining Terrain Texture.

Because Terrain Textures can me mixed and scattered there is kind of ‘sound antialiasing’ applied (not in the literal sense). This is done by mixing recently played footstep sound type with the new one. Volume of the old one is decreased to some degree (~50%). This alleviate a little an unpleasant effect of quick switching between sets of footsteps – especially when single footstep of the whole set is played and then switched to another. This helps the Player to percieve background sound as nicely blended and less discrete (binary 0/1). You can test the difference of ‘footsteps antialiasing‘ by switching it off or on using ‘E’ key. By default it is turned on.

Footsteps are shuffled and tempo of steps is based on Players speed.

There are two areas where you can hear a reverb on footsteps. One is achieved with Unity3ds Reverb Zone. The second one uses stereo samples with mixed prerendered Reverb. The second  solution takes much more memory than the first one because of stereo sound and long reverb tails.

Controls: WASD + Mouse and left shift to run. It doesn’t work in Chromium based browsers anymore (Chrome, Opera) so you have to use Firefox or else.

Triggering Reverb Zones in Unity 3D

To have nice ambience of the closed places like room, cave or church you need to set up Reverb Zones. But Unity 3D 4.x provides only spherical shaped Reverb Zones which doesn’t fit into a box. In order to have such a place nicely filled with the reverberation we need to use triggers to switch it on and off when the player enters the area.

Barrack 1
Setup of Reverb Zone and Trigger for Barrack 1.

For simple shapes it is efficient to use Box Colliders. But there is another problem – do not cut reverb aburptly when player steps out the trigger. It is better to use simple scripting to smoothly fade out a reverb zone when OnTriggerExit occurs.

 

Listen to three cases in the scene below:

  • Barrack 1 uses a bit tricky positioned and tight setting for minDistance and maxDistance parameters of Reverb Zone to fade reverbation right before entrance. Not to flexible but useful sometimes.
  • Barrack 2 fades amount of reverb for a short period of time before switching it off. Simple smoothing can be easely spotted.
  • Barrack 3 fade bases on Players distance from the entrance. If the Player change his mind right after stepping out of the Barrack to go back, the reverb doesn’t disappear completely. In this example it is checked only on the exit, to preserve some CPU but you can do in both ways ofcourse.

Examples 2 and 3 operate on the single Reverb Zone parameter.

Controls: WASD + Mouse look. Small icon on the right bottom corner to fullscreen. About 5MB data to go. Unity Player plugin works in Firefox.

 

ps: The lightbulb in the Barrack 3 is broken. I know.