Skip to content
Divran edited this page Apr 22, 2021 · 4 revisions

Jump to table of contents

Timer

interval(Number Rv1)

Sets a one-time timer with name "interval" and delay in milliseconds (minimum delay for timers is 10ms) (20 ops)

timer(String Rv1, Number Rv2)

Sets a one-time timer with entered name and delay in milliseconds (20 ops)

stoptimer(String Rv1)

Stops a timer, can stop interval with stoptimer("interval") (5 ops)

Number = clk()

Returns 1 if the current execution was caused by the interval (1 ops)

Number = clk(String Rv1)

Returns 1 if the current execution was caused by the inserted name (1 ops)

String = clkName()

Returns the name of the timer that caused current execution (1 ops)

Array = getTimers()

Returns an array of all timers used in the E2 (1 ops)

stopAllTimers()

Stops all timers (1 ops)

Number = curtime()

Returns the current game time since server-start in seconds (1 ops)

Number = realtime()

Returns the current real time since server-start in seconds (1 ops)

Number = systime()

Returns a highly accurate time (also in seconds) since the server was started. Ideal for benchmarking (1 ops)

Table = date()

Returns the server's current time and date (10 ops)

Table = date(Number Time)

Returns the specified unix time (10 ops)

Table = dateUTC()

Returns the server's current time and date in UTC (10 ops)

Table = dateUTC(Number Time)

Returns the specified unix time in UTC (10 ops)

Number = time(String Component)

Returns numerical time/date info from the server. Possible arguments: "year", "month", "day", "hour", "min", "sec", "wday" (weekday, Sunday is 1), "yday" (day of the year), and "isdst" (daylight saving flag 0/1) (10 ops)

Number = time()

Returns the time in seconds (2 ops)

Number = time(Table Data)

Attempts to construct the time from the data in the given table (same as lua's os.time). The table structure must be the same as in the date() functions. If any values are missing or of the wrong type, that value is ignored (it will be nil) (2 ops)

Expression 2 ⚛️

Tutorials (In learning order) 🎓

Extras ❔

Tools 🛠️

Click To Expand

Advanced

Beacon 💡

Control 🎛️

Data 💿

Detection 👀

Display 💻

Render

I/O 🔌

Physics 🚀

Utilities 🛠️

RFID

Wireless 🛜

Gates 🚥

Click To Expand

TBD

Clone this wiki locally