A script in luau can be running something in a place that i cannot yield apparently.
This can crash the script in places it really shouldn't especially tight loops.
local text = "1,2,3"
for i=1,100000,1 do
text:match("([^,]+),([^,]+),([^,]+)")
end
Reliably throws
Object [script:New Script] Script run-time error
Unable to perform mandatory yield
[C] function match
This script is a basic example that can trigger it.
This can be caught with pcall... but it'd be nice if we didn't have too
function test()
local text = "1,2,3"
for i=1,100000,1 do
text:match("([^,]+),([^,]+),([^,]+)")
end
end
ll.OwnerSay("Script Starts")
pcall(test)
ll.OwnerSay("Script Continues")