Esempio n. 1
0
 /// <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);
 }
Esempio n. 2
0
        /// <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;
        }