Wait Function Lua

[Solved] Wait Function Lua | Lua - Code Explorer | yomemimo.com
Question : wait function lua

Answered by : tes

function wait(seconds) local start = os.time() repeat until os.time() > start + seconds
end
--Exactly the same as the roblox one!

Source : | Last Update : Sat, 14 Nov 20

Question : wait function rebuilt in lua

Answered by : stupid-skipper

function wait(seconds) local start = os.time() repeat until os.time() > start + seconds
end
-- This is the wait function (mostly known from roblox)
-- It works exactly like the roblox version
-- It's used like this: wait(how many seconds)

Source : | Last Update : Sun, 08 Mar 20

Question : wait() in lua

Answered by : sticky

wait(5) -- Waits 5 seconds then prints "Hello world!"
print("Hello world!")

Source : | Last Update : Mon, 15 Mar 21

Question : lua wait function

Answered by : colorful-capuchin-56eefkowov5m

function wait(n)	os.execute("sleep "..tostring(tonumber(n)))
end
-- the reason we're doing this is because lua
-- doesn't have a built in wait function
-- unless it's roblox lua or other types,
-- but this is for vanilla lua

Source : | Last Update : Fri, 04 Mar 22

Question : Wait function lua

Answered by : troubled-termite-ulrqcq82yxkl

local function Wait(s) local c = os.time() repeat until c >= c + s end

Source : | Last Update : Sun, 12 Sep 21

Question : lua wait function

Answered by : fadyzain

wait(5)

Source : | Last Update : Thu, 14 Apr 22

Answers related to wait function lua

Code Explorer Popular Question For Lua