Ejemplo n.º 1
0
 IEnumerator LevelEnd()
 {
     bool gameover = !ship.IsAlive;  //AsteroidBehaviour.Any;
     if (gameover)
     {
         announce.GameOver();
         yield return Pause.Brief(); Score.Tally();
         yield return Pause.Brief(); Score.Reset();
         RemoveRemainingGameTokens();
         powerupManager.DenyAllPower(); // ship should reset itself?
         announce.ClearAnnouncements();
         NewGame();
     }
     else
     {
         announce.LevelCleared();
         yield return Pause.Brief(); Score.LevelCleared(level);
         yield return Pause.Brief();
         AdvanceLevel();
     }
     yield return Pause.Long();
 }