IEnumerator RunFrameTimer() { while (true) { yield return(0); Wheel.AddTickCounter(); } }
public void OnUpdate() { var t = _sw.ElapsedMilliseconds - _lastMilliSecond; while (t - kTickInterval >= 0) { t -= kTickInterval; _lastMilliSecond += kTickInterval; Wheel.AddTickCounter(); Wheel.Tick(); } }