Comments (6)
Did a chunk of work on this today. Prioritized turning crashes into errors and intentional shutdowns where necessary, but haven't gotten rid of all alerts yet, so leaving this open until it's cleaner
from bitburner-scripts.
Thanks for the list. I didn't want to hard-code it in the script itself because my intent is for people to use it with their own repositories, and I didn't see an easy way to get a repository listing from github, so I have it as a "TODO" in there.
As for the other request, sadly letting errors happening, and catching them, is the "best" way to detect functionality missing due to the current BN or missing SF files, because the actual ns function to check the current BN or player owned SF files costs RAM, and I've been trying to keep daemon RAM quite low. I'll try to tweak it over time to be less noisy about the functions that it can't access - I know it's annoying.
from bitburner-scripts.
from bitburner-scripts.
Should be better now.
I imagine by now you've fixed all this yourself and no longer want to bother pulling / merging with your own changes, but it should help the next guy getting started
from bitburner-scripts.
I was thinking. Instead of checking if the player has SF files and making . Is it possible to use an arg to tell the code to run without SF functions? Or even args for each SF, so the player can say which one he already owns?
I was able to run the script without SF usign only those, maybe there are more that are possible to run without SF
asynchronousHelpers = [
{ name: "stats.js", requiredServer: "home" }, // Adds stats not usually in the HUD
// { name: "stockmaster.js", requiredServer: "home", args: ["--show-market-summary"], tail: true, shouldRun: () => playerStats.hasTixApiAccess }, // Start our stockmaster if we have the required stockmarket access
// { name: "spend-hacknet-hashes.js", requiredServer: "home", tail: true, args: ["-v"] }, // Always have this running to make sure hashes aren't wasted
// { name: "hacknet-upgrade-manager.js", requiredServer: "home", tail: true, args: ["-c", "--max-payoff-time", "1h"] }, // Kickstart hash income by buying everything with up to 1h payoff time immediately
// { name: "gangs.js", requiredServer: "home", tail: true }, // Script to create manage our gang for us
// { name: "sleeve.js", requiredServer: "home", tail: true }, // Script to create manage our sleeves for us
// { name: "work-for-factions.js", requiredServer: "home", args: ['--fast-crimes-only'] }, // Script to manage how we use our "focus" work
];
asynchronousHelpers.forEach(helper => helper.isLaunched = false);
// These scripts are spawned periodically (at some interval) to do their checks, with an optional condition that limits when they should be spawned
let shouldUpgradeHacknet = () => !shouldReserveMoney() && (whichServerIsRunning(ns, "hacknet-upgrade-manager.js", false) === null);
periodicScripts = [
// Buy tor as soon as we can if we haven't already, and all the port crackers
// { interval: 29000, name: "/Tasks/tor-manager.js", shouldRun: () => !addedServerNames.includes("darkweb") },
//{ interval: 30000, name: "/Tasks/program-manager.js", shouldRun: () => getNumPortCrackers() != 5 },
// { interval: 31000, name: "/Tasks/ram-manager.js", shouldRun: () => !shouldReserveMoney() && (getTotalNetworkUtilization() > 0.85 || xpOnly) },
// Buy every hacknet upgrade with up to 4h payoff if it is less than 10% of our current money or 8h if it is less than 1% of our current money
//{ interval: 32000, name: "hacknet-upgrade-manager.js", shouldRun: shouldUpgradeHacknet, args: () => ["-c", "--max-payoff-time", "4h", "--max-spend", ns.getServerMoneyAvailable("home") * 0.1] },
//{ interval: 33000, name: "hacknet-upgrade-manager.js", shouldRun: shouldUpgradeHacknet, args: () => ["-c", "--max-payoff-time", "8h", "--max-spend", ns.getServerMoneyAvailable("home") * 0.01] },
// Don't start auto-joining factions until we're holding 1 billion (so coding contracts returning money is probably less critical) or we've joined one already
//{ interval: 34000, name: "faction-manager.js", requiredServer: "home", args: ['--join-only'], shouldRun: () => playerStats.factions.length > 0 || ns.getServerMoneyAvailable("home") > 1e9 },
{ interval: 51000, name: "/Tasks/contractor.js", requiredServer: "home" },
//{ interval: 110000, name: "/Tasks/backdoor-all-servers.js", requiredServer: "home" },
{ interval: 111000, name: "host-manager.js", requiredServer: "home", shouldRun: () => !shouldReserveMoney() },
];
from bitburner-scripts.
Nice, thank you very much!
from bitburner-scripts.
Related Issues (20)
- RAM usage error HOT 2
- Autopilot Warning/Error loops HOT 3
- Make work-for-factions.js display remaining time also considering sleeves. [enhancement] HOT 2
- Daemon settings(?) HOT 1
- Provide an option to sync player stats to an external location HOT 1
- suggestion: better progression understanding HOT 1
- autopilot stuck in constant reset HOT 4
- Git-Pull needs to use current working directory HOT 1
- faction-manager.js: Problem with rep cost estimates HOT 3
- faction-manager.js: Trying to join Netburners while not having to requirements
- Repeating warning with Bitburner v2.5.2 HOT 5
- Daemon.js: Non-integer thread count
- Bitbutner v2.6.0dev: Bladeburner skill cost of "null" breaks script
- Stanek's gift not activated automatically HOT 6
- daemon.js: Errors in late BN12.XXX when server initial values are outside of min/max values.
- Idea: utilize new IPvGO game for profit HOT 1
- Post Discord Invite link
- RAM Calculation Error in git-pull.js HOT 1
- Bladeburner.js incorrectly tries to do an action when there is less than 0 count remaining
- Bitburner now kills all scripts on casino save scumming. HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from bitburner-scripts.