Answers for "how to make an infinite loop in lua"

C
1

infinite loop lua

-- We need to create a wait function to slow down the while true do loop.
-- The loop will run so fast, that we need to slow it down. Otherwise, it'll crash.

function wait(seconds)
  local start = os.time() 
  repeat until os.time() > start + seconds
end

while true do -- Create the infinite loop
	print("Hello World")
   	
    wait(1) -- The number you place in the paramater is how many seconds it will wait until looping again.
end
Posted by: Guest on September-26-2020
4

lua how to make a loop

for init,max/min value, increment
do
   statement(s)
end
Posted by: Guest on April-20-2020
0

lua infinite

for i=0, math.huge do

end
Posted by: Guest on March-19-2020

Code answers related to "how to make an infinite loop in lua"

Code answers related to "C"

Browse Popular Code Answers by Language