summaryrefslogtreecommitdiff
path: root/bitburnerFiles1026/stocks.js
diff options
context:
space:
mode:
authorAlmightyMiau <almightymeow612@gmail.com>2024-11-13 10:56:53 -0800
committerAlmightyMiau <almightymeow612@gmail.com>2024-11-13 10:56:53 -0800
commit40843e35434d56e883655e4377994ac76746b184 (patch)
tree786c3acc109b4add11c88ca58a534fd19d4e77cb /bitburnerFiles1026/stocks.js
parent1ca00b3b73a9699e41f81e154cea32934c16de03 (diff)
Organized scripts into folders
Diffstat (limited to 'bitburnerFiles1026/stocks.js')
-rw-r--r--bitburnerFiles1026/stocks.js25
1 files changed, 0 insertions, 25 deletions
diff --git a/bitburnerFiles1026/stocks.js b/bitburnerFiles1026/stocks.js
deleted file mode 100644
index c456534..0000000
--- a/bitburnerFiles1026/stocks.js
+++ /dev/null
@@ -1,25 +0,0 @@
-/** @param {NS} ns */
-export async function main(ns) {
- let manip = ns.args[0];
- if (manip == "-h" || manip == "help" || manip == "--help") {
- ns.tprint("arg 0 is the boolean, to manipulate prices or not. \n True uses more scripts");
- manip = false;
- }
- //ns.disableLog("sleep");
- const syms = ns.stock.getSymbols();
- while (true) {
- for (let i = 0; i < syms.length; i++) {
- let sym = syms[i];
- if (ns.stock.getForecast(sym) > 0.5 && !(ns.getRunningScript("stocker.js", "home", sym))) {
- if ((ns.stock.getAskPrice(sym) * ns.stock.getMaxShares(sym)) < ns.getServerMoneyAvailable("home")) {
- ns.exec("stocker.js", "home", 1, sym);
- }
- }
- await ns.sleep(1000);
- }
- await ns.sleep(1000);
- }
-}
-
-// look through all the stocks to see what is going up, and run stocker on whatever is
-// \ No newline at end of file