Jack and Mary lv4-5 and Noel lv4

This commit is contained in:
thepaperpilot 2022-12-12 21:15:42 -06:00
parent 55ecd21d55
commit e181b2b533
4 changed files with 47 additions and 10 deletions

View file

@ -75,6 +75,9 @@ const layer = createLayer(id, () => {
}
return elfLevel;
});
const totalElfExp = computed(() =>
Object.values(elfTraining).reduce((acc, curr) => acc.add(curr.exp.value), new Decimal(0))
);
// ------------------------------------------------------------------------------- Upgrades
@ -169,7 +172,8 @@ const layer = createLayer(id, () => {
createMultiplicativeModifier(() => ({
multiplier: focusMulti,
description: "Focus Multiplier",
enabled: () => Decimal.gt(focusTime.value, 0) && focusTargets.value[elf.name] == true
enabled: () =>
Decimal.gt(focusTime.value, 0) && focusTargets.value[elf.name] == true
})),
...modifiers
]);
@ -390,7 +394,11 @@ const layer = createLayer(id, () => {
createMilestone(() => ({
display: {
requirement: "Jack Level 4",
effectDisplay: "Oil gain is multiplied based on total elf levels."
effectDisplay: jsx(() => (
<>
Oil gain is multiplied by <Sqrt>total elf levels</Sqrt>.
</>
))
},
visibility: () =>
showIf(heatedCutterElfMilestones[2].earned.value && main.day.value >= 13),
@ -903,8 +911,8 @@ const layer = createLayer(id, () => {
);
}
}
focusTime.value = Decimal.sub(focusTime.value, diff).max(0)
focusCooldown.value = Decimal.sub(focusCooldown.value, diff).max(0)
focusTime.value = Decimal.sub(focusTime.value, diff).max(0);
focusCooldown.value = Decimal.sub(focusCooldown.value, diff).max(0);
if (Decimal.eq(focusTime.value, 0)) {
focusMulti.value = Decimal.pow(
focusMaxMulti.value,
@ -993,7 +1001,7 @@ const layer = createLayer(id, () => {
function rerollFocusTargets(range: number, count: DecimalSource) {
let x = 0;
focusTargets.value = {};
const newCount = Decimal.min(count, range)
const newCount = Decimal.min(count, range);
while (newCount.gte(x)) {
const roll = Object.values(elfTraining)[Math.floor(Math.random() * range)]?.name ?? "";
if (!focusTargets.value[roll]) {
@ -1267,6 +1275,7 @@ const layer = createLayer(id, () => {
elfTraining,
totalElfLevels,
totalElfExp,
currentShown,
generalTabCollapsed,

View file

@ -12,6 +12,7 @@ import { persistent } from "game/persistence";
import { globalBus } from "game/events";
import {
createAdditiveModifier,
createExponentialModifier,
createMultiplicativeModifier,
createSequentialModifier
} from "game/modifiers";
@ -30,6 +31,7 @@ import boxes from "./boxes";
import cloth from "./cloth";
import plastic from "./plastic";
import dyes from "./dyes";
import management from "./management";
const id = "metal";
const day = 7;
@ -78,6 +80,11 @@ const layer = createLayer(id, function (this: BaseLayer) {
multiplier: () => Decimal.add(cloth.cloth.value, 1).log10().plus(1),
description: "Glistening Paint",
enabled: dyes.upgrades.redDyeUpg.bought
})),
createExponentialModifier(() => ({
exponent: 1.1,
description: "Mary Level 4",
enabled: management.elfTraining.heatedPlanterElfTraining.milestones[3].earned
}))
]);
const computedOrePurity = computed(() => orePurity.apply(0.1));
@ -108,6 +115,11 @@ const layer = createLayer(id, function (this: BaseLayer) {
multiplier: () => Decimal.add(plastic.activeRefinery.value, 1).sqrt(),
description: "De Louvre",
enabled: dyes.upgrades.redDyeUpg2.bought
})),
createMultiplicativeModifier(() => ({
multiplier: () => Decimal.div(management.totalElfExp.value, 1000).add(1).sqrt(),
description: "Mary Level 5",
enabled: management.elfTraining.heatedPlanterElfTraining.milestones[4].earned
}))
]);
const computedAutoSmeltSpeed = computed(() => autoSmeltSpeed.apply(0));

View file

@ -35,6 +35,7 @@ import { formatGain } from "util/bignum";
import plastic from "./plastic";
import paper from "./paper";
import dyes from "./dyes";
import management from "./management";
const id = "oil";
const day = 9;
@ -247,8 +248,8 @@ const layer = createLayer(id, function (this: BaseLayer) {
<br />
Pump that oil from the ground.
<br />
Gain oil based on the number of Heavy buildings active and well
depth, but coal usage is multiplied by {row2Upgrades[3].bought.value ? 4 : 5}×.
Gain oil based on the number of Heavy buildings active and well depth, but coal
usage is multiplied by {row2Upgrades[3].bought.value ? 4 : 5}×.
<br />
<br />
Currently:
@ -718,6 +719,11 @@ const layer = createLayer(id, function (this: BaseLayer) {
multiplier: () => coalEffectiveness.value,
description: "Effectiveness",
enabled: () => Decimal.lt(coalEffectiveness.value, 1)
})),
createMultiplicativeModifier(() => ({
multiplier: () => Decimal.sqrt(management.totalElfLevels.value),
description: "Jack Level 4",
enabled: management.elfTraining.heatedCutterElfTraining.milestones[3].earned
}))
]);
const computedOilSpeed = computed(() => oilSpeed.apply(0));

View file

@ -32,6 +32,7 @@ import boxes from "./boxes";
import metal from "./metal";
import oil from "./oil";
import dyes from "./dyes";
import management from "./management";
const id = "plastic";
const day = 10;
@ -66,7 +67,11 @@ const layer = createLayer(id, function (this: BaseLayer) {
resource: metal.metal,
cost() {
const v = new Decimal(this.amount.value);
return Decimal.pow(1.2, v).times(1e7);
let cost = Decimal.pow(1.2, v).times(1e7);
if (management.elfTraining.fertilizerElfTraining.milestones[3].earned.value) {
cost = Decimal.sub(cost, Decimal.pow(plastic.value, 2)).max(0);
}
return cost;
},
display: jsx(() => (
<>
@ -299,11 +304,16 @@ const layer = createLayer(id, function (this: BaseLayer) {
<>
{render(trackerDisplay)}
<Spacer />
<MainDisplay resource={plastic} color={color} style="margin-bottom: 0" effectDisplay={
<MainDisplay
resource={plastic}
color={color}
style="margin-bottom: 0"
effectDisplay={
Decimal.gt(computedPlasticGain.value, 0)
? `+${format(computedPlasticGain.value)}/s`
: undefined
} />
}
/>
<Spacer />
<Column>
{render(buildRefinery)}