Question by 
               guitarjorge24 · Mar 17, 2019 at 02:10 PM · 
                audiowaitforsecondscoroutinesefficiencyclip  
              
 
              Is it more efficient detect when audio clip ends with AudioSource.isPlaying or with AudioClip.length?
I want to trigger an event when an audio clip finishes playing. Would it be more CPU efficient to keep checking if the audio clip is playing withWaitUntil(() => audioSource.isPlaying == false);
 or would it be more efficient to use: WaitForSeconds(audioClip.length); to simply wait a certain amount of time? 
 How can run a test in Unity to see which one is more CPU efficient? 
               Comment
              
 
               
              Your answer