mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2026-04-29 12:27:07 +02:00
sg
This commit is contained in:
+14
-14
@@ -24,7 +24,6 @@ import {
|
||||
import { hasHacknetServers, processHacknetEarnings } from "./Hacknet/HacknetHelpers";
|
||||
import { iTutorialStart } from "./InteractiveTutorial";
|
||||
import { checkForMessagesToSend, initMessages } from "./Message/MessageHelpers";
|
||||
import { inMission, currMission } from "./Missions";
|
||||
import { loadAllRunningScripts, updateOnlineScriptTimes } from "./NetscriptWorker";
|
||||
import { Player } from "./Player";
|
||||
import { saveObject, loadGame } from "./SaveObject";
|
||||
@@ -43,7 +42,7 @@ import { Money } from "./ui/React/Money";
|
||||
import { Hashes } from "./ui/React/Hashes";
|
||||
import { Reputation } from "./ui/React/Reputation";
|
||||
|
||||
import { dialogBoxCreate } from "./ui/React/DialogBox";
|
||||
import { AlertEvents } from "./ui/React/AlertManager";
|
||||
import { exceptionAlert } from "./utils/helpers/exceptionAlert";
|
||||
|
||||
import { startTampering } from "./Exploits/tampering";
|
||||
@@ -132,11 +131,6 @@ const Engine: {
|
||||
Player.gang.process(numCycles, Player);
|
||||
}
|
||||
|
||||
// Mission
|
||||
if (inMission && currMission) {
|
||||
currMission.process(numCycles);
|
||||
}
|
||||
|
||||
// Staneks gift
|
||||
staneksGift.process(Player, numCycles);
|
||||
|
||||
@@ -338,7 +332,9 @@ const Engine: {
|
||||
// Hacknet Nodes offline progress
|
||||
const offlineProductionFromHacknetNodes = processHacknetEarnings(Player, numCyclesOffline);
|
||||
const hacknetProdInfo = hasHacknetServers(Player) ? (
|
||||
<>{Hashes(offlineProductionFromHacknetNodes)} hashes</>
|
||||
<>
|
||||
<Hashes hashes={offlineProductionFromHacknetNodes} /> hashes
|
||||
</>
|
||||
) : (
|
||||
<Money money={offlineProductionFromHacknetNodes} />
|
||||
);
|
||||
@@ -403,12 +399,16 @@ const Engine: {
|
||||
Player.lastUpdate = Engine._lastUpdate;
|
||||
Engine.start(); // Run main game loop and Scripts loop
|
||||
const timeOfflineString = convertTimeMsToTimeElapsedString(time);
|
||||
dialogBoxCreate(
|
||||
<>
|
||||
Offline for {timeOfflineString}. While you were offline, your scripts generated{" "}
|
||||
<Money money={offlineHackingIncome} />, your Hacknet Nodes generated {hacknetProdInfo} and you gained{" "}
|
||||
{Reputation(offlineReputation)} divided amongst your factions.
|
||||
</>,
|
||||
setTimeout(
|
||||
() =>
|
||||
AlertEvents.emit(
|
||||
<>
|
||||
Offline for {timeOfflineString}. While you were offline, your scripts generated{" "}
|
||||
<Money money={offlineHackingIncome} />, your Hacknet Nodes generated {hacknetProdInfo} and you gained{" "}
|
||||
<Reputation reputation={offlineReputation} /> reputation divided amongst your factions.
|
||||
</>,
|
||||
),
|
||||
250,
|
||||
);
|
||||
} else {
|
||||
// No save found, start new game
|
||||
|
||||
Reference in New Issue
Block a user