mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2024-11-27 01:53:48 +01:00
fix for augmentation pricing
This commit is contained in:
parent
fd64746ff8
commit
79238ea5e9
@ -95,7 +95,7 @@ function getRandomBonus(): any {
|
|||||||
return bonuses[Math.floor(bonuses.length * randomNumber.random())];
|
return bonuses[Math.floor(bonuses.length * randomNumber.random())];
|
||||||
}
|
}
|
||||||
|
|
||||||
export const infiltratorsOtherAugmentations = [
|
export const infiltratorsAugmentations = [
|
||||||
new Augmentation({
|
new Augmentation({
|
||||||
name: AugmentationNames.BionicFingers,
|
name: AugmentationNames.BionicFingers,
|
||||||
repCost: 15e1,
|
repCost: 15e1,
|
||||||
@ -159,9 +159,6 @@ export const infiltratorsOtherAugmentations = [
|
|||||||
"blunt damage when used as an alloy with almost any other metal you can think of.",
|
"blunt damage when used as an alloy with almost any other metal you can think of.",
|
||||||
factions: [FactionNames.Infiltrators],
|
factions: [FactionNames.Infiltrators],
|
||||||
}),
|
}),
|
||||||
];
|
|
||||||
|
|
||||||
export const infiltratorsMiniGameAugmentations = [
|
|
||||||
new Augmentation({
|
new Augmentation({
|
||||||
name: AugmentationNames.PythiasBrainStem,
|
name: AugmentationNames.PythiasBrainStem,
|
||||||
repCost: 1e2,
|
repCost: 1e2,
|
||||||
|
@ -17,8 +17,7 @@ import {
|
|||||||
churchOfTheMachineGodAugmentations,
|
churchOfTheMachineGodAugmentations,
|
||||||
generalAugmentations,
|
generalAugmentations,
|
||||||
getNextNeuroFluxLevel,
|
getNextNeuroFluxLevel,
|
||||||
infiltratorsMiniGameAugmentations,
|
infiltratorsAugmentations,
|
||||||
infiltratorsOtherAugmentations,
|
|
||||||
initNeuroFluxGovernor,
|
initNeuroFluxGovernor,
|
||||||
initUnstableCircadianModulator,
|
initUnstableCircadianModulator,
|
||||||
} from "./AugmentationCreator";
|
} from "./AugmentationCreator";
|
||||||
@ -34,8 +33,7 @@ function createAugmentations(): void {
|
|||||||
initNeuroFluxGovernor(),
|
initNeuroFluxGovernor(),
|
||||||
initUnstableCircadianModulator(),
|
initUnstableCircadianModulator(),
|
||||||
...generalAugmentations,
|
...generalAugmentations,
|
||||||
...infiltratorsMiniGameAugmentations,
|
...infiltratorsAugmentations,
|
||||||
...infiltratorsOtherAugmentations,
|
|
||||||
...(factionExists(FactionNames.Bladeburners) ? bladeburnerAugmentations : []),
|
...(factionExists(FactionNames.Bladeburners) ? bladeburnerAugmentations : []),
|
||||||
...(factionExists(FactionNames.ChurchOfTheMachineGod) ? churchOfTheMachineGodAugmentations : []),
|
...(factionExists(FactionNames.ChurchOfTheMachineGod) ? churchOfTheMachineGodAugmentations : []),
|
||||||
].map(resetAugmentation);
|
].map(resetAugmentation);
|
||||||
@ -78,10 +76,10 @@ function updateNeuroFluxGovernorCosts(neuroFluxGovernorAugmentation: Augmentatio
|
|||||||
|
|
||||||
function updateInfiltratorCosts(infiltratorAugmentation: Augmentation): void {
|
function updateInfiltratorCosts(infiltratorAugmentation: Augmentation): void {
|
||||||
const infiltratorMultiplier =
|
const infiltratorMultiplier =
|
||||||
infiltratorsMiniGameAugmentations.filter((augmentation) => Player.hasAugmentation(augmentation.name)).length + 1;
|
infiltratorsAugmentations.filter((augmentation) => Player.hasAugmentation(augmentation.name)).length + 1;
|
||||||
infiltratorAugmentation.baseCost = Math.pow(infiltratorAugmentation.baseCost * 1000, infiltratorMultiplier);
|
infiltratorAugmentation.baseCost = Math.pow(infiltratorAugmentation.startingCost * 1000, infiltratorMultiplier);
|
||||||
if (infiltratorsMiniGameAugmentations.find((augmentation) => augmentation.name === infiltratorAugmentation.name)) {
|
if (infiltratorsAugmentations.find((augmentation) => augmentation.name === infiltratorAugmentation.name)) {
|
||||||
infiltratorAugmentation.baseRepRequirement *= infiltratorMultiplier;
|
infiltratorAugmentation.baseRepRequirement = infiltratorAugmentation.startingRepRequirement * infiltratorMultiplier;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -19,7 +19,7 @@ import { IPlayerOwnedAugmentation, PlayerOwnedAugmentation } from "../../Augment
|
|||||||
import { AugmentationNames } from "../../Augmentation/data/AugmentationNames";
|
import { AugmentationNames } from "../../Augmentation/data/AugmentationNames";
|
||||||
|
|
||||||
import { getRandomInt } from "../../utils/helpers/getRandomInt";
|
import { getRandomInt } from "../../utils/helpers/getRandomInt";
|
||||||
import { infiltratorsMiniGameAugmentations } from "../../Augmentation/AugmentationCreator";
|
import { infiltratorsAugmentations } from "../../Augmentation/AugmentationCreator";
|
||||||
|
|
||||||
// Executes the actual re-sleeve when one is purchased
|
// Executes the actual re-sleeve when one is purchased
|
||||||
export function purchaseResleeve(r: Resleeve, p: IPlayer): boolean {
|
export function purchaseResleeve(r: Resleeve, p: IPlayer): boolean {
|
||||||
@ -112,7 +112,7 @@ export function generateResleeves(): Resleeve[] {
|
|||||||
AugmentationNames.StaneksGift1,
|
AugmentationNames.StaneksGift1,
|
||||||
AugmentationNames.StaneksGift2,
|
AugmentationNames.StaneksGift2,
|
||||||
AugmentationNames.StaneksGift3,
|
AugmentationNames.StaneksGift3,
|
||||||
...infiltratorsMiniGameAugmentations,
|
...infiltratorsAugmentations,
|
||||||
].map((augmentation) => augmentation as string);
|
].map((augmentation) => augmentation as string);
|
||||||
if (forbidden.includes(randKey)) {
|
if (forbidden.includes(randKey)) {
|
||||||
continue;
|
continue;
|
||||||
|
Loading…
Reference in New Issue
Block a user