void Start() { playerControl = GameObject.Find("Player").GetComponent <PlayerControl>(); _time = _second + _mileSecond * 1.0f / 1000; _Count = IsCountOK.NOTOK; // reStartCountDown(); }
//private IEnumerator CountDownT() //{ // _time = int.Parse(TimeCountDown.text); // while (_time > 0) // { // yield return new WaitForSeconds(1/1000); // _time -= 1; // TimeCountDown.text = _time + ""; // } //} public void CountStop() { //_hour = 0; //_minute = 0; //_second = 0; //_mileSecond = 000; _Count = IsCountOK.NOTOK; TimeCountDown.text = string.Format("{0:D2}:{1:D2}.{2:D3}", _minute, _second, _mileSecond); }
public void TimePause() { if (_second != 0) { if (_Count == IsCountOK.OK) { _Count = IsCountOK.NOTOK; } else { _Count = IsCountOK.OK; } } }
public void reStartCountDown() { _time = 0; _Count = IsCountOK.OK; }