Inherits from: PersistentSingleton / Version 1.0.0

Description

The Music Manager Instance allows you to easier manage audio files in Unity. These audio files are in Asset Bundles, which allows you access them directly.

In order to use the script, you need a game object in your scene with the Music Manager script attached to it. The object will enter the don’t destroy on load section so it can be used in multiple scenes.

Untitled

Properties

MusicManager.Instance.isMusicFading

Whether the audio is changing gradually its volume (Read only).


MusicManager.Instace.MusicLoop

Whether the current music is set to loop or not.


MusicManager.Instace.SFXLoop

Whether the current SFX is set to loop or not.


MusicManager.Instace.MusicVolume

Music volume level. (Range form 0 to 1)


MusicManager.Instace.MusicVolumeSave

Music volume level, but after changing the value, it will be saved in the playerprefs (Range form 0 to 1)


MusicManager.Instace.SFXVolume

Volume level of the SFX. (Range form 0 to 1)


MusicManager.Instace.SFXVolumeSafe

Volume level of the SFX, but after changing the value, it will be saved in the playerprefs (Range form 0 to 1)