Quantcast
Channel: Answers for "adjusting volume for audio listener"
Viewing all articles
Browse latest Browse all 6

Answer by jchart7

0
0
I just created another Audio Source and called it MasterVolume, then i linked its values to the Audio Listener. Then use your slider to control the MasterVolume. using UnityEngine; using System.Collections; public class AudioControls : MonoBehaviour { public GameObject masterVolume; private float aSliderValue = 1; void Update () { aSliderValue = masterVolume.audio.volume; AudioListener.volume = aSliderValue; } }

Viewing all articles
Browse latest Browse all 6

Latest Images

Trending Articles





Latest Images