delay function lua code example
Example 1: wait function lua
function wait(seconds)
local start = os.time()
repeat until os.time() > start + seconds
end
--Exactly the same as the roblox one!
Example 2: sleep function lua
local clock = os.clock
function sleep(n) -- seconds
local t0 = clock()
while clock() - t0 <= n do end
end