IEnumerator StartRound() // starts a new game round { announcer.Message("Round " + (roundIndex + 1), 2f); // plays a message for 1.5 seconds, announcing the new round audioManager.PlaySound("next round"); dog.PlayAnimation("Jumping"); // plays new round animations and sound, waits until they are done, yield return(new WaitForSecondsRealtime(1.4f)); audioManager.PlaySound("bark"); // more sounds yield return(new WaitForSecondsRealtime(2f)); StartWave(); // then starts a new wave }