Skip to content
This page was translated from German using AI. If anything is unclear, the German version applies.

HM SimpleTime - Usage

/simpletime (or /wetter) opens the interface. You set the command in config.lua (Config.Command, Config.Aliases, optionally a key with Config.OpenKey). The screenshots show the German interface; with Config.Locale = 'en' it is in English.

Control

  • Time: Drag or tap the slider, use the jump buttons. Switch between Game time and Real time at the top right.
  • Freeze time: The clock stands still until you let it run again.
  • Weather: Tap a tile. Choose the mode at the top right: Manual, Dynamic or Real.
  • Forecast (Dynamic only): the next five weather changes. Reroll creates a new forecast, Change now jumps to the next entry immediately.
  • Blackout, Storm alert and Smooth changes are switched on and off at the bottom.
  • The eye at the top hides the window so you can see the sky. A small bar with time and weather stays at the bottom; Show brings the window back.

Hidden

Automation

Day length, night speed, how often the weather changes and how likely rain, thunder, fog or snow are. Also the city and fetch interval for the real weather and the time zone for real time.

Storm alert

While the alert is active, there is a heavy thunderstorm (configurable). All players get a notice. Before scheduled txAdmin restarts, the alert can start by itself.

All commands work in game and in the server console. German and English sub-commands both work (zeit/time, wetter/weather, frost/freeze, unwetter/storm, modus/mode, an/on, aus/off):

simpletime open the interface (console: show status)
simpletime time 14 30 set the time (14:30 works too)
simpletime weather RAIN set the weather
simpletime freeze [on|off] freeze the clock
simpletime blackout [on|off] blackout
simpletime storm [on|off] storm alert
simpletime mode manual|dynamic|real
simpletime status
local weather = exports.hm_SimpleTime:GetWeather() -- 'RAIN'
local h, m = exports.hm_SimpleTime:GetTime()
local all = exports.hm_SimpleTime:GetAllData() -- hours, mins, weather, blackout, freeze, storm, timeMode, weatherMode, forecast
local fc = exports.hm_SimpleTime:GetForecast() -- { { weather = 'RAIN', inSeconds = 840 }, ... } -- empty unless the mode is dynamic
exports.hm_SimpleTime:GetWeatherMode() -- manual | dynamic | real
exports.hm_SimpleTime:SetTime(14, 30, false) -- third value true = without transition
exports.hm_SimpleTime:SetWeather('THUNDER', false)
exports.hm_SimpleTime:SetBlackout(true)
exports.hm_SimpleTime:SetFreeze(true)
exports.hm_SimpleTime:SetStorm(true)
exports.hm_SimpleTime:SetWeatherMode('dynamic') -- manual | dynamic | real
exports.hm_SimpleTime:SetTimeMode('real') -- game | real
AddEventHandler('hm_SimpleTime:weatherChanged', function(new, old) end)
AddEventHandler('hm_SimpleTime:timeChanged', function(h, m) end) -- only when the clock was set
AddEventHandler('hm_SimpleTime:blackoutChanged', function(active) end)
AddEventHandler('hm_SimpleTime:stormChanged', function(active) end)
exports.hm_SimpleTime:GetWeather()
exports.hm_SimpleTime:GetTime()
exports.hm_SimpleTime:GetAllData() -- + paused, weatherMode, dynamic, forecast
exports.hm_SimpleTime:GetForecast() -- e.g. for a weather app on the phone
exports.hm_SimpleTime:GetWeatherMode()
exports.hm_SimpleTime:IsBlackout()
exports.hm_SimpleTime:PauseSync(true) -- e.g. for interiors or cutscenes: set your own time/weather
exports.hm_SimpleTime:IsSyncPaused()
local data = exports.hm_SimpleTime:GetAllData()
print(data.weather) -- 'CLOUDS'
for _, e in ipairs(exports.hm_SimpleTime:GetForecast()) do
print(e.weather, math.ceil(e.inSeconds / 60)) -- 'RAIN' 14
end
AddEventHandler('hm_SimpleTime:weatherChanged', function(new, old) end)

The forecast only exists in Dynamisch (dynamic) mode. In Manuell (manual) and Echt (real) mode the list is empty. On the client, inSeconds counts down by itself between server updates.