예제 #1
0
파일: Player.cs 프로젝트: phelow/OhDeer
    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);
    }
예제 #2
0
파일: Car.cs 프로젝트: phelow/OhDeer
 void Explode()
 {
     ExplosionMaster.Explode(transform.position);
     //TODO: put in explosion mechanics
     Destroy(this.gameObject);
 }