diff --git a/index.html b/index.html
index 4dfe786..eb54a0f 100644
--- a/index.html
+++ b/index.html
@@ -23,6 +23,14 @@
+
Beta v1.2 Alpha 12
+
+ - Balanced up to 1e9,200,000 Points, 5e18 Magic, and 1e16 Balance Energy
+
+
Beta v1.2 Alpha 11
+
+ - Balanced up to 1e7,650,000 Points, 1e16 Magic, and 4e13 Balance Energy
+
Beta v1.2 Alpha 10
- Made a few visual fixes
@@ -454,12 +462,15 @@
- Note: Activating a Spell uses 1 Magic.
+ Note: Activating a Spell costs Magic.
-
+
+
+
+
-
+
You have {{formatWhole(player.m.hexes)}} Hexes, which are multiplying Hindrance Spirit & Quirk gain by {{format(tmp.hexEff)}}
1 Magic Keep row 4 milestones on all resets |
diff --git a/js/game.js b/js/game.js
index 490e55b..a55e8d2 100644
--- a/js/game.js
+++ b/js/game.js
@@ -140,6 +140,16 @@ function getStartPlayer() {
3: 0,
},
hexes: new Decimal(0),
+ toCast: {
+ 1: "1",
+ 2: "1",
+ 3: "1",
+ },
+ casted: {
+ 1: new Decimal(1),
+ 2: new Decimal(1),
+ 3: new Decimal(1),
+ },
upgrades: [],
},
ba: {
@@ -279,8 +289,8 @@ const LAYER_EFFS = {
},
g: function() { return Decimal.pow(Decimal.add(2, tmp.atgb).times(tmp.sGenPowEff).times((player.ss.upgrades.includes(23) ? LAYER_UPGS.ss[23].currently() : 1)).max(0), player.g.points.times(getGenPow())).sub(1).times(getGenPowerGainMult()).max(0) },
t: function() { return {
- gain: Decimal.pow(3, player.t.points.plus(player.t.extCapsules.plus(tmp.freeExtCap).times(getFreeExtPow())).times(getCapPow())).sub(1).times(getTimeEnergyGainMult()),
- limit: Decimal.pow(2, player.t.points.plus(player.t.extCapsules.plus(tmp.freeExtCap).times(getFreeExtPow())).times(getCapPow())).sub(1).times(100).times(getTimeEnergyLimitMult()),
+ gain: Decimal.pow(Decimal.add(3, tmp.attb), player.t.points.plus(player.t.extCapsules.plus(tmp.freeExtCap).times(getFreeExtPow())).times(getCapPow())).sub(1).times(getTimeEnergyGainMult()),
+ limit: Decimal.pow(Decimal.add(2, tmp.attb), player.t.points.plus(player.t.extCapsules.plus(tmp.freeExtCap).times(getFreeExtPow())).times(getCapPow())).sub(1).times(100).times(getTimeEnergyLimitMult()),
}},
sb: function() { return Decimal.pow(Decimal.add(1.5, addToSBBase()), player.sb.points.times(getSuperBoosterPow())) },
sg: function() { return Decimal.pow(Decimal.add(2, addToSGBase()), player.sg.points).sub(1).times(getSuperGenPowerGainMult()).max(0) },
@@ -736,7 +746,7 @@ const LAYER_UPGS = {
},
},
s: {
- rows: 3,
+ rows: 4,
cols: 4,
11: {
desc: "Add a free level to all Space Buildings.",
@@ -810,6 +820,28 @@ const LAYER_UPGS = {
currently: function() { return Decimal.pow(Object.values(player.s.buildings).reduce((a,b) => Decimal.add(a,b)), 0.2).div(17.5) },
effDisp: function(x) { return "Add "+format(x)+" to exponent" },
},
+ 41: {
+ desc: "Total Space cheapens Space Buildings.",
+ cost: new Decimal(128),
+ unl: function() { return player.ba.upgrades.includes(51) },
+ currently: function() { return Decimal.pow("1e4000", getSpace().plus(player.s.spent).sqrt()) },
+ effDisp: function(x) { return "/"+format(x) },
+ },
+ 42: {
+ desc: "The Space Building cost formula is 40% weaker.",
+ cost: new Decimal(131),
+ unl: function() { return player.ba.upgrades.includes(51) },
+ },
+ 43: {
+ desc: "Space Building 2 uses a better formula.",
+ cost: new Decimal(133),
+ unl: function() { return player.ba.upgrades.includes(51) },
+ },
+ 44: {
+ desc: "Placeholder",
+ cost: new Decimal(1/0),
+ unl: function() { return player.ba.upgrades.includes(51) },
+ },
},
sb: {
rows: 2,
@@ -856,7 +888,7 @@ const LAYER_UPGS = {
cols: 0,
},
q: {
- rows: 4,
+ rows: 5,
cols: 4,
11: {
desc: "Quirks & Hindrance Spirit boost Point, Prestige Point, and Enhance Point gain.",
@@ -884,7 +916,7 @@ const LAYER_UPGS = {
desc: "Quirk Layers are faster based on your Quirks.",
cost: new Decimal(160),
unl: function() { return (player.q.upgrades.includes(12)||player.q.upgrades.includes(13))&&player.h.challs.includes(12) },
- currently: function() { return player.q.points.plus(1).log10().plus(1) },
+ currently: function() { return player.q.points.plus(1).log10().plus(1).pow(player.m.upgrades.includes(42)?1.5:1) },
effDisp: function(x) { return format(x)+"x" },
},
22: {
@@ -955,6 +987,28 @@ const LAYER_UPGS = {
currently: function() { return player.q.energy.plus(1).log10().plus(1) },
effDisp: function(x) { return format(x)+"x" },
},
+ 51: {
+ desc: "Get free Quirk Layers based on your Quirk Energy.",
+ cost: new Decimal("1e2100"),
+ unl: function() { return player.ba.upgrades.includes(52) },
+ currently: function() { return player.q.energy.plus(1).log10().plus(1).log10() },
+ effDisp: function(x) { return "+"+format(x) },
+ },
+ 52: {
+ desc: "Placeholder",
+ cost: new Decimal(1/0),
+ unl: function() { return player.ba.upgrades.includes(52) },
+ },
+ 53: {
+ desc: "Placeholder",
+ cost: new Decimal(1/0),
+ unl: function() { return player.ba.upgrades.includes(52) },
+ },
+ 54: {
+ desc: "Placeholder",
+ cost: new Decimal(1/0),
+ unl: function() { return player.ba.upgrades.includes(52) },
+ },
},
hb: {
rows: 1,
@@ -1051,7 +1105,7 @@ const LAYER_UPGS = {
},
},
m: {
- rows: 3,
+ rows: 4,
cols: 4,
11: {
desc: "Hexes boost all Spells.",
@@ -1073,7 +1127,7 @@ const LAYER_UPGS = {
effDisp: function(x) { return "+"+format(x)+" to base" },
},
14: {
- desc: "You get more Hexes when casting Spells based on your best Magic.",
+ desc: "You get more Hexes based on your best Magic.",
cost: new Decimal(100),
unl: function() { return player.m.upgrades.includes(12) },
currently: function() { return player.m.best.div(3).plus(1).pow(0.8) },
@@ -1127,9 +1181,33 @@ const LAYER_UPGS = {
cost: new Decimal(4e10),
unl: function() { return player.m.upgrades.includes(32) },
},
+ 41: {
+ desc: "You can insert more Magic into Spells, making them stronger.",
+ cost: new Decimal(2.5e14),
+ unl: function() { return player.m.upgrades.includes(34) },
+ },
+ 42: {
+ desc: "Quirk Upgrade 5 is 50% stronger.",
+ cost: new Decimal(1e15),
+ unl: function() { return player.m.upgrades.includes(34) },
+ },
+ 43: {
+ desc: "Spells last longer based on your Hexes.",
+ cost: new Decimal(2e15),
+ unl: function() { return player.m.upgrades.includes(41) },
+ currently: function() { return player.m.hexes.plus(1).log10().plus(1).sqrt().min(86400) },
+ effDisp: function(x) { return format(x)+"x" },
+ },
+ 44: {
+ desc: "Magic adds to the Time Capsule base.",
+ cost: new Decimal(4e15),
+ unl: function() { return player.m.upgrades.includes(41) },
+ currently: function() { return player.m.points.plus(1).log10().div(10) },
+ effDisp: function(x) { return "+"+format(x) },
+ },
},
ba: {
- rows: 4,
+ rows: 5,
cols: 4,
11: {
desc: "All Balance Energy effects use better formulas.",
@@ -1223,6 +1301,26 @@ const LAYER_UPGS = {
unl: function() { return player.ba.upgrades.includes(41)||player.ba.upgrades.includes(42) },
},
44: {
+ desc: "Space Buildings are 50% stronger.",
+ cost: new Decimal(2e12),
+ unl: function() { return player.ba.upgrades.includes(42)||player.ba.upgrades.includes(43) },
+ },
+ 51: {
+ desc: "Unlock 4 new Space Upgrades.",
+ cost: new Decimal(4e13),
+ unl: function() { return player.ba.upgrades.includes(43) },
+ },
+ 52: {
+ desc: "Unlock 4 new Quirk Upgrades.",
+ cost: new Decimal(2e14),
+ unl: function() { return player.ba.upgrades.includes(51) },
+ },
+ 53: {
+ desc: "???",
+ cost: new Decimal(1/0),
+ unl: function() { return false },
+ },
+ 54: {
desc: "???",
cost: new Decimal(1/0),
unl: function() { return false },
@@ -1442,6 +1540,8 @@ function checkForVars() {
if (player.ss.auto === undefined) player.ss.auto = false
if (player.m === undefined) player.m = start.m
if (player.m.auto === undefined) player.m.auto = false
+ if (player.m.toCast === undefined) player.m.toCast = start.m.toCast
+ if (player.m.casted === undefined) player.m.casted = start.m.casted
if (player.ba === undefined) player.ba = start.ba
if (player.offlineProd === undefined) player.offlineProd = true
}
@@ -1486,6 +1586,7 @@ function convertToDecimal() {
player.m.points = new Decimal(player.m.points)
player.m.best = new Decimal(player.m.best)
player.m.hexes = new Decimal(player.m.hexes)
+ for (let i=1;i<=3;i++) player.m.casted[i] = new Decimal(player.m.casted[i])
player.ba.points = new Decimal(player.ba.points)
player.ba.best = new Decimal(player.ba.best)
player.ba.power = new Decimal(player.ba.power)
@@ -1951,6 +2052,7 @@ function buyUpg(layer, id) {
if (layer=="s"&&id==33) player.s.order = 0;
if (layer=="hb"&&id==13) player.hb.order = 0;
if (layer=="ss"&&id==15) player.ss.order = 0;
+ if (layer=="m"&&id==43) for (let i=1;i<=3;i++) player.m.spellTimes[i] *= LAYER_UPGS.m[43].currently().toNumber()
}
function getPointGen() {
@@ -2189,6 +2291,12 @@ function maxExtTimeCapsules() {
player.t.extCapsules = player.t.extCapsules.max(target)
}
+function addToTimeBase() {
+ let toAdd = new Decimal(0)
+ if (player.m.upgrades.includes(44)) toAdd = toAdd.plus(LAYER_UPGS.m[44].currently())
+ return toAdd
+}
+
function getSpace() {
let baseSpace = player.s.best.pow(1.1).times(3).floor()
if (player.s.upgrades.includes(13)&&!(tmp.hcActive?tmp.hcActive[12]:true)) baseSpace = baseSpace.plus(2);
@@ -2200,13 +2308,15 @@ function getSpace() {
function getSpaceBuildingCostMod() {
let mod = new Decimal(1)
- if (player.s.upgrades.includes(24)&&!(tmp.hcActive?tmp.hcActive[12]:true)) mod = new Decimal(0.5)
+ if (player.s.upgrades.includes(24)&&!(tmp.hcActive?tmp.hcActive[12]:true)) mod = mod.times(0.5)
+ if (player.s.upgrades.includes(42)) mod = mod.times(0.6)
return mod;
}
function getSpaceBuildingCostMult() {
let mult = new Decimal(1)
if (player.ss.unl) mult = mult.div(tmp.ssEff2)
+ if (player.s.upgrades.includes(41)) mult = mult.div(LAYER_UPGS.s[41].currently())
return mult
}
@@ -2235,6 +2345,7 @@ function getSpaceBuildingPow() {
if (player.s.upgrades.includes(23)&&!(tmp.hcActive?tmp.hcActive[12]:true)) pow = pow.times(LAYER_UPGS.s[23].currently())
if (player.q.upgrades.includes(41)) pow = pow.times(1.4)
if (player.ss.unl) pow = pow.times(tmp.ssEff3)
+ if (player.ba.upgrades.includes(44)) pow = pow.times(1.5)
return pow
}
@@ -2261,8 +2372,9 @@ function getSpaceBuildingEff(x) {
if (player.ba.upgrades.includes(42)) ret = ret.pow(LAYER_UPGS.ba[42].currently())
return ret;
break;
- case 2:
- return bought.sqrt()
+ case 2:
+ if (player.s.upgrades.includes(43)) return Decimal.pow(1.0001, bought).times(bought.sqrt())
+ else return bought.sqrt()
break;
case 3:
return Decimal.pow(1e18, bought.pow(0.9))
@@ -2397,6 +2509,7 @@ function getQuirkLayerMult() {
function getExtraQuirkLayers() {
let layers = new Decimal(0);
+ if (player.q.upgrades.includes(51)) layers = layers.plus(LAYER_UPGS.q[51].currently())
if (player.m.upgrades.includes(24)) layers = layers.plus(LAYER_UPGS.m[24].currently())
if (player.m.upgrades.includes(34)) layers = layers.plus(1)
return layers;
@@ -2715,6 +2828,7 @@ function getSpellPower(x) {
if (player.m.upgrades.includes(11)) power = power.times(LAYER_UPGS.m[11].currently())
if (player.m.upgrades.includes(21) && (x==2||x==3)) power = power.times(LAYER_UPGS.m[21].currently())
if (player.m.upgrades.includes(22) && (x==2)) power = power.times(10)
+ if (player.m.upgrades.includes(41)) power = power.times(player.m.casted[x].max(1).log10().plus(1).log10().div(5).plus(1))
return power;
}
@@ -2734,6 +2848,7 @@ function getSpellDesc(x) {
function getSpellTime() {
let time = 20
if (player.m.best.gte(2.5e9)) time *= 10
+ if (player.m.upgrades.includes(43)) time *= LAYER_UPGS.m[43].currently().toNumber()
return time
}
@@ -2743,13 +2858,17 @@ function spellActive(x) {
return player.m.spellTimes[x]>0
}
-function activateSpell(x) {
- if (!player.m.unl) return
- if (spellActive(x)) return
- if (player.m.points.lt(1)) return
- player.m.points = player.m.points.sub(1)
+function activateSpell(x, force=false) {
+ let toCast = setToCast(player.m.toCast[x])
+ if (!force) {
+ if (!player.m.unl) return
+ if (spellActive(x)) return
+ if (player.m.points.lt(toCast)) return
+ }
+ player.m.points = player.m.points.sub(toCast)
+ player.m.casted[x] = toCast
player.m.spellTimes[x] = getSpellTime()
- player.m.hexes = player.m.hexes.plus(getHexGain())
+ if (!force) player.m.hexes = player.m.hexes.plus(getHexGain())
}
function getHexGain() {
@@ -2763,6 +2882,29 @@ function getHexEff() {
return eff;
}
+function isToCastValid(val) {
+ try {
+ val = new Decimal(val).floor()
+ if (val.eq(undefined) || val.eq(null)) return false
+ if (val.lt(1)) return false
+ if (val.gt(player.m.points)) return false
+ return val;
+ } catch(e) {
+ return false;
+ }
+}
+
+function setToCast(val) {
+ if (!player.m.upgrades.includes(41)) return new Decimal(1)
+ let validVal = isToCastValid(val)
+ if (!validVal) return new Decimal(1)
+ else return validVal
+}
+
+function updateToCast(id) {
+ activateSpell(id, true)
+}
+
function getSGenPowEff() {
if (!player.sg.unl) return new Decimal(1)
if (!player.h.challs.includes(62)) return new Decimal(1)
diff --git a/js/temp.js b/js/temp.js
index 19247b3..db531a7 100644
--- a/js/temp.js
+++ b/js/temp.js
@@ -41,6 +41,7 @@ function updateTemp() {
tmp.freeExtCap = getFreeExtCapsules()
tmp.timeEff = getTimeEnergyEff()
+ tmp.attb = addToTimeBase()
if (!tmp.spaceBuildEff) tmp.spaceBuildEff = {}
for (let i=1;i<=5;i++) tmp.spaceBuildEff[i] = getSpaceBuildingEff(i)
diff --git a/js/v.js b/js/v.js
index 0c8c95c..458d8ac 100644
--- a/js/v.js
+++ b/js/v.js
@@ -31,6 +31,7 @@ function loadVue() {
getSpellDesc,
activateSpell,
spellActive,
+ updateToCast,
LAYERS,
LAYER_RES,
LAYER_TYPE,