-
Notifications
You must be signed in to change notification settings - Fork 274
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
implemention of #308 hacknet nodes max ram usage #314
base: main
Are you sure you want to change the base?
Conversation
My only feedback here is that the default should be 1.0 (to default to the current behaviour) - but other than that, it's great to have the extra option to tweak. We may also wish to add something to autopilot which sets this automatically to a lower number it bitnodes where hacking is less important and/or hashes are more important. |
@@ -33,6 +33,7 @@ const argsSchema = [ | |||
['n', false], // Can toggle on using hacknet nodes for extra hacking ram (at the expense of hash production) | |||
['use-hacknet-nodes', false], // Same as above (kept for backwards compatibility, but these are now called hacknet-servers) | |||
['use-hacknet-servers', false], // Same as above, but the game recently renamed these | |||
['hacknet-use-ram-percentage', 0.75], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
['hacknet-use-ram-percentage', 0.75], | |
['hacknet-use-ram-percentage', 1.00], |
@@ -118,6 +119,7 @@ let xpOnly = false; // "-x" command line arg - focus on a strategy that produces | |||
let verbose = false; // "-v" command line arg - Detailed logs about batch scheduling / tuning | |||
let runOnce = false; // "-o" command line arg - Good for debugging, run the main targettomg loop once then stop | |||
let useHacknetNodes = false; // "-n" command line arg - Can toggle using hacknet nodes for extra hacking ram | |||
let hacknetUsePercentage = 0.75 // How much ram percentage ram from the hacknet is getting used. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let hacknetUsePercentage = 0.75 // How much ram percentage ram from the hacknet is getting used. | |
let hacknetUsePercentage = 1.00 // How much ram percentage ram from the hacknet is getting used. |
@@ -250,6 +252,7 @@ export async function main(ns) { | |||
stockMode = (options.s || options['stock-manipulation'] || options['stock-manipulation-focus']) && !options['disable-stock-manipulation']; | |||
stockFocus = options['stock-manipulation-focus'] && !options['disable-stock-manipulation']; | |||
useHacknetNodes = options.n || options['use-hacknet-nodes'] || options['use-hacknet-servers']; | |||
hacknetUsePercentage = Math.max(options['hacknet-use-ram-percentage']) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hacknetUsePercentage = Math.max(options['hacknet-use-ram-percentage']) | |
hacknetUsePercentage = options['hacknet-use-ram-percentage'] |
Not sure why the max was there, it would do nothing
here is the code for my suggestion.