/// <summary> /// Update Timer UI in game loop /// </summary> /// <param name="sender">object that call event</param> /// <param name="e">info</param> public void UpdateTimerUI(object sender, TimerUpdateUIEventArgs e) { timerText.text = e.CurrentTime.ToString("0.0"); timerBar.transform.localScale = new Vector3(e.CurrentTime / e.AllTime, timerBar.transform.localScale.y, 1); }
protected void UpdateTimerUI(TimerUpdateUIEventArgs args) { updateTimerUIEvent?.Invoke(this, args); }