Quick actions

cmd+k|ctrl+k

Navigation

Languages

Code Delay

Snippet info

Language

Lua

Visibility

public

Author

ren

Created

2022-06-24T18:10:55.051384Z

Updated

2022-10-11T20:37:56.111425Z

--[[
Code delay
]]


Delay = function(Time)
    if Time ~= nil then
       if type(Time) == "number" then
           if Time > 0 then
               start = os.clock()
              repeat until  os.clock() > start+Time
           end
           else
               error("Argument must be a number",2)
       end
        else
         start = os.clock()
         repeat until  os.clock() > start+0.01
    end
   
end
INFO