public void Init(AudioClipData data, bool loop) { _audioSource.outputAudioMixerGroup = data.mixerGroup; _audioSource.clip = data.clip; _audioSource.loop = loop; }
public void Play(AudioClipData data, bool loop) { Init(data, loop); Play(); }
public void PlayClipFromData(AudioClipData data) { _audioSourcePool.GetObject() .GetComponent <AudioSourceController>() .Play(data, false); }