Tanoda
PromoTimeDisplay.cs
Go to the documentation of this file.
1using System.Collections;
2using System.Collections.Generic;
3using UnityEngine;
4using UnityEngine.UI;
5
6public class PromoTimeDisplay : MonoBehaviour
7{
8 public TextMesh tm;
9 public Text txt;
10 public Text txt2;
11
12 void Update()
13 {
14 return;
15 var finish = FindObjectOfType<FinishAction>();
16 if (finish)
17 {
18 if (finish.currTime.text == "00:00.00")
19 {
20 if (tm)
21 tm.text = "";
22 }
23 else
24 {
25 if (tm)
26 tm.text = finish.currTime.text;
27 }
28
29 if (txt)
30 txt.text = finish.currTime.text;
31 if (txt2)
32 txt2.text = finish.currTime.text;
33 }
34 else
35 {
36 if (tm)
37 tm.text = "";
38 if (txt)
39 txt.text = "00:00.00";
40 }
41 }
42}