public override void clicked()
 {
     if (--GameManager.totalScore < 0)
     {
         GameManager.totalScore = 0;
     }
     ComboFuntion.ComboEnd();
 }
Exemple #2
0
    private IEnumerator Countdown()
    {
        timerRemain = 30;
        while (timerRemain >= 0)
        {
            if (paused || TimeFreeze.isFreeze)
            {
                yield return(new WaitForFixedUpdate());

                continue;
            }
            ScoreObject.GetComponent <TextMeshProUGUI>().text = "Score: " + totalScore;
            TimerObject.GetComponent <TextMeshProUGUI>().text = "Timer: " + Mathf.CeilToInt(timerRemain);
            timerRemain -= Time.deltaTime;
            yield return(null);
        }
        ComboFuntion.ComboEnd();
        paused = true;
        SceneManager.LoadScene("RankScene", LoadSceneMode.Additive);
    }