Click or drag to resize
DigitalRuneIGameTimerLostTime Property
Gets the amount of time dropped in the current time step.

Namespace: DigitalRune.Game.Timing
Assembly: DigitalRune.Game (in DigitalRune.Game.dll) Version: 1.4.0.0 (1.4.0.14427)
Syntax
TimeSpan LostTime { get; }

Property Value

Type: TimeSpan
The lost time.
Remarks

In most game timers the maximal time of time step can be limited. For example, see property MaxNumberOfSteps of FixedStepTimer or property MaxDeltaTime of VariableStepTimer. If a time step takes longer than the maximal allowed amount of time, DeltaTime is set to the maximal allowed amount of time, the time above this value is dropped. The dropped time will not be recovered in the next time steps. The time is lost.

This mechanism is necessary to preserve stability in physics simulations or other game components. As a result the game is running slower than real-time (wall clock time), but the simulation stays stable.

LostTime is adjusted each time step and only refers to the current time step. (The lost time of multiple time steps is not accumulated.)

The value is also scaled by Speed. Time, DeltaTime, IdleTime, and LostTime have the same scale. Except that IdleTime and LostTime cannot be negative. They always return the absolute value.

See Also