Class AudioManager
- Namespace
- Fallencake.UI.Audio
- Assembly
- Fallencake.UI.dll
Centralized audio settings and utilities for UI components. Manages global enable/volume and provides a shared UnityEngine.AudioSource.
public static class AudioManager
- Inheritance
-
objectAudioManager
Properties
GlobalSoundEnabled
Global sound enable/disable for all UI components.
public static bool GlobalSoundEnabled { get; set; }
Property Value
- bool
GlobalVolume
Global volume for all UI components.
public static float GlobalVolume { get; set; }
Property Value
- float
SharedAudioSource
Shared audio source for components that don't have their own.
public static AudioSource SharedAudioSource { get; }
Property Value
- AudioSource
Methods
MuteAll()
Disables sounds for all components.
public static void MuteAll()
RegisterHandler(IAudioHandler)
Registers an audio handler for centralized management.
public static void RegisterHandler(IAudioHandler handler)
Parameters
handlerIAudioHandlerAudio handler.
UnmuteAll()
Enables sounds for all components.
public static void UnmuteAll()
UnregisterHandler(IAudioHandler)
Removes the audio handler from management.
public static void UnregisterHandler(IAudioHandler handler)
Parameters
handlerIAudioHandlerAudio handler.