mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2026-04-21 16:52:55 +02:00
Add triggers for faction invite check
Manually check for faction invites whenever a server is backdoored, and whenever the player uses ns.singularity.checkFactionInvites
This commit is contained in:
@@ -76,6 +76,7 @@ import { hash } from "../hash/hash";
|
||||
import { apr1 } from "./commands/apr1";
|
||||
import { changelog } from "./commands/changelog";
|
||||
import { BitNodeMultipliers } from "../BitNode/BitNodeMultipliers";
|
||||
import { Engine } from "../engine";
|
||||
|
||||
export class Terminal {
|
||||
// Flags to determine whether the player is currently running a hack or an analyze
|
||||
@@ -207,6 +208,10 @@ export class Terminal {
|
||||
Router.toBitVerse(false, false);
|
||||
return;
|
||||
}
|
||||
// Manunally check for faction invites
|
||||
Engine.Counters.checkFactionInvitations = 0;
|
||||
Engine.checkCounters();
|
||||
|
||||
let moneyGained = calculatePercentMoneyHacked(server, Player) * BitNodeMultipliers.ManualHackMoney;
|
||||
moneyGained = Math.floor(server.moneyAvailable * moneyGained);
|
||||
|
||||
@@ -298,6 +303,10 @@ export class Terminal {
|
||||
Router.toBitVerse(false, false);
|
||||
return;
|
||||
}
|
||||
// Manunally check for faction invites
|
||||
Engine.Counters.checkFactionInvitations = 0;
|
||||
Engine.checkCounters();
|
||||
|
||||
this.print(`Backdoor on '${server.hostname}' successful!`);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user