Skip to main content

Time

Complete API reference for Time, including constructors, attributes, virtual attributes, and methods.

Package: JAVARuntime

Category: Time

Component: no


public class Time

Virtual Attributes

NameTypeAccessDescription
deltaTimefloatgetReturns the time (in seconds) between the last frame and the current one.
frameTimefloatgetReturns the time (in seconds) between the last frame and the current one.
timeScalefloatget/setReturns the current time scale.
timeSpeedfloatget/setReturns the current time speed.
unscaledDeltaTimefloatgetReturns the time (in seconds) between the last frame and the current one without time scale (real time).
unscaledFrameTimefloatgetReturns the time (in seconds) between the last frame and the current one without time scale (real time).

Static Methods

SignatureReturnsDescription
deltaTime()floatReturns the time (in seconds) between the last frame and the current one.
getDeltaTime()ObjectReturns the current deltaTime value.
frameTime()floatReturns the time (in seconds) between the last frame and the current one.
getFrameTime()ObjectReturns the current frameTime value.
unscaledDeltaTime()floatReturns the time (in seconds) between the last frame and the current one without time scale (real time).
getUnscaledDeltaTime()ObjectReturns the current unscaledDeltaTime value.
getUnscaledFrameTime()ObjectReturns the current unscaledFrameTime value.
getTimeSpeed()ObjectReturns the current timeSpeed value.
setTimeSpeed(float)ObjectSets timeSpeed.
getTimeScale()ObjectReturns the current timeScale value.
setTimeScale(float)ObjectSets timeScale.