Exemplo n.º 1
0
 public void UpdateText()
 {
     for (int i = 0; i < scoreTexts.Length; i++)
     {
         ScoreTextData data = scoreTexts[i];
         if (data.IsValid && data.LastScore != data.Field.Value) //update text only if score has been modified
         {
             data.LastScore = data.Field.Value;
             data.Text.text = data.LastScore.ToString();
         }
     }
 }
Exemplo n.º 2
0
 public void Reset()
 {
     for (int i = 0; i < scoreTexts.Length; i++)
     {
         ScoreTextData data = scoreTexts[i];
         if (data.IsValid)
         {
             data.Text.text = defaultText;
             data.LastScore = data.Field.Value;
         }
     }
 }