Adding gang.getOtherGangInformation() function. Rebalancing

This commit is contained in:
danielyxie
2018-10-24 20:26:53 -05:00
parent 58c67415c1
commit c56e18a0f9
6 changed files with 79 additions and 35 deletions
+13
View File
@@ -3579,6 +3579,19 @@ function NetscriptFunctions(workerScript) {
throw makeRuntimeRejectMsg(workerScript, nsGang.unknownGangApiExceptionMessage("getGangInformation", e));
}
},
getOtherGangInformation : function() {
if (workerScript.checkingRam) {
return updateStaticRam("getOtherGangInformation", CONSTANTS.ScriptGangApiBaseRamCost / 2);
}
updateDynamicRam("getOtherGangInformation", CONSTANTS.ScriptGangApiBaseRamCost / 2);
nsGang.checkGangApiAccess(workerScript, "getOtherGangInformation");
try {
return Object.assign(AllGangs);
} catch(e) {
throw makeRuntimeRejectMsg(workerScript, nsGang.unknownGangApiExceptionMessage("getOtherGangInformation", e));
}
},
getMemberInformation : function(name) {
if (workerScript.checkingRam) {
return updateStaticRam("getMemberInformation", CONSTANTS.ScriptGangApiBaseRamCost / 2);