Merge pull request #4492 from Abextm/run-script-recursion

mixins: Prevent runScript from being called recursively
This commit is contained in:
Adam
2018-07-26 18:56:31 -04:00
committed by GitHub

View File

@@ -130,6 +130,7 @@ public abstract class ScriptVMMixin implements RSClient
public void runScript(int id, Object... args)
{
assert isClientThread();
assert currentScript == null;
Object[] cargs = new Object[args.length + 1];
cargs[0] = id;
System.arraycopy(args, 0, cargs, 1, args.length);