public void Play(ClipId id = DefaultClip) { var clip = _audioClips.Find(clip => clip.name == id.ToString()); if (clip != null) { _audioSource.Stop(); _audioSource.clip = clip; _audioSource.Play(); } else { Debug.LogError($"Can't find clip with id {id}"); } }
private static string GetPathToAudioClip(ClipId id) { return($"Audio/{id}"); }