예제 #1
0
    private void PlayerDead(StarController star)
    {
        soundsController.PlaySound(SoundsController.Type.Death);
        initUI.SetActive(true);
        musicController.EndGame();
        timer.SetActive(false);

        bestTime          = Mathf.Max(bestTime, lifeTime);
        bestTimeText.text = string.Format("{0:00}:{1:00}", (int)(bestTime / 60), (bestTime % 60));
        lastTimeText.text = string.Format("{0:00}:{1:00}", (int)(lifeTime / 60), (lifeTime % 60));
        starsText.text    = starsCount.ToString();
    }