9

Recipe

Sound and Audio

In this chapter, we look at AudioMixers, build a script to act as a basic sound manager (BaseSoundManager) and discuss adding audio to the weapons system of the framework.

9.1AudioMixers and Mixing Audio in Unity

Audio balancing is a huge part of making your game sound professional. It can be difficult to get the volumes of your sounds nicely balanced, so that you can hear everything important underneath the music or so that a laser doesn’t sound louder than an explosion and so forth. Unity provides a great toolkit for balancing audio along with some effects to help get the kind of audioscapes your work needs.

Unity's AudioMixers allow you to organize sounds into groups and then manage those groups rather than ...

Get C# Game Programming Cookbook for Unity 3D, 2nd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.