Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Ignore a wait function?

Asked by 6 years ago

i have a function that uses wait in a for loop, problem is is when i run the function before the other piece of code it waits to complete the function before going to the next line

any way to make it work in the background without it interfering with the other piece of code?

1 answer

Log in to vote
1
Answered by 6 years ago
Edited 6 years ago

Multi-thread

--[[Spawn(function)
OR
coroutine.wrap(function)()]]--

spawn(function()
--code1
end)

--code2

---------------------------------------
coroutine.wrap(function()
--code1
end)()

--code2
Ad

Answer this question