Triggering audio is usually done via two common methods, via Flow Graph or via Trackview. This article will show you how to setup in either method.
Many times sounds can simply be placed in the level as and active Sound Event Spot (SES). This is mainly used for static environmental sounds such as humming and buzzing of a electrical fuse box or dripping water from a water barrel.
You can still link these SES to an area trigger to only activate them when the player is near and vice versa.
Other sounds are designed to be turned on or off based on events during game play. To have a sound play simply link a SoundEventSpot to any of the many available trigger methods in the Flow Graph. The Flow Graph Editor can be used to trigger single-event sounds, as well as start and stop looping sounds. By placing a sound entity in a Flow Graph, it becomes an Entity FlowNode. Most of the properties then become input ports whose values can be changed. This is done by linking other FlowNodes, such as trigger or logic FlowNodes, to the input ports of the sound FlowNode. The most common and easiest method is to connect a trigger FlowNode to the play port of a FlowNode.
In this example the player would enter an area trigger and activate a one shot sound event spot for a falling statue.
To add a 3D sound to an object, open the Track View by going to View -> Open View Pane -> Track View.
3. Right-click the Event and select Add Track -> Sound to add a sound track.
4. Click the Add Key icon, and then click at the point in the Sound track where you would like the sound to be triggered.
5. Select the Key to bring up its properties window.
6. Select the SoundEvent under Sound File.
7. Select the Voice check box if this is a dialog sound, even if it does not have lip-sync animation.
8. Use the following parameters only if you reference a wave file for rapid prototyping:
9. For sound events, ensure the following:
Often, complex scripted events are done in Track View. There are several ways to implement a sound in a scripted event. First, it depends on the player's allowed freedom of interactivity. Let's take three different scenarios: