mirror of https://github.com/OpenTTD/OpenTTD
Fix: [Script] SQOpsLimiter had no effect for native valuator/filter (#14322)
parent
ea0b3983a5
commit
9e8fc8da48
|
@ -977,6 +977,10 @@ SQRESULT sq_call(HSQUIRRELVM v,SQInteger params,SQBool retval,SQBool raiseerror,
|
||||||
if(!v->_suspended) {
|
if(!v->_suspended) {
|
||||||
v->Pop(params);//pop closure and args
|
v->Pop(params);//pop closure and args
|
||||||
}
|
}
|
||||||
|
if (!v->_can_suspend && v->IsOpsTillSuspendError()) {
|
||||||
|
v->Raise_Error(fmt::format("excessive CPU usage in {}", v->_ops_till_suspend_error_label));
|
||||||
|
return SQ_ERROR;
|
||||||
|
}
|
||||||
if(retval){
|
if(retval){
|
||||||
v->Push(res); return SQ_OK;
|
v->Push(res); return SQ_OK;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue