v0.28.5 changes

This commit is contained in:
danielyxie
2017-09-13 09:22:22 -05:00
parent f8ff4cfba6
commit c0369bc937
11 changed files with 129 additions and 85 deletions
+1
View File
@@ -621,6 +621,7 @@ function runScriptFromScript(server, scriptname, args, workerScript, threads=1)
//Check for admin rights and that there is enough RAM availble to run
var script = server.scripts[i];
var ramUsage = script.ramUsage;
threads = Math.round(Number(threads)); //Convert to number and round
ramUsage = ramUsage * threads * Math.pow(CONSTANTS.MultithreadingRAMCost, threads-1);
var ramAvailable = server.maxRam - server.ramUsed;