Summary: Ambience with Ambient Sound Actors, attenuation shapes and falloff distance, spatialization, filter over distance, area loops, source loops, source one-shots, player-oriented one-shots, Sound Cues, audio volumes for reverb, triggers and triggered sounds, embedding sounds into Blueprint Actors
Project: DemoCh01Jungle01 Level: Jungle01
You can skip between the different locations in game using the keys 1–9.
Summary: Playing the game
Download, install, then open the Project: DemoCh01Jungle01 and the Level: Jungle01.
Play the map.
If you’re not used to this kind of first person shooter environment, then practice using the mouse to look around and the W, A, S, and D keys to move around (don’t forget if you hold down the RMB you can also move around in similar fashion within the editor). Press the Esc key to return to the editor window.
Now press the Bookmark keys 1–9 to have a look at the different areas in the environment. Explore the level and get a feel for how the sounds are working. Remember you can also hear the Ambient Sounds in edit mode by enabling Real Time Audio from the Settings menu on the Toolbar.
To be able to jump in and play the game from any starting position, the easiest thing to do is to change the play settings (the drop down menu next to the Play icon on the Toolbar) to Spawn player at/Current Camera Location. You can also right-click anywhere on the floor surface and choose Play from Here, but this can be a little unreliable.
Summary: Ambient Sound Actors, attenuation shapes and falloffdistance, area loops, source loops, source one-shots, player-oriented one-shots
The background ambience to your level forms the crucial foundations on which everything else sits. The attention to detail required for really immersive ambience is one thing that’s sometimes overlooked by people starting in game audio. In this section we’ll be looking at how to implement both the background environmental sounds and sonic landmarks of your map.
Exercise 01_01: Listening Exercise
Now think about how you might begin to group these sounds by their characteristics. You’ll find that they tend to be either constant/looping sounds (usually from some kind of mechanical or electronic source) or one-shots (usually instigated by some sort of human or natural agent). You might end up with something like this.
Ambient Sounds tend to be implemented in the following ways:
Area Loops— These are typically long loops (2–3 minutes) that cover particular sections of the environment. These can sometimes include both background sounds and occasional one-shots, or be shorter loops with just a background area or room tone. Although they sometimes have spatial sounds within them (typically being stereo or quad files), they play back directly to the players ears and don’t pan around as you move.
Source Loops— These are shorter looping sounds that come from specific spatialized sources in the game (typically 4–10 seconds of mechanical/electrical sources that naturally have looping characteristics) and so are spatialized in the game world.
Source One-shots— These are the occasional one-off spatialized sounds that occur at randomized intervals to give the impression of life and activity in the level. The source could be a specifically located one or an imaginary one.
Player-oriented Sounds (POS)— These are similar to source one-shots but come from imaginary sources that we don’t necessarily actually see and are always located relative to the player’s position in the game world.
From their experience in the real world, people expect there to be sound of some sort everywhere they go in a game. Even a bare empty room will feel weird with no sound. Acting as a useful indicator of location, these area loops or room tones not only make an environment feel more real, but can also be used to set the mood of a particular place. Games that use streaming off the disk (discussed in Chapter 02) often use long ambient loops as an efficient way of populating an area with sound. Although not strictly natural since these loops lack the randomization of reality, they can work well if they are long enough and combined with other elements.
It might seem strange that these are not spatialized (in other words, they don’t come from a specific location in the game world), but sounds do tend to become more diffuse (less defined in their direction) the further away you are, so this doesn’t feel entirely unconvincing. It is certainly better than the whole environment whipping/panning around you as you move. In most modern games, these would be multichannel, but given that we’re just getting started, we’ll stick to stereo for now and cover how to import multichannel ambiences in Chapter 08.
Press the 1 key to jump to the *Cave 01* area (Bookmark 1). In front of you, there is a loudspeaker icon representing an [Ambient Sound] Actor of the type that you have already come across in Chapter 00.
By selecting the icon, you can see the sound used in the Details panel and the Attenuation settings (expand the Attenuation Overrides drop down) that control the size of the area over which we’ll hear it. In this instance we’re using a Box shape. The sound is at its maximum volume when the player is inside the interior box, then the sound drops away to zero at the exterior box. The numbers in the Extents settings refer to the Unreal Unit measurement of distance where 1 UU (Unreal Unit) is equal to 1cm. In order to see the sound attenuation curves more clearly and avoid confusion, you can switch off the Volumes/Lightmass Importance from the Show menu of the Viewport.
Using the magnifying glass icon next to the Sound reference in the Details panel will find the sound in the Content Browser ({Cave_Loop_01}). Double-click the Sound Wave to open its Generic Editor panel, and you can see it is set to be a looping sound.
Look back at the Details panel of the [Ambient Sound], and you can see that the Override Attenuation box is checked. This means that we are controlling the attenuation locally, and you can see we’ve set it not to Spatialize.
Press 2 to jump to Bookmark 2 then use the World Outliner to find and select (Ctrl + Click to multiple select) the following area loops for this part of the game level:
Note how we’ve used different attenuation shapes that are appropriate for the areas we’re trying to cover.
These all follow the same principle that the sound is at its maximum volume within the inner shape then falls off towards the outer limits. Each shape uses different names for their inner areas as you can see from the illustrations below. The cone shape has a slightly more specific usage that we’ll be looking at in more detail in Chapter 07.
Sphere: Max Volume inside Radius, then falling off to Falloff Distance.
Box: Max Volume inside Extents, then falling off to Falloff Distance.
Capsule: Max Volume inside capsule as defined by Half Height and Radius, then falling off to Falloff Distance.
Cone: Max Volume inside inner cone as defined by Cone Radius and Cone Angle, then falling off to cone defined by Falloff Distance and Falloff Angle. Cone Offset allows us to offset the start of the cone back from the location of the Ambient Sound Actor.
Exercise 01_02: Area Loops
Download and install the Exercise_Project from the website. In this exercise we are going to add area loops to the *Cave 01* and *Oasis* areas of the exercise level using Ambient Sounds for area loops.
[Ambient Sound], attenuation shapes and falloffdistance, spatialization, hiding/showing items in the level, volume multiplier
You can see that there are two main areas to the first section of this map, *Cave 01* (Bookmark 1), and *Oasis*(Bookmark 2). Using the sounds provided in the folder below (or your own), add background area loops to encapsulate each of the two environments.
PC: C:UsersUserNameDocumentsUnreal ProjectsExercise_ProjectExercise_Assets 1_02_ CaveToneandJungleLoops
Mac: /Users/UserName/Documents/Unreal Projects/Exercise_Project/Exercise_Assets/01_02_ CaveToneandJungleLoops
Note that while volume settings in most DAWs are scaled to take account of the logarithmic nature of sound perception, unfortunately volume settings in the Unreal Engine are not. This causes volume multipliers, particularly at the lower end, to feel slightly unpredictable. This is why we often use curves to control volume—see Appendix A: Core Concepts/Transforming and Constraining Variables and Parameters/Reading through Curves.
For area loops the attenuation settings are about creating a smooth transition between one area and the next. Source loop sounds have a specific point of origin in the game—they are coming from a particular source object, so in this case the attenuation settings are about trying to recreate the realistic drop in volume over distance.
Inside the second large cave (*Cave 02*, Bookmark 3), you can see that the ambience is now created with a general background area loop together with several source loops.
This time these Ambient Sound Actors are spatialized and located in much more specific areas around their source objects. If you look at the Details panel for the Ambient Sound located by the yellow box on the left as you enter the cave ([Generator]), you can see that the attenuation is controlled locally (Override Attenuation) and that the sphere attenuation shape is now spatialized (Allow Spatialization). Unlike the area loops, you will hear these pan from left to right (or in surround) as you move around.
Sound travelling in air also changes in frequency content depending on the humidity and temperature. While this is rather tricky to calculate accurately, we can fake something like this by applying a low-pass filter over distance in addition to attenuating the volume.
If you look at the two areas where we have water dripping through the roof of the cave ([Water_ Stream_01] and [Water_Stream_02]), you can see that these Ambient Sounds have the Attenuate with LPF option enabled. The LPFRadius Min is the distance at which no filtering is applied, and LPFRadius Max is where the maximum filtering is applied.
There are a variety of other aspects regarding how the sound attenuates that you have control over, such as the curve by which it attenuates (Distance Algorithm) and the region in which the sound becomes spatialized (Non-Spatialized Radius). Feel free to play around with these, but we’ll be coming back to them in more detail in Chapter 07.
Although the implementation of ambient loops may appear relatively easy, don’t make the mistake of thinking that it is simple. Creating a convincing and detailed environment is a huge creative challenge, and is so important to setting the mood and tone of your game. The next area serves as an illustration of the kind of attention to detail you should be thinking about.
As it is raining in *Jungle: Area 02* (Bookmark 4), we have a stereo area loop for the background, but we also need source loops for the specific sound of rain falling on different objects within the area. For example in the small patch around the hut we need:
Using the World Outliner search for and select the sounds starting with Jungle02 to see these more clearly. Each one of these needs to be carefully considered in regard to its Inner Area Size and Falloff Distance, whether to apply the low-pass filter, and whether to Spatialize the sound or simply attenuate over distance.
Exercise 01_03: Source Loops
In this exercise we will be adding source loops to the *Cave 01* area of the exercise level using Ambient Sound Actors.
Low-pass filter over distance, previewing attenuation shapes in-game
As well as previewing your source loops as you move around the game in the Viewport (Settings/Real Time Audio), you may want to actually see the attenuation shapes in the game as you play it. If you edit your Sound Waves Generic Asset Editor to enable Debug, you can call up the Console while playing the game (¬ or Tab key, depending on your keyboard language settings), then type “Stat Sounds-Debug”. “Stat Sounds Off” turns this off. You’ll then see their attenuation setting in the game represented in blue shapes when the Ambient Sounds are active. As well as being useful, this also looks pretty cool—which is always important! For more on Console commands, see Appendix A: Core Concepts/Console Commands.
In the next section we are going to be using Sound Cues (indicated in the text by {Sound Cue Name}), so we’ll spend a moment to look at what these are. Rather than simply playing back one .wav or Sound Wave file, most game editors will have a more abstracted layer for sound events so that you are in fact triggering a system that contains multiple .wav files. Sometimes called a sound event or sound object, in the Unreal Engine these systems take place within a Sound Cue. We will be talking about this idea again in more depth in Chapter 02.
In the Content Browser double-click on the {Thunder} Sound Cue. This will open the Sound Cue Editor.
You should see a panel to the right that displays the Palette of objects or - Nodes- available for you to build your systems with, and to the left a Details panel where you have access to their settings. Try pressing Play from the top toolbar of the Sound Cue Editor. You should hear a thunder sound. You may have to wait a while, as this Sound Cue has a - Delay- node in it. If you select one of the - Wave Players- and click on Play Node from the top toolbar, you’ll hear it immediately since now we’re choosing to play that specific node rather than the whole cue. (You can also preview the cue up to the selected node by double clicking on it.)
LMB—Click to select, click and hold to drag
RMB—Click and hold to move the screen around
Ctrl + LMB—Click to select and deselect multiple items
Shift + LMB—Drag to marquee select (this allows you to draw a rectangle and will select the items within it)
Click and drag wires between pins to connect up the systems, Alt + click to delete connections, and Ctrl + click to move an existing connection to another pin. (See also the Quick Reference/Tips page at the back of the book.).
In addition to the systems you can build within them, another advantage of using Sound Cues is that you can reuse them in a number of locations in your level, and any changes you need to make need only be made on the Sound Cue itself rather than hunting around the level to make changes on multiple [Ambient Sound] s.
We’ll be using Sound Cues a great deal throughout the book and will go into each node’s function as we go, but for the moment a description of each of the nodes available in the Sound Cue and their function can be found in Appendix A: Core Concepts/Sound Cue Nodes.
The simplest way to add your sounds to a Sound Cue is to drag and drop the {Sound Waves} from the Content Browser into the Sound Cue Editor graph; however, this is not always the fastest method.
If you first select your {Sound Waves} in the Content Browser then right-click in the Sound Cue Editor, you’ll see that you have the option to add the waves prelinked to a particular -Node-. For example you might have 10 waves that you want to play back randomly. If you use this method, they’ll all appear in the Sound Cue already linked up to a -Random- node rather than having to link them up individually.
This is the right-click menu in the Sound Cue Editor when waves are selected in the Content Browser:
When you are working in the Sound Cue Editor, you can sync the Content Browser to select the cue you are working on by pressing Ctrl + B. To find the specific Sound Wave in the browser, right-click on it in the Viewport and choose Sync to Browser.
As we saw in the listening exercise, the real world is typically made up of a combination of loops and one-shots. One thing that will stop a game environment from feeling immersive and natural is any repetition of a series or sequence of sounds, as these immediately jump out as being artificial. Imagine this scenario in the real world: A dog barks a few times, then a car door slams, somebody shouts, and a helicopter flies overhead. If any of those sounds were to repeat but actually sounded pretty much the same (i.e., the same sample), then it might be unusual but you’d probably accept it. If they happened again but with exactly the same timing in exactly the same order then it would feel incredibly odd. To break this up, we need a system that will allow us to play back a random choice of sounds at random times.
Sometimes our one-shots are associated with actual objects or agents in the game, but very often they are there to create the impression of a world much more real and alive than it actually is. In the perfect game, there would be no such thing as one-shots like this because the environmental ambience would be comprised of hundreds of individual agents going around, doing their thing, and making the occasional noise—like in the real world. Given that most companies don’t want to bankrupt themselves by developing assets for every possible object that might be in a world, it’s our job to fake it by creating the impression that these things are there, even when they are not necessarily visible. So there might be imaginary birds in the trees, imaginary traffic just out of sight, and imaginary police cars in the distance.
Find the [Thunder] Ambient Sound in the level that references the {Thunder} Sound Cue you just looked at (using the World Outliner panel search). Select it, press F to focus, and you’ll see that it is in the *Jungle: Area 02* (Bookmark 4). Using the Details panel and the looking glass icon, locate the Sound Cue {Thunder} again in the Content Browser, and double-click it to open the Sound Cue editorif it is not still open.
If you select the -Delay- node and look at the Details panel, you can see that its settings are Delay Min = 8 and Delay Max = 20. So the system starts, and a random time count between 8 and 20 seconds is chosen. When that time is reached, a random choice is made to play one of the Sound Waves attached to the -Random- node. When that sound has finished playing, the -Looping- node restarts the system and chooses a new delay time, so we get a random delay between a random choice of sounds.
In the first part of the *Temple Clearing 01* (Bookmark 5), there are 4 more examples of the source one-shot using the Sound Cues: {Creature_01}, {Creature_02},
{Creature_03}, and some {Frogs}.
When you look at these Sound Cues in the Sound Cue Editor, you’ll note that they have an additional node: the -Modulator-.
This is very useful for increasing variety in your one-shots, as it allows you to randomize both the volume and pitch of the sounds between Min and Max settings. Another thing to note is that you can alter the Weights within the -Random- node to make sounds more or less likely to be chosen, so if you want one of your sounds to be chosen more rarely than the others, set its Weight to be lower than the others (see more discussion of randomization in Chapter 06).
Exercise 01_04: Source One-shots
In this exercise you will add source one-shots to the *Oasis* area of your exercise level using Sound Cues that are referenced by Ambient Sound Actors.
{Sound Cue}, -Looping-, -Delay-, -Random-
Despite having random delays, you may have noticed some of your one-shot elements still may feel a little artificial or even have a looping feel to them—why is that? One of the problems with a looping delay that is implemented within a Sound Cue is that the -Delay- only actually starts once the first sound has finished playing (i.e., the delay is the time between sounds), so you’ll never get overlapping sounds—in other words, it is a monophonic (one voice) system. If you’re using short delays on sounds of a similar length, then this can start to sound a bit loopy.
To create a system that has random delays between the start of sounds and allows them to be retriggered with overlap (a multiple voice or polyphonic system), we need to allow for simultaneous sounds by using a -Mixer-.
Again in the *Temple Clearing 01* area (Bookmark 5) over by the river is the Ambient Sound [Loons_01] that references the Sound Cue {Loons_01}. Here you can see that we’ve set up two looping delay systems. They will both randomly choose one of the Sound Waves but at different times, and since they are then connected to a -Mixer- node, you will be able to hear both sources play should they happen to overlap.
We’ve demonstrated source one-shots that are associated with specific locations in the game, but these sources could equally be imaginary ones. Combining these kinds of randomized one-shots with area loops in a single Sound Cue for an area is another approach you could take if the spatialized aspects were less of a priority in your game.
Exercise 01_05: Overlapping One-shots
In this exercise you will add some overlapping source one-shots to the oasis area of your exercise level.
-Mixer
What’s the sound of one hand clapping in a forest when there is nobody there to hear? Well, we don’t know either, but having meticulously placed hundreds of one-shot sounds in the level to represent things that often aren’t actually there or visible, you might ask yourself if there’s a quicker alternative. After all there is little point in having the one-shots there if the player is not close enough to actually hear them. Player-oriented one-shots fulfill the purpose of representing these things in the world that you want there but can’t see, and ensure that the player will always hear them since they are actually oriented around the player’s location.
This functionality doesn’t actually exist natively in the Unreal Engine, so we have cooked up a Macro, or a reusable Blueprint system, for you. This is imaginatively entitled the <GAB_Player_Oriented_ One_Shot>, and this is what is generating the kookaburra and fly sounds in the area immediately in front of the temple (*Temple Clearing02*, Bookmark 6). This macro is installed when you installed the levels in the following directory:
Open up the [Level Blueprint] from the Blueprints icon on the Toolbar and find the Player Oriented Sounds section.
We have placed a [Trigger] in the game level on the bridge, since we only want these sounds to come on when the player has crossed into the final area. The [Trigger] outputs an event when the player overlaps with it and then the <Sequence> node triggers our two Blueprint macro systems.
The XY values range from negative to positive, negative being behind (X) and to the left (Y), and positive being in front (X) and to the right (Y) relative to the game world axis. The XY values of the <GAB_Player_Oriented_One_Shot> represent potential distance ranges for the sound from the player in the XY plane of the game world axis. If you want the sound to originate from all directions you’ll want to use both positive and negative values. Play this area (starting prior to the bridge), and you should hear these sounds being randomly spawned around you (this is particularly effective with 5.1 surround). Note that in the case of the kookaburra, for example, this can potentially spawn up to 1,000 units away, so we have made sure that our sound has an attenuation fall off of greater than this otherwise when it does play we might not hear it.
By default this does not take the player’s rotation into account (the way they are facing), but if you specifically want sounds to always spawn in front or behind the player (or to the side), you can check the Use Player Rotation Boolean. By setting the X value to negative, for example, you can fix the sounds to always appear behind the player—spooky!
Exercise 01_06: Player-oriented One-shots
In this exercise we will be adding POS (Player-oriented sounds) to the *Oasis* area of your level. This is your first Blueprint system, so be brave! (Read the first part of Appendix B: Blueprint primer before starting this exercise)
<GAB_Player_Oriented_One_Shot>, [Trigger], <OnActorBeginOverlap Event>
Although randomized one-shot sounds are ideal for generating variety and life in your ambient environments, it can be tricky to source the sounds in the first place. Typically these sounds exist alongside others in the real world, so when you try to edit them out as individualized elements, you get all the background noise as well. Although you should always aim to get sounds that are as clean and isolated as possible, one can get a little obsessive about this when editing one-shots in isolation. Don’t forget that the one-shots will likely be played against a background of both area loops and source loops. Often the frequencies in these background elements can help mask some of the noisiness on your one-shots or help to hide an abrupt decay tail, and they’ll sometimes sit in the mix better than you might imagine.
When you consider the massive scale of many modern games, you’ll appreciate that it’s not very efficient to have an artist go around and place lots of objects, and then a sound designer go around and find exactly the same objects to add sound to them. Since most objects will get reused numerous times throughout a game (e.g. tree type A), it would be useful if we can embed the sounds themselves in the Actor. Then we would have global control over the sound itself (through the Sound Cue), but we wouldn’t have to place them all. If things needed changing, we would only need to alter the cue, not each of the 500 Ambient Sounds!
In the illustration below, two trees are highlighted (*Temple Clearing 02*, Bookmark 6). These are actually Blueprint Actors {GAB_Tree_Blueprint} that have both the tree mesh and an ambient one-shot sound embedded.
We’ve seen examples of this already in the shooter game, where you opened up various ship Blueprints and replaced the sounds. Open the {GAB_Tree_Blueprint} by either double-clicking on the asset in the Content Browser or by selecting the asset in the Viewport and clicking on Edit Blueprint in its Details panel. When the Blueprint Editor window is open, look at the Viewport to see the components in this Blueprint.
Here you can see the static mesh component ({Tree}) and the audio component (the Sound Cue {Bird_For_Tree}). This means that wherever this Blueprint is used, it will automatically refer to and spatialize this Sound Cue along with the visual asset. In some levels you may be hearing a lot of sound, but when looking around for the Ambient Sounds in the level, there appear to be none. This is because they are part of the Blueprint Actors. Much of what we’ve done in the demo levels is in the level Blueprint to make things easier to follow and understand, but some of this might more typically be done in Blueprint Actors, particularly if you have multiple instances.
Exercise 01_07: Embedding Sounds in Actor Blueprints
In this exercise you’re going to make your own Blueprint Actor that has an embedded audio component so you can reuse it throughout your level.
Actor Blueprint, components, audio component, static mesh
Much of this chapter has dealt with creating background ambience to make your game world seem alive and real. A useful analogy when considering ambience is that of an oil painting. When you look at a finished oil painting, you get the impression of a complete and convincing picture. However, not one area of the painting is the result of a single brush stroke, but instead the final effect arises from the combination of layer upon layer of paint. You should think of your ambience in the same way. The final effect will need to be built up of many different layers of distant, mid-distance, and close sounds to produce the final effect.
Summary: Triggers, fading Ambient Sounds in/out for occlusion
So far we’ve managed to give our different areas (caves and jungle) a separate audio identity by careful use of the Radius/Extents and Falloff settings for our Ambient Sounds, but this is mainly because we’ve had relatively simple area shapes to deal with. Game engines typically do not have particularly sophisticated systems for dealing with audio occlusion (where sounds are attenuated by passing through materials such as walls) and so often we need to deal with this by hand. Imagine how you might approach an area like the one represented below. You could no longer just use large area loops since the jungle sound would be heard inside the temples, and the temples are awkward shapes that don’t align neatly with spheres, boxes, capsules, or cones.
One solution is to use lots of overlapping sound areas with different shapes to work your way around and within the buildings, but that would be a lot of work and could lead to phasing issues between instances of the same sound playing simultaneously. A more pragmatic approach that is often used is to simply switch off the exterior sounds when you go inside (and switch on interior sounds) and vice versa.
In the image below, you can see the issue (*Temple Entrance*, Bookmark 7). The Ambient Sound [Swamp_Loop_01] that forms the background audio for the jungle protrudes into the temple, so you will hear it even when inside. Although not particularly realistic, many games use a simple method of placing a trigger in the entrance of a building or area and using this to switch the ambiences on or off.
Open the Level Blueprint and find the “Ambience Switching” section. A sphere [Trigger] at the entrance to the temple gives us an <On Actor Begin Overlap> event in the [Level Blueprint] when the player walks through it. This is used to <Fade Out> the outside ambience and <Fade In> the temple music [Temple_Music_01_Loop].
The Auto Activate option for the temple music [Ambient Sound] has been disabled in its Details panel. In other words it does not start playing when the level starts, and so it will be silent until the <Fade In> command is received.
The <FlipFlop> node alternates between its two outputs. It will send an execute command out of A, then B, then A, etc., so if the player walks back out of the temple, then the outside ambience is faded back in and the inside faded out again. We’ll be returning for a deeper look at occlusion later in Chapter 07, but for the moment this simple switching approach can work effectively.
You could of course extend this approach to deal with all the different Ambient Sound areas in your level, setting up Sound Cues that include both area loops and imaginary source one-shots, and then switching between them as you move between locations. See Exercise 05_01 in Chapter 05 for an adaptable system using arrays for this.
Since occasionally things don’t go to plan, it is a good idea to also have some kind of completely global subtle background tone throughout your whole level. Silence is a real glaring error and immersion breaker, so if the switching system does go wrong (maybe the sound is slow to be streamed from disk for example), then the game won’t sound completely broken.
Exercise 01_08: Switching Ambience
In this exercise we are going to use a Blueprint system for switching ambience when the player goes into or out of the buildings in the *Oasis* area of your level.
[Trigger], <FadeIn>, <FadeOut>, <FlipFlop>, <Gate>, <Sequence>
Summary: [Audio Volumes] for reverb
The characteristics of a space can change dramatically according to its size and the materials within it since these affect the way that sound is reflected around. Think about the difference between singing in the shower and singing in a large cathedral for example. For your environments to sound convincing to the player, you need to carefully select the appropriate reverb setting for each space and apply this to sounds that occur within it (you can specify if you don’t want it applied to specific sounds, and we will look at that later in the section on sound classes in Chapter 08).
As you enter the temple (*Temple Upper*, Bookmark 8), you will notice that your footstep and weapon sounds have reverb applied, and as you move through different sized rooms in the temple, you’ll hear that the type of reverb changes accordingly. The type of reverb effect is set in the Details panel of the [Audio Volume] Actor, and you can specify the volume of the reverb effect and how long it takes to fade in after you enter the volume (this is to stop any abrupt changes).
Exercise 01_09: Reverb
In this exercise you are going to add reverb to *Cave 01*, *Cave 02*, and the *Oasis Buildings* using [Audio Volume] s.
[Audio Volume], reverb effects
Summary: Triggering sounds directly with key of controller inputs
In the basement of the temple (*Temple Lower*, Bookmark 9), you can use the stone button in front of the fire pit to stoke the flames and…well, we won’t spoil the surprise. We have looked at how to turn Ambient Sounds on and off when the player overlaps a [Trigger] that has been placed in the game, but you might also want to trigger a sound or a piece of dialogue when a player interacts with an object or button by using it (typically through pressing X or A on the controller or E on the keyboard).
In order to trigger events from key or controller inputs anywhere in the level, we could just create a <Key Event> in the [Level Blueprint] and link it straight to a <Play Sound Attached>; however, we want this input to work only when the player is actually standing next to the relevant button. See the “Interact” section of the Level Blueprint.
In order to do this, we use a <Gate> node that is opened and closed by the [Trigger] around the button. This way the <Key Event> E will not be allowed through to trigger the sound unless the player is in proximity to the button.
Exercise 01_10: Triggering Sound Events
In this exercise we will look at adding a sound that can be triggered by with a key input when using a button in the game world.
<Key Input Event>, <Play Sound Attached>
Exercise 01_011: DIY: Building Your Own Level
In this exercise you can have a go at building your own level. It is not essential, but the better understanding you have of the level designers work, then the better you can work together. Plus it’s fun!
Static mesh, snapping
You may find it useful at times to use the Snapping functions in the Viewport to snap the Actors to certain grid, rotation, or scaling factors (see Appendix A: Core Concepts/Manipulating Actors).
Although the learning curve has no doubt been a little steep at times, you now have all the basic skills to populate a level with ambient audio and reverb. We’ve emphasized the implementation here, but do not overlook the importance of sound design. It is no good showing off a load of techniques if the end result just doesn’t sound any good. This is why the game sound designer, and as we will see later the game composer, needs a new skillset, one that encompasses all the skills from previous media (being a good sound designer and being a good composer) as well as all the new skills involved in implementation.
After working through this chapter, you should now be able to: