• 沒有找到結果。

Update your soundbank with Wwise

在文檔中 Amazon Lumberyard (頁 151-154)

In the first part of this audio tutorial, you will use the Wwise project that we have already started for you.

Wwise projects are used to:

• Import, group, and manage your sound assets

• Set up sound events that can be called from your game

• Generate a soundbank that can be read by Lumberyard’s Audio Controls Editor

We’re going to begin with a brief introduction to Wwise, where we’ll import a new sound asset and create a new sound event for the game. Then we’ll update the soundbank before we head over to the Lumberyard Editor. If you are already familiar with all of these features in Wwise and want to skip ahead to the next section on adding sound effects to your game, complete the following tasks first:

• Import Chicken2.wav from WelcomeGuideTutorials\SoundAssets into the Chicken_Squawk container.

Update your soundbank with Wwise

• Create the Play_Chicken_Squawk and Stop_Chicken_Squawk events.

• Generate the soundbank.

For detailed instructions on how to perform those tasks, continue with the following steps.

1. Open Wwise by choosing the Wwise LTX icon from your desktop or Start menu. If this is the first time that you are running Wwise, you will be prompted to accept a license agreement in order to proceed.

2. In the Project Launcher dialog box, choose Open Other….

3. Navigate to the WelcomeGuideTutorials\Sounds\wwise_project directory in your Lumberyard installation and select the Wwise project file named WelcomeGuideTutorials.wproj.

You should now have the WelcomeGuideTutorials Wwise project open in the Wwise project editor.

4. Choose the Audio tab, then open the Actor-Mixer Hierarchy folder, the Default Work Unit category, and the SFX virtual folder. You will see two Wwise "random containers": Chicken_Squawk and Farm_Background. Random containers enable you to group a series of sounds and configure how they are selected randomly upon playback.

5. Open the Farm_Background container to see two sounds: Farm1 and Farm2.

You can listen to these sound effects using the playback controls in the Transport Control view at the bottom of the Wwise editor. To do this, select a container or a specific sound and click the Play button.

You might also want to peruse the settings that define how these ambient background sounds are selected during playback:

a. With the Farm_Background selected in the Project Explorer view, notice in the Property Editor window that Play Type is set to Random and Standard, while the Avoid repeating last checkbox is not checked. This enables either of the two sounds to be chosen at random, without regard to which sound was last chosen.

b. The Play Mode is set to Continuous with a Loop that is set to Infinite. This enables the sounds to loop as we play them in the background, selecting from the two available sounds each time it loops.

c. The Weight of a sound in the Contents Editor determines the probability of that particular sound getting chosen at random.

For more details on all of these settings, use the help provided with Wwise by opening the Help menu and choosing Wwise Help, or by pressing the F1 key.

6. Right-click the Chicken_Squawk container so that we can import a new variation of the squawking sound.

7. Choose Import Audio Files….

Update your soundbank with Wwise

8. In the Audio File Importer dialog box, choose Add Files….

9. In the file browser dialog box, navigate to the WelcomeGuideTutorials\SoundAssets directory, select Chicken2.wav, and choose Open.

TipAnother way to choose sound asset files for import is to drag the .wav files from Windows Explorer and drop them into the Actor-Mixer Hierarchy. Doing this will automatically open the Audio File Importer dialog box with the files already selected.

10.In the Audio File Importer dialog box, choose Import to add a second sound effect to the

Chicken_Squawk container. You should now have two sound effects in the container: Chicken1 and Chicken2. Feel free to adjust the weights of each sound in the container using the controls in the Contents Editor.

11.For Lumberyard to play these sounds, we need to create Wwise sound events. Typically, you will create two events for each sound effect: play and stop.

a. Right-click the Chicken_Squawk container, highlight New event, and choose Play.

b. Right-click the Chicken_Squawk container again, highlight New event, highlight Stop, and choose Stop.

c. Choose the Events tab. You should now have a Play_Chicken_Squawk and a Stop_Chicken_Squawk event listed under the Default Work Unit in this tab.

For organizational purposes, feel free to drag and drop these two events to the SFX folder if you would like.

We’ve imported a new sound and created new sound events for the container. Now we need to save the project and then regenerate the sound bank so that our Lumberyard game can find them.

12.Open the Project menu and choose Save.

13.Generate the soundbank.

• To do this in Wwise LTX, choose the Generate Soundbank button, just below the menu bar.

• To do this in the full version of Wwise, right-click the Soundbank folder and select Generate Soundbank(s) for all platforms.

在文檔中 Amazon Lumberyard (頁 151-154)