refactor: Remove pitch parameter from PlayAfterDelay coroutine
This commit is contained in:
@@ -197,7 +197,7 @@ namespace OCES.Audio
|
||||
this.m_activeSounds.Add(active);
|
||||
IncrementClipCount(audioObject.Id);
|
||||
|
||||
active.Coroutine = StartCoroutine(PlayAfterDelay(active, audioObject, pitch));
|
||||
active.Coroutine = StartCoroutine(PlayAfterDelay(active, audioObject));
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -264,13 +264,12 @@ namespace OCES.Audio
|
||||
source.Play();
|
||||
}
|
||||
|
||||
IEnumerator PlayAfterDelay(ActiveSound active, AudioObject audioObject, float pitch)
|
||||
IEnumerator PlayAfterDelay(ActiveSound active, AudioObject audioObject)
|
||||
{
|
||||
Debug.Log($"Delaying for {audioObject.InitialDelay} second(s).");
|
||||
yield return new WaitForSeconds(audioObject.InitialDelay);
|
||||
|
||||
if (!this.m_activeSounds.Contains(active)) yield break;
|
||||
active.Pitch = pitch;
|
||||
|
||||
ExecutePlay(active, isRegistered: true);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user