working on Mizzajl/home/wip/scanFactionAugments.js

This commit is contained in:
Mizzajl committed 2024-10-07 12:01:02 +02:00
1 parent 38947d3d81
commit 6378dc3d7b
5 files changed
+42 -14

No files matched your search

+3
View File
@@ -0,0 +1,3 @@
Mizzajl/home/bestTarget.txt
Mizzajl/home/ServerRouteList.txt
Mizzajl/home/serverList.txt
+1 -1
View File
@@ -1 +1 @@
{"home":{"n00dles":{"nectar-net":{"phantasy":{"netlink":{},"crush-fitness":{},"avmnite-02h":{"rothman-uni":{},"summit-uni":{},"syscore":{"lexo-corp":{"global-pharm":{"deltaone":{"defcomm":{"taiyang-digital":{"applied-energetics":{"stormtech":{".":{"nwo":{"ecorp":{},"The-Cave":{}}}}},"run4theh111z":{"fulcrumtech":{"omnitek":{"clarkinc":{}}},"vitalife":{"4sigma":{"b-and-a":{}}}}}},"icarus":{"nova-med":{"microdyne":{"helios":{"kuai-gong":{"blade":{"megacorp":{}},"powerhouse-fitness":{"fulcrumassets":{}}}}}}}}}},"rho-construction":{},"millenium-fitness":{"aerocorp":{"omnia":{"solaris":{}}},"snap-fitness":{"unitalife":{"univ-energy":{"infocomm":{}},"zeus-med":{"zb-def":{"titan-labs":{}}}}}}}}}}},"foodnstuff":{},"sigma-cosmetics":{"zer0":{"omega-net":{"the-hub":{},"johnson-ortho":{}}},"max-hardware":{}},"joesguns":{},"hong-fang-tea":{},"harakiri-sushi":{},"iron-gym":{"CSEC":{"neo-net":{"computek":{"zb-institute":{"alpha-ent":{},"aevum-police":{"galactic-cyber":{}}},"catalyst":{},"I.I.I.I":{}}},"silver-helix":{}}},"darkweb":{}}}
{"home":{"n00dles":{"nectar-net":{"phantasy":{"netlink":{},"crush-fitness":{},"avmnite-02h":{"rothman-uni":{},"summit-uni":{},"syscore":{"lexo-corp":{"global-pharm":{"deltaone":{"defcomm":{"taiyang-digital":{"applied-energetics":{"stormtech":{".":{"nwo":{"ecorp":{},"The-Cave":{}}}}},"run4theh111z":{"fulcrumtech":{"omnitek":{"clarkinc":{}}},"vitalife":{"4sigma":{"b-and-a":{}}}}}},"icarus":{"nova-med":{"microdyne":{"helios":{"kuai-gong":{"blade":{"megacorp":{}},"powerhouse-fitness":{"fulcrumassets":{}}}}}}}}}},"rho-construction":{},"millenium-fitness":{"aerocorp":{"omnia":{"solaris":{}}},"snap-fitness":{"unitalife":{"univ-energy":{"infocomm":{}},"zeus-med":{"zb-def":{"titan-labs":{}}}}}}}}}}},"foodnstuff":{},"sigma-cosmetics":{"zer0":{"omega-net":{"the-hub":{},"johnson-ortho":{}}},"max-hardware":{}},"joesguns":{},"hong-fang-tea":{},"harakiri-sushi":{},"iron-gym":{"CSEC":{"neo-net":{"computek":{"zb-institute":{"alpha-ent":{},"aevum-police":{"galactic-cyber":{}}},"catalyst":{},"I.I.I.I":{}}},"silver-helix":{}}},"darkweb":{},"pserv-00":{},"pserv-01":{},"pserv-02":{},"pserv-03":{},"pserv-04":{},"pserv-05":{},"pserv-06":{},"pserv-07":{},"pserv-08":{},"pserv-09":{},"pserv-10":{},"pserv-11":{},"pserv-12":{},"pserv-13":{},"pserv-14":{},"pserv-15":{},"pserv-16":{},"pserv-17":{},"pserv-18":{},"pserv-19":{},"pserv-20":{},"pserv-21":{},"pserv-22":{},"pserv-23":{},"pserv-24":{}}}
+1 -1
View File
@@ -1 +1 @@
{"serverName":"the-hub","maxRam":64,"maxMoney":440206450.3125,"minSec":13,"minPorts":2,"minHackLvl":298,"rootAccess":true,"openPorts":0,"serverOrgs":"The Hub","serverCores":2,"serverFiles":[]}
{"serverName":"clarkinc","maxRam":0,"maxMoney":56342049041.25,"minSec":15,"minPorts":5,"minHackLvl":1195,"rootAccess":true,"openPorts":0,"serverOrgs":"Clarke Incorporated","serverCores":14,"serverFiles":["beyond-man.lit","cost-of-immortality.lit"]}
+1 -1
View File
@@ -1 +1 @@
{"home":{"serverName":"home","maxRam":4194304,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"Home PC","serverCores":7,"serverFiles":["AutoLink.exe","BruteSSH.exe","CrackAndRootAll.js","DeepscanV1.exe","DeepscanV2.exe","EveryServerRun.js","FTPCrack.exe","HTTPWorm.exe","Library.js","NUKE.exe","RMgrow.js","RMhack.js","RMweaken.js","Ramses/Backdoor.js","Ramses/ContractSolver.js","Ramses/ContractSolverRamses.js","Ramses/CorpControl.js","Ramses/CrackAndRootAll.js","Ramses/RamsesUtils.js","Ramses/S4controller.js","Ramses/S4logHelper.js","Ramses/S4tGrow.js","Ramses/S4tHack.js","Ramses/S4tWeaken.js","Ramses/S4utils.js","Ramses/Serverlist.js","Ramses/analyzeContract.js","Ramses/corp/Autosell.js","Ramses/corp/HireWorkers.js","Ramses/corp/SetupExport.js","Ramses/corp/Smart.js","Ramses/corp/UpgradeOffice.js","Ramses/killAllScript.js","Ramses/purchaseServers.js","SQLInject.exe","ServerRouteList.txt","Serverlist.js","Updatebesttarget.js","algorithm.js","ascii/detective.txt","ascii/detective2.txt","ascii/detective3.txt","ascii/hacker.txt","ascii/judge.txt","ascii/noir.txt","ascii/sonic.js","autoexec.js","b1t_flum3.exe","backdoor.js","backup/batch2.js","backup/bitnodeStart.js","backup/growrepeater.js","backup/maxGrow.js","backup/myLibrary.js","backup/serverlister.js","backup/upgrade.js","batch.js","bestTarget.txt","breach.js","contract.js","csec-test.msg","factionboost.js","fl1ght.exe","gang/argFunctions.js","gang/auto-gang.js","gang/auto-gang2.js","gang/gangManager.js","hackers-starting-handbook.lit","hacknet/hacknetmanager.js","j0.msg","j1.msg","j2.msg","j3.msg","killAllScripts.js","nitesec-test.msg","notes.txt","purchaseServers.js","relaySMTP.exe","serverList.txt","settings.txt","sharePserv.js","singularity/RMroutelist.js","singularity/manualalgo.js","wip/Minimum_Path_Sum_in_a_Triangle.js","wip/RMbreach.js","wip/RMcontroller.js","wip/progress.js","wip/pserv.js","wip/scanFactionAugments.js","wip/test.js","wip/testhackgrow.js"]},"pserv-24":{"serverName":"pserv-24","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":[]},"pserv-23":{"serverName":"pserv-23","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":[]},"pserv-22":{"serverName":"pserv-22","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":[]},"pserv-21":{"serverName":"pserv-21","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":[]},"pserv-20":{"serverName":"pserv-20","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":[]},"pserv-19":{"serverName":"pserv-19","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":[]},"pserv-18":{"serverName":"pserv-18","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":[]},"pserv-17":{"serverName":"pserv-17","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":[]},"pserv-16":{"serverName":"pserv-16","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":[]},"pserv-15":{"serverName":"pserv-15","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":[]},"pserv-14":{"serverName":"pserv-14","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":[]},"pserv-13":{"serverName":"pserv-13","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":[]},"pserv-12":{"serverName":"pserv-12","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":[]},"pserv-11":{"serverName":"pserv-11","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":[]},"pserv-10":{"serverName":"pserv-10","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":[]},"pserv-09":{"serverName":"pserv-09","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":[]},"pserv-08Line truncated
{"home":{"serverName":"home","maxRam":4194304,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"Home PC","serverCores":8,"serverFiles":["19dfj3l1nd.msg","AutoLink.exe","BruteSSH.exe","CrackAndRootAll.js","DeepscanV1.exe","DeepscanV2.exe","EveryServerRun.js","FTPCrack.exe","HTTPWorm.exe","Library.js","NUKE.exe","RMgrow.js","RMhack.js","RMweaken.js","Ramses/Backdoor.js","Ramses/ContractSolver.js","Ramses/ContractSolverRamses.js","Ramses/CorpControl.js","Ramses/CrackAndRootAll.js","Ramses/RamsesUtils.js","Ramses/S4controller.js","Ramses/S4logHelper.js","Ramses/S4tGrow.js","Ramses/S4tHack.js","Ramses/S4tWeaken.js","Ramses/S4utils.js","Ramses/Serverlist.js","Ramses/analyzeContract.js","Ramses/corp/Autosell.js","Ramses/corp/HireWorkers.js","Ramses/corp/SetupExport.js","Ramses/corp/Smart.js","Ramses/corp/UpgradeOffice.js","Ramses/killAllScript.js","Ramses/purchaseServers.js","SQLInject.exe","ServerRouteList.txt","Serverlist.js","Updatebesttarget.js","algorithm.js","ascii/detective.txt","ascii/detective2.txt","ascii/detective3.txt","ascii/hacker.txt","ascii/judge.txt","ascii/noir.txt","ascii/sonic.js","autoexec.js","b1t_flum3.exe","backdoor.js","backup/batch2.js","backup/bitnodeStart.js","backup/growrepeater.js","backup/maxGrow.js","backup/myLibrary.js","backup/serverlister.js","backup/upgrade.js","batch.js","bestTarget.txt","breach.js","contract.js","csec-test.msg","factionboost.js","fl1ght.exe","gang/argFunctions.js","gang/auto-gang.js","gang/auto-gang2.js","gang/gangManager.js","hackers-starting-handbook.lit","hacknet/hacknetmanager.js","j0.msg","j1.msg","j2.msg","j3.msg","j4.msg","killAllScripts.js","nitesec-test.msg","notes.txt","purchaseServers.js","relaySMTP.exe","serverList.txt","settings.txt","sharePserv.js","singularity/RMroutelist.js","singularity/manualalgo.js","wip/Minimum_Path_Sum_in_a_Triangle.js","wip/RMbreach.js","wip/RMcontroller.js","wip/progress.js","wip/pserv.js","wip/scanFactionAugments.js","wip/test.js","wip/testhackgrow.js"]},"pserv-24":{"serverName":"pserv-24","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":["Library.js","RMgrow.js","RMhack.js","RMweaken.js","batch.js","factionboost.js","settings.txt"]},"pserv-23":{"serverName":"pserv-23","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":["Library.js","RMgrow.js","RMhack.js","RMweaken.js","batch.js","factionboost.js","settings.txt"]},"pserv-22":{"serverName":"pserv-22","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":["Library.js","RMgrow.js","RMhack.js","RMweaken.js","batch.js","factionboost.js","settings.txt"]},"pserv-21":{"serverName":"pserv-21","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":["Library.js","RMgrow.js","RMhack.js","RMweaken.js","batch.js","factionboost.js","settings.txt"]},"pserv-20":{"serverName":"pserv-20","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":["Library.js","RMgrow.js","RMhack.js","RMweaken.js","batch.js","factionboost.js","settings.txt"]},"pserv-19":{"serverName":"pserv-19","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":["Library.js","RMgrow.js","RMhack.js","RMweaken.js","batch.js","factionboost.js","settings.txt"]},"pserv-18":{"serverName":"pserv-18","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":["Library.js","RMgrow.js","RMhack.js","RMweaken.js","batch.js","factionboost.js","settings.txt"]},"pserv-17":{"serverName":"pserv-17","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":["Library.js","RMgrow.js","RMhack.js","RMweaken.js","batch.js","factionboost.js","settings.txt"]},"pserv-16":{"serverName":"pserv-16","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":["Library.js","RMgrow.js","RMhack.js","RMweaken.js","batch.js","factionboost.js","settings.txt"]},"pserv-15":{"serverName":"pserv-15","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCores":1,"serverFiles":["Library.js","RMgrow.js","RMhack.js","RMweaken.js","batch.js","factionboost.js","settings.txt"]},"pserv-14":{"serverName":"pserv-14","maxRam":1048576,"maxMoney":0,"minSec":1,"minPorts":5,"minHackLvl":1,"rootAccess":true,"openPorts":4,"serverOrgs":"","serverCoresLine truncated
+36 -11
View File
@@ -1,24 +1,49 @@
/** @param {NS} ns */
export async function main(ns) {
let aFactions = ns.getPlayer().factions;
const aOwnedAugmentations = ns.singularity.getOwnedAugmentations(true);
//ns.tprint("aOwnedAugmentations = " + aOwnedAugmentations);
const aFactions = ns.getPlayer().factions;
ns.tprint("aFactions = " + aFactions);
let aAugmentations;
let sStats;
let aStats;
for (let f = 0; f < aFactions.length; f++) {
//ns.tprint("f = " + f);
//sFaction = ns.singularity.faction
//loop throught the factions
ns.tprint("Faction = " + aFactions[f]);
aAugmentations = ns.singularity.getAugmentationsFromFaction(aFactions[f]);
ns.tprint("aAugmentations = " + aAugmentations);
let aAvailableAugmentations = aAugmentations.filter(item => !aOwnedAugmentations.includes(item)); //ChatGPT
//ns.tprint("aAugmentations = " + aAugmentations);
ns.tprint("aAvailableAugmentations = " + aAvailableAugmentations);
ns.tprint("----------------------------------------------------------------------------------------------------------------------------------------------------------");
for (let a = 0; a < aFactions.length; a++) {
sStats = JSON.stringify(ns.singularity.getAugmentationStats(aAugmentations[a]));
ns.tprint(aAugmentations[f] + "sStats = " + sStats);
for (let a = 0; a < aAvailableAugmentations.length; a++) {
//loop throught their aumentations
//if (aOwnedAugmentations.includes(aAvailableAugmentations[a]) === false) {
//JSON.stringify(ns.singularity.getAugmentationStats(aAvailableAugmentations[a]));
let oStats = ns.singularity.getAugmentationStats(aAvailableAugmentations[a]);
ns.tprint(aAvailableAugmentations[a]);
let nAugmentationReputation = ns.singularity.getAugmentationRepReq(aAvailableAugmentations[a]);
let sAugmentationPrereq = ns.singularity.getAugmentationPrereq(aAvailableAugmentations[a]);
let nAugmentationPrice = ns.singularity.getAugmentationPrice(aAvailableAugmentations[a]);
ns.tprint("Reputation needed = " + nAugmentationReputation);
ns.tprint("Prereq = " + sAugmentationPrereq);
ns.tprint("Price = " + nAugmentationPrice);
// ChatGPT - Iterate through the object and display properties where the value is not 1
for (const key in oStats) {
if (oStats[key] !== 1) {
//console.log(`${key}: ${oStats[key]}`);
ns.tprint(`${key}: ${oStats[key]}`);
}
}
//ns.tprint(aAvailableAugmentations.filter(index !== 1) + " aStats = " + aStats);
//ns.tprint(aAvailableAugmentations[a] + " oStats = " + oStats);
ns.tprint("----------------------------------------------------------------------------------------------------------------------------------------------------------");
}
}
}