Fix menu music
This commit is contained in:
@@ -12,7 +12,6 @@ public class MenuMusic : MonoBehaviour
|
||||
Instance = this;
|
||||
DontDestroyOnLoad(gameObject);
|
||||
SceneManager.sceneLoaded += OnSceneLoaded;
|
||||
GetComponent<AudioSource>().volume = BazookaManager.Instance.GetSettingMusicVolume();
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -20,6 +19,11 @@ public class MenuMusic : MonoBehaviour
|
||||
}
|
||||
}
|
||||
|
||||
void Start()
|
||||
{
|
||||
GetComponent<AudioSource>().volume = BazookaManager.Instance.GetSettingMusicVolume();
|
||||
}
|
||||
|
||||
void OnSceneLoaded(Scene scene, LoadSceneMode mode)
|
||||
{
|
||||
if (scene.name == "GamePlayer")
|
||||
|
||||
Reference in New Issue
Block a user