コード例 #1
0
    public void AddToScore(int amount)
    {
        Score += amount;
        inGameScoreText.UpdateScore(Score);
        inGameScoreText.Bounce();

        int topScore = PlayerPrefs.GetInt("Top Score");

        if (!hasNewTopScore &&
            topScore > 0 &&
            Score > topScore)
        {
            hasNewTopScore = true;
            topScoreEffect.DoNewTopScoreEffect();
        }
    }
コード例 #2
0
 public void AddToScore(int amount)
 {
     score += amount;
     inGameScoreText.UpdateScore(score);
     inGameScoreText.Bounce();
 }