Paradox Game Engine  v1.0.0 beta06
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Events Macros Pages
SiliconStudio.Paradox.Games.GameTime Class Reference

Current timing used for variable-step (real time) or fixed-step (game time) games. More...

Public Member Functions

 GameTime ()
 Initializes a new instance of the GameTime class. More...
 
 GameTime (TimeSpan totalTime, TimeSpan elapsedTime)
 Initializes a new instance of the GameTime class. More...
 
 GameTime (TimeSpan totalTime, TimeSpan elapsedTime, bool isRunningSlowly)
 Initializes a new instance of the GameTime class. More...
 

Properties

TimeSpan Elapsed [get, set]
 Gets the elapsed game time since the last update More...
 
bool IsRunningSlowly [get, set]
 Gets a value indicating whether the game is running slowly than its TargetElapsedTime. This can be used for example to render less details...etc. More...
 
TimeSpan Total [get, set]
 Gets the amount of game time since the start of the game. More...
 
int FrameCount [get, set]
 Gets the current frame count since the start of the game. More...
 
float FramePerSecond [get, set]
 Gets the number of frame per second (FPS) for the current running game. More...
 
TimeSpan TimePerFrame [get, set]
 Gets the time per frame. More...
 
bool FramePerSecondUpdated [get, set]
 Gets a value indicating whether the FramePerSecond and TimePerFrame were updated for this frame. More...
 

Detailed Description

Current timing used for variable-step (real time) or fixed-step (game time) games.

Definition at line 31 of file GameTime.cs.

Constructor & Destructor Documentation

SiliconStudio.Paradox.Games.GameTime.GameTime ( )

Initializes a new instance of the GameTime class.

Definition at line 41 of file GameTime.cs.

SiliconStudio.Paradox.Games.GameTime.GameTime ( TimeSpan  totalTime,
TimeSpan  elapsedTime 
)

Initializes a new instance of the GameTime class.

Parameters
totalTimeThe total game time since the start of the game.
elapsedTimeThe elapsed game time since the last update.

Definition at line 51 of file GameTime.cs.

SiliconStudio.Paradox.Games.GameTime.GameTime ( TimeSpan  totalTime,
TimeSpan  elapsedTime,
bool  isRunningSlowly 
)

Initializes a new instance of the GameTime class.

Parameters
totalTimeThe total game time since the start of the game.
elapsedTimeThe elapsed game time since the last update.
isRunningSlowlyTrue if the game is running unexpectedly slowly.

Definition at line 64 of file GameTime.cs.

Property Documentation

TimeSpan SiliconStudio.Paradox.Games.GameTime.Elapsed
getset
int SiliconStudio.Paradox.Games.GameTime.FrameCount
getset

Gets the current frame count since the start of the game.

Definition at line 97 of file GameTime.cs.

Referenced by SiliconStudio.Paradox.Graphics.Regression.GraphicsTestBase.Draw(), and SiliconStudio.Paradox.Graphics.Regression.TestGameBase.Update().

float SiliconStudio.Paradox.Games.GameTime.FramePerSecond
getset

Gets the number of frame per second (FPS) for the current running game.

The frame per second.

Definition at line 103 of file GameTime.cs.

bool SiliconStudio.Paradox.Games.GameTime.FramePerSecondUpdated
getset

Gets a value indicating whether the FramePerSecond and TimePerFrame were updated for this frame.

true if the FramePerSecond and TimePerFrame were updated for this frame; otherwise, false.

Definition at line 115 of file GameTime.cs.

bool SiliconStudio.Paradox.Games.GameTime.IsRunningSlowly
getset

Gets a value indicating whether the game is running slowly than its TargetElapsedTime. This can be used for example to render less details...etc.

true if this instance is running slowly; otherwise, false.

Definition at line 86 of file GameTime.cs.

TimeSpan SiliconStudio.Paradox.Games.GameTime.TimePerFrame
getset

Gets the time per frame.

The time per frame.

Definition at line 109 of file GameTime.cs.

TimeSpan SiliconStudio.Paradox.Games.GameTime.Total
getset

Gets the amount of game time since the start of the game.

The total game time.

Definition at line 92 of file GameTime.cs.


The documentation for this class was generated from the following file: