bitburner-scripts icon indicating copy to clipboard operation
bitburner-scripts copied to clipboard

Initial infiltration code

Open abarnert opened this issue 3 years ago • 2 comments

I forked ullbergm's infiltration.js and added a few fixes, then wrote a driver that can be used to infiltrate a target company for a faction or for cash in a loop.

This should be usable for manual scripting whenever autopilot isn't stealing focus:

  • run infiloop.js --target NWO --faction Aevum --loop Infinity

Anyone who wants to use it for now can just pull the two files out of my fork (or from this PR) and run it manually.

I have some thoughts about how to integrate this into autopilot/work-for-factions (see infinotes.md file for more details), but haven't yet implemented them. It should be easy enough to:

  • Skip casino and instead infiltrate NWO for cash until $10B
    • Including infiltrating MegaCorp once to make cash for travel
    • No need to pause normal startup, just pass --no-focus until $10B
  • Speed up working for factions
  • Work for factions or cash while working for companies.
  • Prioritize phyzical WKS harmonizer over other infiltration augments

I'll add comments on the source.

abarnert avatar Jul 10 '22 21:07 abarnert

Some notes:

  • I tried calling this in autopilot.js, and observed that if this and casino.js are both called, the game hits an error state. This might be casino.js's fault.
  • Infiltrate.js will put the game into a bad state if it's run while an infiltration is already in progress (eg. on a timer), which also breaks typing into the terminal. I locally avoided that problem locally by incorporating the instanceCount from helpers.js. Presumably this is because the two scripts having conflicting interactions with the "tmrAutoInf" variable on wnd.

(My local code is a complete garbage hack-job or I'd share it, but I was just trying to add getting all the needed rep and then getting money after 10 minutes of idle. Main reason for 10 minutes of idle is a combo of getting me time to manually intervene, and being well-clear of the casino.js problem.)

MichaelJosephEns avatar Aug 29 '22 06:08 MichaelJosephEns

You'll want to modify https://github.com/alainbryden/bitburner-scripts/commit/cac44e7db97c612abf5890c2fec1bd48df9c617e

Most of the Shadows of Anarchy should still be ignored but the one item that increases the rewards for infiltration should be a priority.

MichaelJosephEns avatar Sep 23 '22 03:09 MichaelJosephEns

it appears the solve for "slash when his guard is down" isn't triggering properly. it just run's through and then auto fails.

CARAMELRALLYE avatar Feb 04 '23 20:02 CARAMELRALLYE

Ongoing work moved to #239, then to #286

alainbryden avatar Apr 24 '23 19:04 alainbryden