Skip to content

Return of Reckoning

Wiki

RoR Wiki

API:GetEpochTime

From RoR Wiki
Revision as of 19:43, 16 October 2026 by Maintenance script (talk | contribs) (UI Lua API import (WAR 1.4.8))
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

UI Lua API · Time functions
Version: WAR 1.4.8

Returns the current time as a Unix timestamp, from the computer's clock.

timestamp = GetEpochTime()

Arguments

None.

Returns

timestamp
number – Seconds since 1 January 1970 (UTC).

Details

  • The value comes from the computer's clock, not from the server.
  • It is returned as an unsigned 32-bit value.
  • It can be compared with values from GetTimeStamp.
  • Arguments are not checked; anything passed is ignored.

Errors

None.

Example

From easystem_utils/source/friendsuggester.lua:

local time = GetEpochTime()
if time - GetLastSuggestTime() < lockoutTime
then
    return false
end

See also