Will using break in a scope end any functions running in a separate thread under the same scope? If not, is there a way to do this efficiently? For instance,
i = 5
function Thingy()
function FunctionInOtherThread()
if i = 5 then
for a = 1, 5 do
print("i = 5")
wait(10)
end
end
end
spawn(FunctionInOtherThread)
repeat
print("repeating til I break")
until i == 6
if i == 6 then break --If I break here, will it end/stop/break FunctionInOtherThread(), in the other thread?
end
Like I wrote in the comment, would the FunctionInotherThread() break if I break Thingy()? Any help is appreciated, thanks!
P.S. I made that code up on the fly for an example, just saying. :)
