diff --git a/src/CotMG/StaneksGift.ts b/src/CotMG/StaneksGift.ts index 21ebd5df8..9ae9c1447 100644 --- a/src/CotMG/StaneksGift.ts +++ b/src/CotMG/StaneksGift.ts @@ -58,7 +58,7 @@ export class StaneksGift extends BaseGift { this.storedCycles = Math.max(0, this.storedCycles - usedCycles); // Only update multipliers (slow) if there was charging done since last process tick. if (this.justCharged) { - this.updateMults(); + Player.applyEntropy(Player.entropy); this.justCharged = false; } StaneksGiftEvents.emit(); @@ -210,9 +210,6 @@ export class StaneksGift extends BaseGift { } updateMults(): void { - // applyEntropy also reapplies all augmentations and source files - // This wraps up the reset nicely - Player.applyEntropy(Player.entropy); const mults = this.calculateMults(); Player.mults = mergeMultipliers(Player.mults, mults); Player.updateSkillLevels(); diff --git a/src/DevMenu/ui/StanekDev.tsx b/src/DevMenu/ui/StanekDev.tsx index 98e2c04cb..bc6ae8221 100644 --- a/src/DevMenu/ui/StanekDev.tsx +++ b/src/DevMenu/ui/StanekDev.tsx @@ -1,6 +1,7 @@ import React from "react"; import { staneksGift } from "../../CotMG/Helper"; +import { Player } from "@player"; import Accordion from "@mui/material/Accordion"; import AccordionSummary from "@mui/material/AccordionSummary"; @@ -29,12 +30,14 @@ export function StanekDev(): React.ReactElement { staneksGift.fragments.forEach((f) => { f.highestCharge = 1e21; f.numCharge = 1e21; + Player.applyEntropy(Player.entropy); }); } function modCharge(modify: number): (x: number) => void { return function (cycles: number): void { staneksGift.fragments.forEach((f) => (f.highestCharge += cycles * modify)); + Player.applyEntropy(Player.entropy); }; } diff --git a/src/PersonObjects/Player/PlayerObjectAugmentationMethods.ts b/src/PersonObjects/Player/PlayerObjectAugmentationMethods.ts index abcb38f8a..788105a43 100644 --- a/src/PersonObjects/Player/PlayerObjectAugmentationMethods.ts +++ b/src/PersonObjects/Player/PlayerObjectAugmentationMethods.ts @@ -1,5 +1,6 @@ /** Augmentation-related methods for the Player class (PlayerObject) */ import { calculateEntropy } from "../Grafting/EntropyAccumulation"; +import { staneksGift } from "../../CotMG/Helper"; import type { PlayerObject } from "./PlayerObject"; @@ -9,4 +10,5 @@ export function applyEntropy(this: PlayerObject, stacks = 1): void { this.reapplyAllSourceFiles(); this.mults = calculateEntropy(stacks); + staneksGift.updateMults(); } diff --git a/src/engine.tsx b/src/engine.tsx index 9be60d447..96287782f 100644 --- a/src/engine.tsx +++ b/src/engine.tsx @@ -229,8 +229,6 @@ const Engine: { if (loadGame(saveString)) { FormatsNeedToChange.emit(); initBitNodeMultipliers(); - Player.reapplyAllAugmentations(); - Player.reapplyAllSourceFiles(); if (Player.hasWseAccount) { initSymbolToStockMap(); }