fixes + throwparty and buytea and rundist
This commit is contained in:
9
Mizzajl/home/corp/BuyTea.js
Normal file
9
Mizzajl/home/corp/BuyTea.js
Normal file
@@ -0,0 +1,9 @@
|
||||
/** @param {NS} ns */
|
||||
export async function main(ns) {
|
||||
let [sDivName, sCity] = ns.args;
|
||||
//ns.tprint("sDivName = " + sDivName);
|
||||
//ns.tprint("sCity = " + sCity);
|
||||
let bSuccess = ns.corporation.buyTea(sDivName, sCity)
|
||||
//ns.tprint("bSuccess = " + bSuccess);
|
||||
ns.writePort(ns.pid, bSuccess);
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
/** @param {NS} ns */
|
||||
export async function main(ns) {
|
||||
ns.writePort(ns.pid, ns.corporation.getCorporation());
|
||||
ns.writePort(ns.pid,ns.corporation.getCorporation());
|
||||
}
|
||||
@@ -14,7 +14,7 @@ export async function main(ns) {
|
||||
(oCurrentOffice.employeeJobs.Management < aWorkerDistribution[3]) ? ns.corporation.hireEmployee(sDivName, sCity, "Management") : "";
|
||||
(oCurrentOffice.employeeJobs["Research & Development"] < aWorkerDistribution[4]) ? ns.corporation.hireEmployee(sDivName, sCity, "Research & Development") : "";
|
||||
(oCurrentOffice.employeeJobs.Intern < aWorkerDistribution[5]) ? ns.corporation.hireEmployee(sDivName, sCity, "Intern") : "";
|
||||
await ns.sleep(1);
|
||||
await ns.sleep(1)
|
||||
i += 1;
|
||||
};
|
||||
ns.writePort(ns.pid, true);
|
||||
|
||||
10
Mizzajl/home/corp/ThrowParty.js
Normal file
10
Mizzajl/home/corp/ThrowParty.js
Normal file
@@ -0,0 +1,10 @@
|
||||
/** @param {NS} ns */
|
||||
export async function main(ns) {
|
||||
let [sDivName, sCity, nSpend] = ns.args;
|
||||
//ns.tprint("sDivName = " + sDivName);
|
||||
//ns.tprint("sCity = " + sCity);
|
||||
//ns.tprint("nSpend = " + nSpend);
|
||||
let nMoraleMultiplier = ns.corporation.throwParty(sDivName, sCity, nSpend)
|
||||
//ns.tprint("nMoraleMultiplier = " + nMoraleMultiplier);
|
||||
ns.writePort(ns.pid, nMoraleMultiplier);
|
||||
}
|
||||
Reference in New Issue
Block a user