Struct HexTerrainSimulationTimer
Implements
Inherited Members
Namespace: Fwt.HexTerrains.Simulations.Data
Assembly: fwt.hexterrains.dll
Syntax
public struct HexTerrainSimulationTimer : IComponentData, IQueryTypeParameter
Fields
DeltaTime
The time elapsed since the last simulation frame in seconds. This is the time that has passed in the simulation since the last update.
Declaration
public float DeltaTime
Field Value
| Type | Description |
|---|---|
| float |
Elapsed
The total elapsed time in seconds since the simulation started. This is the total time that has passed in the simulation, it's not always the elapsed game time.
Declaration
public double Elapsed
Field Value
| Type | Description |
|---|---|
| double |
FixedTimeStep
The fixed time step in seconds for the simulation. This value is used when IsFixedTimeStep is true to determine the time between simulation frames.
Declaration
public float FixedTimeStep
Field Value
| Type | Description |
|---|---|
| float |
FrameCount
The number of simulation frames that have been processed in the simulation.
Declaration
public long FrameCount
Field Value
| Type | Description |
|---|---|
| long |
IsFixedTimeStep
If true, the simulation runs with a fixed time step defined by FixedTimeStep. If false, the simulation runs with a variable time step based on DeltaTime.
Declaration
public bool IsFixedTimeStep
Field Value
| Type | Description |
|---|---|
| bool |
IsPaused
If true, the simulation is paused and does not advance.
Declaration
public bool IsPaused
Field Value
| Type | Description |
|---|---|
| bool |
IsTickAndPause
If true, the simulation will tick once and then pause. This is useful for debugging, allowing you to step through the simulation one frame at a time.
Declaration
public bool IsTickAndPause
Field Value
| Type | Description |
|---|---|
| bool |
SimulationDelay
This amount of frames will be skipped between each simulation frames. 0 meas no frames will be skipped, 1 means every other frame will be simulated, 2 means every third frame will be simulated, and so on. This allows you to control the frequency of the simulation updates, which can be useful for performance optimization or for creating slow-motion effects.
Declaration
public int SimulationDelay
Field Value
| Type | Description |
|---|---|
| int |
SimulationDelayCounter
Current counter for the simulation delay. When this counter reaches SimulationDelay, the simulation will run and the counter will reset to 0. This allows you to control how often the simulation updates, effectively skipping frames if needed.
Declaration
public int SimulationDelayCounter
Field Value
| Type | Description |
|---|---|
| int |
TimeScale
The time scale for the simulation. A value of 1.0 means real-time, 2.0 means double speed, and 0.5 means half speed.
Declaration
public float TimeScale
Field Value
| Type | Description |
|---|---|
| float |