- Documentation
- Server functions
- setTimeFrozen
Function
setTimeFrozen
Stops or restarts the game clock for every player. A stopped clock keeps a constant time of day (e.g. eternal noon on a racing server). setTime can still change the hour.
Syntax
bool setTimeFrozen([bool frozen = true])Arguments
frozenbool, optional = truetrue= the clock stands still,false= it runs.
Returns
true on success.
Example
setTime(12, 0)
setTimeFrozen(true)
See also
isTimeFrozenChecks whether the game clock is stopped withsetTimeFrozen.resetTimeFrozenRestarts a stopped game clock; the same assetTimeFrozen(false).setTimeSets the in-game time for every player. From then on the clock keeps running by itself (unless it is stopped withsetTimeFrozen); one game minute lasts one second by default (setMinuteDuration). The time of day changes the lighting, the sky colour and whether it is dark.