private IEnumerator DeathSequence(float deathTime) { this.dying = true; float timeLeft = deathTime; this.gunObjects[this.currentGun].SetActive(false); while (timeLeft > 0) { this.spriteRenderer.enabled = !this.spriteRenderer.enabled; timeLeft -= Time.deltaTime; yield return(null); } FightController.FindMe().EndLevel(); }
void Start() { this.lastSpawn = float.MinValue; this.levelController = FightController.FindMe(); }