mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2024-12-18 20:25:45 +01:00
group initializers
This commit is contained in:
parent
94a8c7ca64
commit
ab56d18e1e
@ -1,11 +1,13 @@
|
||||
import React from "react";
|
||||
import { SourceFile } from "./SourceFile";
|
||||
import { IMap } from "../types";
|
||||
import { initBitNodes } from "../BitNode/BitNode";
|
||||
import { initBitNodes, initBitNodeMultipliers } from "../BitNode/BitNode";
|
||||
|
||||
export const SourceFiles: IMap<SourceFile> = {};
|
||||
/** Engine initializer for SourceFiles, BitNodes, and BitNodeMultipliers. Run once at engine load. */
|
||||
export function initSourceFiles() {
|
||||
initBitNodes();
|
||||
initBitNodeMultipliers();
|
||||
SourceFiles["SourceFile1"] = new SourceFile(
|
||||
1,
|
||||
(
|
||||
|
@ -4,7 +4,6 @@
|
||||
import { convertTimeMsToTimeElapsedString } from "./utils/StringHelperFunctions";
|
||||
import { initAugmentations } from "./Augmentation/AugmentationHelpers";
|
||||
import { AugmentationNames } from "./Augmentation/data/AugmentationNames";
|
||||
import { initBitNodeMultipliers } from "./BitNode/BitNode";
|
||||
import { initSourceFiles } from "./SourceFile/SourceFiles";
|
||||
import { initDarkWebItems } from "./DarkWeb/DarkWebItems";
|
||||
import { generateRandomContract } from "./CodingContractGenerator";
|
||||
@ -232,7 +231,6 @@ const Engine: {
|
||||
if (loadGame(saveString)) {
|
||||
ThemeEvents.emit();
|
||||
initSourceFiles();
|
||||
initBitNodeMultipliers();
|
||||
initDarkWebItems();
|
||||
initAugmentations(); // Also calls Player.reapplyAllAugmentations()
|
||||
Player.reapplyAllSourceFiles();
|
||||
@ -372,7 +370,6 @@ const Engine: {
|
||||
} else {
|
||||
// No save found, start new game
|
||||
initSourceFiles();
|
||||
initBitNodeMultipliers();
|
||||
initDarkWebItems();
|
||||
Engine.start(); // Run main game loop and Scripts loop
|
||||
Player.init();
|
||||
|
Loading…
Reference in New Issue
Block a user