mirror of
https://github.com/aharabada/glitchy-engine-beef.git
synced 2026-09-05 21:01:52 +00:00
24 lines
619 B
C#
24 lines
619 B
C#
namespace DotNetScriptingHelper;
|
|
|
|
public class GameTime
|
|
{
|
|
private ulong _frameCount;
|
|
|
|
private TimeSpan _totalTime;
|
|
private TimeSpan _frameTime;
|
|
|
|
public ulong FrameCount => _frameCount;
|
|
public TimeSpan TotalTime => _totalTime;
|
|
public TimeSpan FrameTime => _frameTime;
|
|
|
|
public float DeltaTime => (float)_frameTime.TotalSeconds;
|
|
public float TotalSeconds => (float)_totalTime.TotalSeconds;
|
|
|
|
internal GameTime(ulong frameCount, TimeSpan totalTime, TimeSpan frameTime)
|
|
{
|
|
_frameCount = frameCount;
|
|
_totalTime = totalTime;
|
|
_frameTime = frameTime;
|
|
}
|
|
}
|