Unity: Adding audio to increase immersion

Games can look amazing but without audio, they fall short. In this article we’ll add some background music to immerse our players.

We’ll start by adding an empty gameobject called AudioManager. This will eventually handle scripting for audio events but for now it will house another child object called Background.

We add an Audio Source component to Background. Because this will be our background music we want to to play when the game starts and play constantly while the game runs. We make sure Play On Awake and Loop are checked to achieve this.

Finally we drag our music file to the AudioClip in Background and that’s it, we now have some excellent mood music for our game.

In the next article we’ll go over adding audio events like laser fire and explosions.



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Ian Plumpton

Software developer in the field of Unity and C#. Passionate about creating and always driven to develop.