/// <summary> /// Initializes the pool, fills it, registers to the scene loaded event /// </summary> protected virtual void InitializeSoundManager() { if (_pool == null) { _pool = new MMSoundManagerAudioPool(); } _sounds = new List <MMSoundManagerSound>(); _pool.FillAudioSourcePool(AudioSourcePoolSize, this.transform); }
/// <summary> /// Initializes the pool, fills it, registers to the scene loaded event /// </summary> protected virtual void InitializeSoundManager() { if (_pool == null) { _pool = new MMSoundManagerAudioPool(); } _sounds = new HashSet <MMSoundManagerSound>(); _pool.FillAudioSourcePool(AudioSourcePoolSize, this.transform); SceneManager.sceneLoaded += OnSceneLoaded; }