private IEnumerator KillPlayerCoroutine() { PlayerPrefs.SetInt("YourScore", m_totalPoints); Destroy(this.gameObject); ExplosionMaster.Explode(transform.position); //TODO: include code for animation here yield return(new WaitForSeconds(DEATH_ANIMATION_TIME)); SceneManager.LoadScene(Levels.GAME_OVER_LEVEL); }
void Explode() { ExplosionMaster.Explode(transform.position); //TODO: put in explosion mechanics Destroy(this.gameObject); }