From 7d1cc514c27c88914c856e9fabcdeda3b36d7d8e Mon Sep 17 00:00:00 2001 From: Acamaeda Date: Sun, 4 Oct 2020 11:28:52 -0400 Subject: [PATCH] Changed another thing to use the repaired functions --- js/game.js | 2 +- js/layers.js | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/js/game.js b/js/game.js index b2ba59a..2cf2447 100644 --- a/js/game.js +++ b/js/game.js @@ -42,7 +42,7 @@ function getStartPlayer() { function getPointGen() { let gain = new Decimal(1) - if (player.c.upgrades.includes(12)) gain = gain.times(layers.c.upgrades["12"].effect()) + if (hasUpg("c", 12)) gain = gain.times(layers.c.upgrades[12].effect()) return gain } diff --git a/js/layers.js b/js/layers.js index 74df6b4..5ce48d7 100644 --- a/js/layers.js +++ b/js/layers.js @@ -20,8 +20,8 @@ addLayer("c", { canBuyMax() {}, // Only needed for static layers with buy max gainMult() { // Calculate the multiplier for main currency from bonuses mult = new Decimal(1) - if (hasUpg(this.layer, 166)) mult = mult.times(2) - if (hasUpg(this.layer, 12)) mult = mult.times(this.upgrades[12].effect()) + if (hasUpg(this.layer, 166)) mult = mult.times(2) // These upgrades don't exist + if (hasUpg(this.layer, 120)) mult = mult.times(this.upgrades[12].effect()) return mult }, gainExp() { // Calculate the exponent on main currency from bonuses