public void notify() { if (myIsPaused == true) { return; } myFrameTime = TimeSource.timeThisFrame() * myTimeScale; myCurrentTime += myFrameTime; foreach (Timer t in myTimers) { if (t.notify() == false) { releaseTimer(t); } } //remove any old timers foreach (Timer t in myReleaseTimers) { myTimers.Remove(t); } myReleaseTimers.Clear(); }
internal Clock(double setTime) { myTimeScale = 1.0; myIsPaused = false; myPauseTime = 0.0; myCurrentTime = setTime; myFrameTime = TimeSource.timeThisFrame(); }
public Clock() { myTimeScale = 1.0; myIsPaused = false; myPauseTime = 0.0; myCurrentTime = TimeSource.defaultClock.currentTime(); myFrameTime = TimeSource.timeThisFrame(); }