Improve achievement 118 behavior

This commit is contained in:
SpectralFlame 2023-08-31 09:24:44 -05:00 committed by cyip92
parent 5e361f956a
commit 3abadca018
3 changed files with 16 additions and 4 deletions

View File

@ -20,16 +20,22 @@ export default {
data() {
return {
isUnlocked: false,
// Used to hide the input box if the game is auto-sacrificing every tick without resource resets
isHiddenSacrifice: false,
};
},
computed: {
name() {
return this.autobuyer.name;
},
isSacrifice() {
return this.name === "Dimensional Sacrifice";
}
},
methods: {
update() {
this.isUnlocked = this.autobuyer.isUnlocked;
this.isHiddenSacrifice = this.isSacrifice && Achievement(118).canBeApplied;
},
}
};
@ -45,8 +51,14 @@ export default {
{{ name }}
<AutobuyerIntervalLabel :autobuyer="autobuyer" />
<b
v-if="isHiddenSacrifice"
class="c-autobuyer-box__small-text"
>
Automatic (Achievement 118)
</b>
<span
v-if="autobuyer.hasInput"
v-else-if="autobuyer.hasInput"
class="c-autobuyer-box__small-text"
>
Multiplier:

View File

@ -38,7 +38,6 @@ export class SacrificeAutobuyerState extends AutobuyerState {
}
tick() {
if (Sacrifice.nextBoost.lt(Decimal.max(this.multiplier, 1.01))) return;
sacrificeReset();
if (Achievement(118).canBeApplied || Sacrifice.nextBoost.gte(Decimal.max(this.multiplier, 1.01))) sacrificeReset();
}
}

View File

@ -839,7 +839,8 @@ export const normalAchievements = [
get description() { return `Get a total Dimensional Sacrifice multiplier of ${formatPostBreak(DC.E9000)}.`; },
checkRequirement: () => Sacrifice.totalBoost.exponent >= 9000,
checkEvent: GAME_EVENT.SACRIFICE_RESET_AFTER,
reward: "Dimensional Sacrifice doesn't reset your Antimatter Dimensions.",
reward: `Dimensional Sacrifice doesn't reset your Antimatter Dimensions
and the Autobuyer activates every tick if turned on.`,
},
{
id: 121,