implement row 3 upg effects

This commit is contained in:
unsoftcapped3 2022-12-23 03:32:05 +00:00
parent 59d5c46b74
commit 3b386f5909
3 changed files with 50 additions and 6 deletions

View file

@ -36,6 +36,7 @@ import oil from "./oil";
import paper from "./paper"; import paper from "./paper";
import trees from "./trees"; import trees from "./trees";
import toys from "./toys"; import toys from "./toys";
import factory from "./factory";
interface Dye { interface Dye {
name: string; name: string;
@ -56,7 +57,7 @@ type DyeUpg =
| "blueDyeUpg2" | "blueDyeUpg2"
| "coalUpg"; | "coalUpg";
export type enumColor = "red" | "green" | "blue" | "yellow" | "purple" | "orange" | "black"; export type enumColor = "red" | "green" | "blue" | "yellow" | "purple" | "orange" | "black" | "white";
const id = "dyes"; const id = "dyes";
const day = 11; const day = 11;
@ -520,6 +521,31 @@ const layer = createLayer(id, function (this: BaseLayer) {
dyesToReset: [], dyesToReset: [],
visibility: () => showIf(toys.milestones.milestone2.earned.value) visibility: () => showIf(toys.milestones.milestone2.earned.value)
}), }),
white: createDye({
name: "White Dye",
color: "white",
key: "q",
costs: () => [
{
base: "1e60",
root: 5,
res: trees.logs
},
{
base: computed(() => (upgrades.yellowDyeUpg2.bought.value ? "1e17" : "2e17")),
root: 2,
res: oil.oil
}
],
listedBoosts: [
{
visible: true,
desc: computed(() => `*${format(boosts.white1.value)} plastic gain.`)
}
],
dyesToReset: [],
visibility: () => showIf(factory.upgrades[2][3].bought.value)
}),
orange: createDye({ orange: createDye({
name: "Orange Dye", name: "Orange Dye",
color: "orange", color: "orange",
@ -702,6 +728,11 @@ const layer = createLayer(id, function (this: BaseLayer) {
Decimal.pow(2, Decimal.add(dyes.black.amount.value, 1).log2().sqrt()) Decimal.pow(2, Decimal.add(dyes.black.amount.value, 1).log2().sqrt())
.pow(upgrades.coalUpg.bought.value ? 1.2 : 1) .pow(upgrades.coalUpg.bought.value ? 1.2 : 1)
.pow(management.elfTraining.clothElfTraining.milestones[3].earned.value ? 1.1 : 1) .pow(management.elfTraining.clothElfTraining.milestones[3].earned.value ? 1.1 : 1)
),
white1: computed(() =>
Decimal.pow(2, Decimal.add(dyes.white.amount.value, 1).log2().sqrt())
.pow(upgrades.coalUpg.bought.value ? 1.2 : 1)
.pow(management.elfTraining.clothElfTraining.milestones[3].earned.value ? 1.1 : 1)
) )
}; };

View file

@ -194,8 +194,17 @@ const factory = createLayer(id, () => {
multiplier: Decimal.add(paper.paper.value, 1).log10().div(100).add(1), multiplier: Decimal.add(paper.paper.value, 1).log10().div(100).add(1),
description: "News Ticker", description: "News Ticker",
enabled: () => upgrades[0][1].bought.value enabled: () => upgrades[0][1].bought.value
})) })),
createMultiplicativeModifier(() => ({
multiplier: Decimal.lt(energyEfficiency.value, 1)?1:Decimal.sub(2, Decimal.div(energyConsumption.value, computedEnergy.value)),
description: "Brighter work rooms",
enabled: () => upgrades[2][1].bought.value
})),
createMultiplicativeModifier(() => ({
multiplier: 1.5,
description: "Carry ticks in boxes",
enabled: () => upgrades[2][3].bought.value
})),
]); ]);
const computedTickRate = computed(() => tickRate.apply(1)); const computedTickRate = computed(() => tickRate.apply(1));
const factorySize = createSequentialModifier(() => [ const factorySize = createSequentialModifier(() => [
@ -651,7 +660,7 @@ const factory = createLayer(id, () => {
}, },
outputs: { outputs: {
bear: { bear: {
amount: 1, amount: computed(() => (upgrades[1][3].bought.value ? 2 : 1)),
resource: bears resource: bears
} }
}, },
@ -703,7 +712,7 @@ const factory = createLayer(id, () => {
}, },
outputs: { outputs: {
console: { console: {
amount: computed(() => (upgrades[1][1].bought.value ? 3 : 1)), amount: computed(() => (upgrades[1][3].bought.value ? 3 : 1)),
resource: consoles resource: consoles
} }
}, },
@ -1116,7 +1125,7 @@ const factory = createLayer(id, () => {
cost: () =>Decimal.pow(100, upgradeAmount.value).mul(1e136), cost: () =>Decimal.pow(100, upgradeAmount.value).mul(1e136),
display: { display: {
title: "Brighter work rooms", title: "Brighter work rooms",
description: "Unused electricity % makes ticks faster up to 2x" description: "Unused electricity makes ticks faster"
}, },
visible: () => showIf(main.days[advancedDay - 1].opened.value) visible: () => showIf(main.days[advancedDay - 1].opened.value)
})), })),

View file

@ -379,6 +379,10 @@ const layer = createLayer(id, function (this: BaseLayer) {
multiplier: 50, multiplier: 50,
description: "350 toys", description: "350 toys",
enabled: toys.milestones.milestone4.earned enabled: toys.milestones.milestone4.earned
})),
createMultiplicativeModifier(() => ({
multiplier: () => dyes.boosts.white1.value,
description: "White Dye Boost"
})) }))
]); ]);
const computedPlasticGain = computed(() => plasticGain.apply(0)); const computedPlasticGain = computed(() => plasticGain.apply(0));