The most common ways to break out of a pair loop, or most loops in that matter, are Return and Break. Return will break but instead of just breaking it will give a value well, “in return”. Break will stop the loop completely, without returning any sort of value. @Scrizonn in that scenario the break will stop the loop it is in( the inner loop), not the outermost
Technically wouldn’t it still give back a value( like if you have a while loop nestled in a function) , but i do see your point that they should be more often used in function
Example of what i mean
function Test()
while true do
wait(.1)
return 5
end
end
print(Test()) -- this will still print 5
Yeah, I could tell from the code sample you knew how to use it. I just wanted to make sure it was clear to anyone else reading this who might not be aware.