KernelAPI reference
Class WorldClock
Namespace: MicroEngine.Scenes
Assembly: MicroEngine.Scene.dll
Guide: Scenes
A world’s own time: a time scale and freezes (hitstop) on top of the engine’s fixed step. It advances as part of its world’s step (BeginStep), once per step: a world that does not step (paused, under an overlay) consumes no time and no freeze.
public sealed class WorldClockInheritance
Constructors
WorldClock()
public WorldClock()Properties
Delta
Scaled length of the latest step (0 while frozen or at scale 0).
public float Delta { get; }Property Value
FreezeRemaining
Seconds of freeze left. Steps subtract their unscaled length while it is positive, so the last frozen step may leave it slightly below zero (the whole step was frozen); it is not frozen when it is 0 or less.
public float FreezeRemaining { get; }Property Value
Frozen
Whether the next step is frozen.
public bool Frozen { get; }Property Value
Scale
Multiplies the step (0 pauses, 0.5 is slow motion); 1 by default.
public float Scale { get; set; }Property Value
Exceptions
The value is negative.
Time
Scaled seconds this world has advanced (freezes and scale applied).
public double Time { get; }Property Value
Methods
Freeze(float)
Freezes the world for at least seconds of unscaled step time (the longer freeze wins). Hitstop is a freeze.
public void Freeze(float seconds)Parameters
seconds float
Unfreeze()
Ends a freeze now.
public void Unfreeze()