forked from profectus/Profectus
Used 2 layers tree to test mechanics
This commit is contained in:
parent
f50d634812
commit
3772f65919
17 changed files with 325 additions and 281 deletions
|
@ -4,6 +4,7 @@
|
||||||
transform: scale(1.05, 1.05);
|
transform: scale(1.05, 1.05);
|
||||||
border-color: rgba(0, 0, 0, 0.125);
|
border-color: rgba(0, 0, 0, 0.125);
|
||||||
box-shadow: -4px -4px 4px rgba(0, 0, 0, 0.25) inset, 0 0 20px #ff0000;
|
box-shadow: -4px -4px 4px rgba(0, 0, 0, 0.25) inset, 0 0 20px #ff0000;
|
||||||
|
z-index: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
.subtabs > .notify:not(.floating) {
|
.subtabs > .notify:not(.floating) {
|
||||||
|
@ -13,6 +14,7 @@
|
||||||
*:not(.subtabs) > .resetNotify:not(.notify),
|
*:not(.subtabs) > .resetNotify:not(.notify),
|
||||||
*:not(.subtabs) > .resetNotify:not(.notify) button {
|
*:not(.subtabs) > .resetNotify:not(.notify) button {
|
||||||
box-shadow: -4px -4px 4px rgba(0, 0, 0, 0.25) inset, 0 0 8px #ffffff;
|
box-shadow: -4px -4px 4px rgba(0, 0, 0, 0.25) inset, 0 0 8px #ffffff;
|
||||||
|
z-index: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
.subtabs > .resetNotify:not(.notify):not(.floating) {
|
.subtabs > .resetNotify:not(.notify):not(.floating) {
|
||||||
|
|
|
@ -15,11 +15,16 @@
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-flow: row wrap;
|
flex-flow: row wrap;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
align-items: center;
|
align-items: stretch;
|
||||||
max-width: 100%;
|
max-width: 100%;
|
||||||
margin: 0 10px;
|
margin: 0 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.row > * {
|
||||||
|
margin: 0;
|
||||||
|
display: flex;
|
||||||
|
}
|
||||||
|
|
||||||
.col {
|
.col {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-flow: column wrap;
|
flex-flow: column wrap;
|
||||||
|
|
|
@ -10,10 +10,10 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<frament v-else>
|
<row v-frag v-else>
|
||||||
<buyable v-for="(buyable, id) in filteredBuyables" :key="id" class="align buyable-container" :style="{ height }"
|
<buyable v-for="(buyable, id) in filteredBuyables" :key="id" class="align buyable-container"
|
||||||
:id="id" :size="height === 'inherit' ? null : height" />
|
:style="{ height }" :id="id" :size="height === 'inherit' ? null : height" />
|
||||||
</frament>
|
</row>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
|
|
@ -79,8 +79,8 @@ export default {
|
||||||
<style scoped>
|
<style scoped>
|
||||||
.challenge {
|
.challenge {
|
||||||
background-color: var(--locked);
|
background-color: var(--locked);
|
||||||
width: 250px;
|
width: 300px;
|
||||||
min-height: 250px;
|
min-height: 300px;
|
||||||
color: black;
|
color: black;
|
||||||
font-size: 15px;
|
font-size: 15px;
|
||||||
display: flex;
|
display: flex;
|
||||||
|
|
|
@ -3,10 +3,10 @@
|
||||||
<button :style="style" @click="clickable.click" @mousedown="start" @mouseleave="stop" @mouseup="stop" @touchstart="start"
|
<button :style="style" @click="clickable.click" @mousedown="start" @mouseleave="stop" @mouseup="stop" @touchstart="start"
|
||||||
@touchend="stop" @touchcancel="stop" :disabled="!clickable.canClick"
|
@touchend="stop" @touchcancel="stop" :disabled="!clickable.canClick"
|
||||||
:class="{ feature: true, [layer || tab.layer]: true, clickable: true, can: clickable.canClick, locked: !clickable.canClick }">
|
:class="{ feature: true, [layer || tab.layer]: true, clickable: true, can: clickable.canClick, locked: !clickable.canClick }">
|
||||||
<div v-if="titleDisplay">
|
<div v-if="title">
|
||||||
<component :is="titleDisplay" />
|
<component :is="title" />
|
||||||
</div>
|
</div>
|
||||||
<component :is="descriptionDisplay" style="white-space: pre-line;" />
|
<component :is="display" style="white-space: pre-line;" />
|
||||||
<mark-node :mark="clickable.mark" />
|
<mark-node :mark="clickable.mark" />
|
||||||
<branch-node :branches="clickable.branches" :id="id" featureType="clickable" />
|
<branch-node :branches="clickable.branches" :id="id" featureType="clickable" />
|
||||||
</button>
|
</button>
|
||||||
|
@ -45,14 +45,14 @@ export default {
|
||||||
this.clickable.style
|
this.clickable.style
|
||||||
];
|
];
|
||||||
},
|
},
|
||||||
titleDisplay() {
|
title() {
|
||||||
if (this.clickable.titleDisplay) {
|
if (this.clickable.title) {
|
||||||
return coerceComponent(this.clickable.titleDisplay, 'h2');
|
return coerceComponent(this.clickable.title, 'h2');
|
||||||
}
|
}
|
||||||
return null;
|
return null;
|
||||||
},
|
},
|
||||||
descriptionDisplay() {
|
display() {
|
||||||
return coerceComponent(this.clickable.descriptionDisplay, 'div');
|
return coerceComponent(this.clickable.display, 'div');
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
|
|
@ -29,7 +29,7 @@ export default {
|
||||||
if (this.challenge.goalDescription) {
|
if (this.challenge.goalDescription) {
|
||||||
return coerceComponent(this.challenge.goalDescription);
|
return coerceComponent(this.challenge.goalDescription);
|
||||||
}
|
}
|
||||||
return coerceComponent(`format(${this.goal}) ${this.currencyDisplayName || 'points'}`);
|
return coerceComponent(`{{ format(${this.challenge.goal}) }} ${this.currencyDisplayName || 'points'}`);
|
||||||
},
|
},
|
||||||
rewardDescription() {
|
rewardDescription() {
|
||||||
return coerceComponent(this.challenge.rewardDescription);
|
return coerceComponent(this.challenge.rewardDescription);
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
<span v-if="showPrefix">You have</span>
|
<span v-if="showPrefix">You have</span>
|
||||||
<resource :amount="amount" :color="color" />
|
<resource :amount="amount" :color="color" />
|
||||||
{{ resource }}<!-- remove whitespace -->
|
{{ resource }}<!-- remove whitespace -->
|
||||||
<span v-if="effectDescription">, <component :is="effectDescription" /></span>
|
<span v-if="effectDisplay">, <component :is="effectDisplay" /></span>
|
||||||
<br><br>
|
<br><br>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
@ -28,8 +28,8 @@ export default {
|
||||||
resource() {
|
resource() {
|
||||||
return layers[this.layer || this.tab.layer].resource;
|
return layers[this.layer || this.tab.layer].resource;
|
||||||
},
|
},
|
||||||
effectDescription() {
|
effectDisplay() {
|
||||||
return coerceComponent(layers[this.layer || this.tab.layer].effectDescription);
|
return coerceComponent(layers[this.layer || this.tab.layer].effectDisplay);
|
||||||
},
|
},
|
||||||
showPrefix() {
|
showPrefix() {
|
||||||
return player[this.layer || this.tab.layer].points.lt('1e1000');
|
return player[this.layer || this.tab.layer].points.lt('1e1000');
|
||||||
|
|
|
@ -21,6 +21,7 @@ export default {
|
||||||
top: -10px;
|
top: -10px;
|
||||||
width: 30px;
|
width: 30px;
|
||||||
height: 30px;
|
height: 30px;
|
||||||
|
z-index: 1;
|
||||||
pointer-events: none;
|
pointer-events: none;
|
||||||
margin-left: 0.9em;
|
margin-left: 0.9em;
|
||||||
margin-right: 0.9em;
|
margin-right: 0.9em;
|
||||||
|
@ -35,7 +36,6 @@ export default {
|
||||||
left: -10px;
|
left: -10px;
|
||||||
width: 0;
|
width: 0;
|
||||||
height: 0;
|
height: 0;
|
||||||
z-index: 10000;
|
|
||||||
margin-left: 0.9em;
|
margin-left: 0.9em;
|
||||||
margin-right: 0.9em;
|
margin-right: 0.9em;
|
||||||
margin-bottom: 1.2em;
|
margin-bottom: 1.2em;
|
||||||
|
|
|
@ -5,9 +5,11 @@
|
||||||
<button class="layer-tab minimized" v-if="minimized" @click="toggleMinimized"><div>{{ name }}</div></button>
|
<button class="layer-tab minimized" v-if="minimized" @click="toggleMinimized"><div>{{ name }}</div></button>
|
||||||
<div class="layer-tab" :style="style" :class="{ hasSubtabs: subtabs }" v-else>
|
<div class="layer-tab" :style="style" :class="{ hasSubtabs: subtabs }" v-else>
|
||||||
<branches>
|
<branches>
|
||||||
<sticky v-if="subtabs" class="subtabs" :class="{ floating, firstTab: firstTab || !allowGoBack }">
|
<sticky v-if="subtabs" class="subtabs-container" :class="{ floating, firstTab: firstTab || !allowGoBack }">
|
||||||
|
<div class="subtabs">
|
||||||
<tab-button v-for="(subtab, id) in subtabs" @selectTab="selectSubtab(id)" :key="id"
|
<tab-button v-for="(subtab, id) in subtabs" @selectTab="selectSubtab(id)" :key="id"
|
||||||
:activeTab="id === activeSubtab" :options="subtab" :text="id" />
|
:activeTab="id === activeSubtab" :options="subtab" :text="id" />
|
||||||
|
</div>
|
||||||
</sticky>
|
</sticky>
|
||||||
<component v-if="display" :is="display" />
|
<component v-if="display" :is="display" />
|
||||||
<default-layer-tab v-else />
|
<default-layer-tab v-else />
|
||||||
|
@ -202,22 +204,27 @@ export default {
|
||||||
.layer-tab .subtabs {
|
.layer-tab .subtabs {
|
||||||
margin-bottom: 24px;
|
margin-bottom: 24px;
|
||||||
display: flex;
|
display: flex;
|
||||||
|
flex-flow: wrap;
|
||||||
|
padding-right: 60px;
|
||||||
z-index: 4;
|
z-index: 4;
|
||||||
}
|
}
|
||||||
|
|
||||||
.subtabs:not(.floating) {
|
.subtabs-container:not(.floating) {
|
||||||
width: calc(100% + 14px);
|
|
||||||
border-top: solid 4px var(--separator);
|
border-top: solid 4px var(--separator);
|
||||||
border-bottom: solid 4px var(--separator);
|
border-bottom: solid 4px var(--separator);
|
||||||
height: 50px;
|
}
|
||||||
|
|
||||||
|
.subtabs-container:not(.floating) .subtabs {
|
||||||
|
width: calc(100% + 14px);
|
||||||
margin-left: -7px;
|
margin-left: -7px;
|
||||||
margin-right: -7px;
|
margin-right: -7px;
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
text-align: left;
|
text-align: left;
|
||||||
padding-left: 14px;
|
padding-left: 14px;
|
||||||
|
margin-bottom: -4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.subtabs.floating {
|
.subtabs-container.floating .subtabs {
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
margin-top: -25px;
|
margin-top: -25px;
|
||||||
}
|
}
|
||||||
|
@ -237,24 +244,27 @@ export default {
|
||||||
padding-left: 0;
|
padding-left: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.subtabs:not(.floating).firstTab {
|
.subtabs-container:not(.floating).firstTab .subtabs {
|
||||||
padding-left: 0;
|
padding-left: 0;
|
||||||
padding-right: 0;
|
padding-right: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.subtabs:not(.floating):first-child {
|
.subtabs-container:not(.floating):first-child {
|
||||||
margin-top: -50px;
|
|
||||||
border-top: 0;
|
border-top: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.subtabs:not(.floating):not(.firstTab) {
|
.subtabs-container:not(.floating):first-child .subtabs {
|
||||||
|
margin-top: -50px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.subtabs-container:not(.floating):not(.firstTab) .subtabs {
|
||||||
padding-left: 70px;
|
padding-left: 70px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.minimize {
|
.minimize {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 0;
|
top: 0;
|
||||||
right: 15px;
|
right: 0;
|
||||||
background-color: transparent;
|
background-color: transparent;
|
||||||
border: 1px solid transparent;
|
border: 1px solid transparent;
|
||||||
color: var(--color);
|
color: var(--color);
|
||||||
|
@ -262,6 +272,8 @@ export default {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
line-height: 40px;
|
line-height: 40px;
|
||||||
z-index: 7;
|
z-index: 7;
|
||||||
|
width: 60px;
|
||||||
|
background: var(--background);
|
||||||
}
|
}
|
||||||
|
|
||||||
.minimized + .minimize {
|
.minimized + .minimize {
|
||||||
|
|
|
@ -56,6 +56,7 @@ export default {
|
||||||
margin: 5px;
|
margin: 5px;
|
||||||
border-radius: 5px;
|
border-radius: 5px;
|
||||||
border: 2px solid;
|
border: 2px solid;
|
||||||
|
flex-shrink: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.tabButton:hover {
|
.tabButton:hover {
|
||||||
|
|
|
@ -126,6 +126,7 @@ export default {
|
||||||
color: rgba(0, 0, 0, 0.5);
|
color: rgba(0, 0, 0, 0.5);
|
||||||
text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.25);
|
text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.25);
|
||||||
box-shadow: -4px -4px 4px rgba(0, 0, 0, 0.25) inset, 0px 0px 20px var(--background);
|
box-shadow: -4px -4px 4px rgba(0, 0, 0, 0.25) inset, 0px 0px 20px var(--background);
|
||||||
|
text-transform: capitalize;
|
||||||
}
|
}
|
||||||
|
|
||||||
.treeNode.small {
|
.treeNode.small {
|
||||||
|
|
|
@ -50,7 +50,7 @@ export default {
|
||||||
waffleBoost: Decimal.pow(player[this.layer].points, 0.2),
|
waffleBoost: Decimal.pow(player[this.layer].points, 0.2),
|
||||||
icecreamCap: (player[this.layer].points * 10)
|
icecreamCap: (player[this.layer].points * 10)
|
||||||
}},
|
}},
|
||||||
effectDescription() { // Optional text to describe the effects
|
effectDisplay() { // Optional text to describe the effects
|
||||||
let eff = this.effect;
|
let eff = this.effect;
|
||||||
const waffleBoost = eff.waffleBoost.times(buyableEffect(this.layer, 11).first)
|
const waffleBoost = eff.waffleBoost.times(buyableEffect(this.layer, 11).first)
|
||||||
return "which are boosting waffles by "+format(waffleBoost)+" and increasing the Ice Cream cap by "+format(eff.icecreamCap)
|
return "which are boosting waffles by "+format(waffleBoost)+" and increasing the Ice Cream cap by "+format(eff.icecreamCap)
|
||||||
|
|
|
@ -18,69 +18,69 @@ export default {
|
||||||
let require = new Decimal(8).plus(player.i.points.div(10).floor().times(2))
|
let require = new Decimal(8).plus(player.i.points.div(10).floor().times(2))
|
||||||
return require
|
return require
|
||||||
} , // Can be a function that takes requirement increases into account
|
} , // Can be a function that takes requirement increases into account
|
||||||
effectDescription(){return "Multiplying points and prestige points by "+format(player[this.layer].points.plus(1).pow(hasUpgrade("p",235)?6.9420:1))},
|
effectDisplay(){return "Multiplying points and prestige points by "+format(player[this.layer].points.plus(1).pow(hasUpgrade("p",235)?6.9420:1))},
|
||||||
resource: "Infinity", // Name of prestige currency
|
resource: "Infinity", // Name of prestige currency
|
||||||
baseResource: "pointy points", // Name of resource prestige is based on
|
baseResource: "pointy points", // Name of resource prestige is based on
|
||||||
baseAmount() {return player.p.buyables[21]}, // Get the current amount of baseResource
|
baseAmount() {return player.p.buyables[21]}, // Get the current amount of baseResource
|
||||||
type: "custom", // normal: cost to gain currency depends on amount gained. static: cost depends on how much you already have
|
type: "custom", // normal: cost to gain currency depends on amount gained. static: cost depends on how much you already have
|
||||||
getResetGain(){
|
resetGain(){
|
||||||
|
|
||||||
if (hasMilestone("p",12)){return getBuyableAmount("p",21).div(2).floor().times(2).times(5).sub(30).sub(player.i.points)}
|
if (hasMilestone("p",12)){return getBuyableAmount("p",21).div(2).floor().times(2).times(5).sub(30).sub(player.i.points)}
|
||||||
return (player.p.buyables[21].gte(layers.i.requires)?1:0)}, // Prestige currency exponent
|
return (player.p.buyables[21].gte(layers.i.requires)?1:0)}, // Prestige currency exponent
|
||||||
getNextAt(){return new Decimal(100)},
|
getNextAt(){return new Decimal(100)},
|
||||||
canReset(){return player.p.buyables[21].gte(layers.i.requires)},
|
canReset(){return player.p.buyables[21].gte(layers.i.requires)},
|
||||||
prestigeButtonText(){return "Reset everything for +"+format(layers.i.getResetGain)+" Infinity.<br>You need "+format(layers.i.requires())+" pointy points to reset."},
|
prestigeButtonDisplay(){return "Reset everything for +"+format(layers.i.resetGain)+" Infinity.<br>You need "+format(layers.i.requires)+" pointy points to reset."},
|
||||||
row: 1, // Row the layer is in on the tree (0 is the first row)
|
row: 1, // Row the layer is in on the tree (0 is the first row)
|
||||||
|
displayRow: 3,
|
||||||
hotkeys: [
|
hotkeys: [
|
||||||
{key: "i", description: "I: Infinity", press(){if (layers.i.canReset) resetLayer(this.layer)}},
|
{key: "i", description: "I: Infinity", press(){if (layers.i.canReset) resetLayer(this.layer)}},
|
||||||
],
|
],
|
||||||
layerShown(){return player[this.layer].unlocked||new Decimal(player.p.buyables[21]).gte(8)},
|
layerShown(){return player[this.layer].unlocked||new Decimal(player.p.buyables[21]).gte(8)},
|
||||||
milestones: {
|
milestones: {
|
||||||
0: {
|
0: {
|
||||||
requirementDescription: "2 Infinity points",
|
requirementDisplay: "2 Infinity points",
|
||||||
effectDescription: "Keep ALL milestones on reset",
|
effectDisplay: "Keep ALL milestones on reset",
|
||||||
done() { return player[this.layer].points.gte(2) },
|
done() { return player[this.layer].points.gte(2) },
|
||||||
|
|
||||||
},
|
},
|
||||||
1: {
|
1: {
|
||||||
requirementDescription: "3 Infinity points",
|
requirementDisplay: "3 Infinity points",
|
||||||
effectDescription: "Pointy points don't reset generators",
|
effectDisplay: "Pointy points don't reset generators",
|
||||||
done() { return player[this.layer].points.gte(3) },
|
done() { return player[this.layer].points.gte(3) },
|
||||||
unlocked(){return hasMilestone(this.layer,this.id-1)}
|
unlocked(){return hasMilestone(this.layer,this.id-1)}
|
||||||
},
|
},
|
||||||
2: {
|
2: {
|
||||||
requirementDescription: "4 Infinity points",
|
requirementDisplay: "4 Infinity points",
|
||||||
effectDescription: "Start with 6 <b>Time Dilation</b>, 3 <b>Point</b>, and 1 of the other 2 challenges",
|
effectDisplay: "Start with 6 <b>Time Dilation</b>, 3 <b>Point</b>, and 1 of the other 2 challenges",
|
||||||
done() { return player[this.layer].points.gte(4) },
|
done() { return player[this.layer].points.gte(4) },
|
||||||
unlocked(){return hasMilestone(this.layer,this.id-1)}
|
unlocked(){return hasMilestone(this.layer,this.id-1)}
|
||||||
},
|
},
|
||||||
3: {
|
3: {
|
||||||
requirementDescription: "5 Infinity points",
|
requirementDisplay: "5 Infinity points",
|
||||||
effectDescription: "Start with 40 upgrades and 6 boosts",
|
effectDisplay: "Start with 40 upgrades and 6 boosts",
|
||||||
done() { return player[this.layer].points.gte(5) },
|
done() { return player[this.layer].points.gte(5) },
|
||||||
unlocked(){return hasMilestone(this.layer,this.id-1)}
|
unlocked(){return hasMilestone(this.layer,this.id-1)}
|
||||||
},
|
},
|
||||||
4: {
|
4: {
|
||||||
requirementDescription: "6 Infinity points",
|
requirementDisplay: "6 Infinity points",
|
||||||
effectDescription: "You can choose all of the 14th row upgrades, and remove the respec button",
|
effectDisplay: "You can choose all of the 14th row upgrades, and remove the respec button",
|
||||||
done() { return player[this.layer].points.gte(6) },
|
done() { return player[this.layer].points.gte(6) },
|
||||||
unlocked(){return hasMilestone(this.layer,this.id-1)}
|
unlocked(){return hasMilestone(this.layer,this.id-1)}
|
||||||
},
|
},
|
||||||
5: {
|
5: {
|
||||||
requirementDescription: "8 Infinity points",
|
requirementDisplay: "8 Infinity points",
|
||||||
effectDescription: "Keep all upgrades and 7 Time dilation",
|
effectDisplay: "Keep all upgrades and 7 Time dilation",
|
||||||
done() { return player[this.layer].points.gte(8) },
|
done() { return player[this.layer].points.gte(8) },
|
||||||
unlocked(){return hasMilestone(this.layer,this.id-1)}
|
unlocked(){return hasMilestone(this.layer,this.id-1)}
|
||||||
},
|
},
|
||||||
6: {
|
6: {
|
||||||
requirementDescription: "10 Infinity points",
|
requirementDisplay: "10 Infinity points",
|
||||||
effectDescription: "Infinity reset nothing and auto prestige",
|
effectDisplay: "Infinity reset nothing and auto prestige",
|
||||||
done() { return player[this.layer].points.gte(10) },
|
done() { return player[this.layer].points.gte(10) },
|
||||||
unlocked(){return hasMilestone(this.layer,this.id-1)}
|
unlocked(){return hasMilestone(this.layer,this.id-1)}
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
resetsNothing(){return hasMilestone(this.layer,6)},
|
resetsNothing(){return hasMilestone(this.layer,6)},
|
||||||
autoPrestige(){return hasMilestone(this.layer,6)},
|
|
||||||
update(){
|
update(){
|
||||||
if (hasMilestone(this.layer,0)){
|
if (hasMilestone(this.layer,0)){
|
||||||
if (!hasMilestone("p",0)){
|
if (!hasMilestone("p",0)){
|
||||||
|
@ -97,10 +97,10 @@ update(){
|
||||||
}
|
}
|
||||||
if (hasMilestone(this.layer,2)){
|
if (hasMilestone(this.layer,2)){
|
||||||
if (!hasChallenge("p",11)){
|
if (!hasChallenge("p",11)){
|
||||||
player.p.challenges[11]=(hasMilestone(this.layer,5)?7:6)
|
player.p.challenges[11]=new Decimal(hasMilestone(this.layer,5)?7:6)
|
||||||
player.p.challenges[12]=3
|
player.p.challenges[12]=new Decimal(3)
|
||||||
player.p.challenges[21]=1
|
player.p.challenges[21]=new Decimal(1)
|
||||||
player.p.challenges[22]=1
|
player.p.challenges[22]=new Decimal(1)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (hasMilestone(this.layer,3)){
|
if (hasMilestone(this.layer,3)){
|
||||||
|
@ -112,16 +112,19 @@ update(){
|
||||||
if (hasUpgrade(this.layer,13)){
|
if (hasUpgrade(this.layer,13)){
|
||||||
|
|
||||||
for (let i=0;i<(hasUpgrade("p",222)?100:hasUpgrade("p",215)?10:1);i++){
|
for (let i=0;i<(hasUpgrade("p",222)?100:hasUpgrade("p",215)?10:1);i++){
|
||||||
if (layers.p.buyables[12].canAfford())layers.p.buyables[12].buy()
|
if (layers.p.buyables[12].canAfford)layers.p.buyables[12].buy()
|
||||||
if (layers.p.buyables[13].canAfford())layers.p.buyables[13].buy()
|
if (layers.p.buyables[13].canAfford)layers.p.buyables[13].buy()
|
||||||
if (layers.p.buyables[14].canAfford()&&layers.p.buyables[14].unlocked())layers.p.buyables[14].buy()
|
if (layers.p.buyables[14].canAfford&&layers.p.buyables[14].unlocked())layers.p.buyables[14].buy()
|
||||||
if (layers.p.buyables[21].canAfford())layers.p.buyables[21].buy()}
|
if (layers.p.buyables[21].canAfford)layers.p.buyables[21].buy()}
|
||||||
}
|
}
|
||||||
if (hasUpgrade("p",223)){
|
if (hasUpgrade("p",223)){
|
||||||
if (hasMilestone("p",14))player.p.buyables[22]=player.p.buyables[22].max(player.p.buyables[21].sub(7))
|
if (hasMilestone("p",14))player.p.buyables[22]=player.p.buyables[22].max(player.p.buyables[21].sub(7))
|
||||||
else if (layers.p.buyables[22].canAfford())layers.p.buyables[22].buy()
|
else if (layers.p.buyables[22].canAfford)layers.p.buyables[22].buy()
|
||||||
}
|
}
|
||||||
if (hasMilestone(this.layer,5)&&!hasUpgrade("p",111)){player.p.upgrades=[11,12,13,14,21,22,23,24,31,32,33,34,41,42,43,44,51,52,53,54,61,62,63,64,71,72,73,74,81,82,83,84,91,92,93,94,101,102,103,104,111,121,122,131,132,141,142,143]}
|
if (hasMilestone(this.layer,5)&&!hasUpgrade("p",111)){player.p.upgrades=[11,12,13,14,21,22,23,24,31,32,33,34,41,42,43,44,51,52,53,54,61,62,63,64,71,72,73,74,81,82,83,84,91,92,93,94,101,102,103,104,111,121,122,131,132,141,142,143]}
|
||||||
|
if (hasMilestone(this.layer,6)) {
|
||||||
|
this.reset();
|
||||||
|
}
|
||||||
},
|
},
|
||||||
upgrades:{
|
upgrades:{
|
||||||
rows: 999,
|
rows: 999,
|
||||||
|
|
|
@ -19,10 +19,10 @@ export default {
|
||||||
requires(){
|
requires(){
|
||||||
let require = new Decimal(68.99)
|
let require = new Decimal(68.99)
|
||||||
if (hasMilestone(this.layer,0))require=require.plus(0.01)
|
if (hasMilestone(this.layer,0))require=require.plus(0.01)
|
||||||
if (hasUpgrade(this.layer,21))require=require.tetrate(hasUpgrade("p",34)?(new Decimal(1).div(new Decimal(1).plus(layers.p.upgrades[34].effect()))):1)
|
if (hasUpgrade(this.layer,21))require=require.tetrate(hasUpgrade("p",34)?(new Decimal(1).div(new Decimal(1).plus(layers.p.upgrades[34].effect))):1)
|
||||||
if (hasUpgrade(this.layer,22))require=require.pow(hasUpgrade("p",34)?(new Decimal(1).div(new Decimal(1).plus(layers.p.upgrades[34].effect()))):1)
|
if (hasUpgrade(this.layer,22))require=require.pow(hasUpgrade("p",34)?(new Decimal(1).div(new Decimal(1).plus(layers.p.upgrades[34].effect))):1)
|
||||||
if (hasUpgrade(this.layer,23))require=require.div(hasUpgrade("p",34)?(new Decimal(1).plus(layers.p.upgrades[34].effect())):1)
|
if (hasUpgrade(this.layer,23))require=require.div(hasUpgrade("p",34)?(new Decimal(1).plus(layers.p.upgrades[34].effect)):1)
|
||||||
if (hasUpgrade(this.layer,24))require=require.sub(hasUpgrade("p",34)?(new Decimal(1).plus(layers.p.upgrades[34].effect())):1)
|
if (hasUpgrade(this.layer,24))require=require.sub(hasUpgrade("p",34)?(new Decimal(1).plus(layers.p.upgrades[34].effect)):1)
|
||||||
return require.max(1)
|
return require.max(1)
|
||||||
},
|
},
|
||||||
resource: "prestige points",
|
resource: "prestige points",
|
||||||
|
@ -39,13 +39,14 @@ export default {
|
||||||
let asdf = (hasUpgrade("p",132)?player.p.gp.plus(1).pow(new Decimal(1).div(2)):hasUpgrade("p",101)?player.p.gp.plus(1).pow(new Decimal(1).div(3)):hasUpgrade("p",93)?player.p.gp.plus(1).pow(0.2):player.p.gp.plus(1).log10())
|
let asdf = (hasUpgrade("p",132)?player.p.gp.plus(1).pow(new Decimal(1).div(2)):hasUpgrade("p",101)?player.p.gp.plus(1).pow(new Decimal(1).div(3)):hasUpgrade("p",93)?player.p.gp.plus(1).pow(0.2):player.p.gp.plus(1).log10())
|
||||||
mult=mult.mul(asdf.plus(1))
|
mult=mult.mul(asdf.plus(1))
|
||||||
}
|
}
|
||||||
if (hasMilestone(this.layer,13))mult=mult.mul(new Decimal(2).plus(layers.p.buyables[33].effect()).pow(getBuyableAmount(this.layer,32)))
|
if (hasMilestone(this.layer,13))mult=mult.mul(new Decimal(2).plus(layers.p.buyables[33].effect).pow(getBuyableAmount(this.layer,32)))
|
||||||
return mult
|
return mult
|
||||||
},
|
},
|
||||||
gainExp() { // Calculate the exponent on main currency from bonuses
|
gainExp() { // Calculate the exponent on main currency from bonuses
|
||||||
return new Decimal(1)
|
return new Decimal(1)
|
||||||
},
|
},
|
||||||
row: 0, // Row the layer is in on the tree (0 is the first row)
|
row: 0, // Row the layer is in on the tree (0 is the first row)
|
||||||
|
displayRow: 2,
|
||||||
hotkeys: [
|
hotkeys: [
|
||||||
{key: "p", description: "P: Reset for prestige points", press(){if (layers.p.canReset) resetLayer(this.layer)}},
|
{key: "p", description: "P: Reset for prestige points", press(){if (layers.p.canReset) resetLayer(this.layer)}},
|
||||||
],
|
],
|
||||||
|
@ -123,40 +124,40 @@ export default {
|
||||||
},
|
},
|
||||||
34:{
|
34:{
|
||||||
title: "Increase",
|
title: "Increase",
|
||||||
description(){return "Add 0.01 to all above upgrades. Currently: +"+format(this.effect())},
|
description(){return "Add 0.01 to all above upgrades. Currently: +"+format(this.effect)},
|
||||||
cost(){return new Decimal(1)},
|
cost(){return new Decimal(1)},
|
||||||
unlocked(){return hasUpgrade(this.layer,33)},
|
unlocked(){return hasUpgrade(this.layer,33)},
|
||||||
effect(){
|
effect(){
|
||||||
let r = (hasUpgrade("p",41)?new Decimal(0.01).times(layers.p.upgrades[41].effect()):new Decimal(0.01))
|
let r = (hasUpgrade("p",41)?new Decimal(0.01).times(layers.p.upgrades[41].effect):new Decimal(0.01))
|
||||||
r=r.times(new Decimal(1).plus(new Decimal(player[this.layer].challenges[11]+1).pow(hasUpgrade(this.layer,121)?1.2:1)))
|
r=r.times(new Decimal(1).plus(new Decimal(player[this.layer].challenges[11]).add(1).pow(hasUpgrade(this.layer,121)?1.2:1)))
|
||||||
if (hasUpgrade(this.layer,92)) r=r.plus(new Decimal(0.001).times(player[this.layer].g.plus(1)).min(0.05))
|
if (hasUpgrade(this.layer,92)) r=r.plus(new Decimal(0.001).times(player[this.layer].g.plus(1)).min(0.05))
|
||||||
return r
|
return r
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
41:{
|
41:{
|
||||||
title: "Increase again",
|
title: "Increase again",
|
||||||
description(){return "Multiply the previous upgrade by 1.01. Currently: x"+format(this.effect())},
|
description(){return "Multiply the previous upgrade by 1.01. Currently: x"+format(this.effect)},
|
||||||
cost(){return new Decimal(1)},
|
cost(){return new Decimal(1)},
|
||||||
unlocked(){return hasUpgrade(this.layer,34)},
|
unlocked(){return hasUpgrade(this.layer,34)},
|
||||||
effect(){return new Decimal(1.01).pow(hasUpgrade("p",42)?layers.p.upgrades[42].effect():1).times(hasUpgrade("p",63)?2:1)}
|
effect(){return new Decimal(1.01).pow(hasUpgrade("p",42)?layers.p.upgrades[42].effect:1).times(hasUpgrade("p",63)?2:1)}
|
||||||
},
|
},
|
||||||
42:{
|
42:{
|
||||||
title: "Increase again",
|
title: "Increase again",
|
||||||
description(){return "Exponentiate the previous upgrade by 1.01. Currently: ^"+format(this.effect())},
|
description(){return "Exponentiate the previous upgrade by 1.01. Currently: ^"+format(this.effect)},
|
||||||
cost(){return new Decimal(1)},
|
cost(){return new Decimal(1)},
|
||||||
unlocked(){return hasUpgrade(this.layer,41)},
|
unlocked(){return hasUpgrade(this.layer,41)},
|
||||||
effect(){return new Decimal(1.01).tetrate(hasUpgrade("p",43)?layers.p.upgrades[43].effect():1).times(hasUpgrade("p",63)?2:1).times(hasUpgrade("p",64)?2:1)}
|
effect(){return new Decimal(1.01).tetrate(hasUpgrade("p",43)?layers.p.upgrades[43].effect:1).times(hasUpgrade("p",63)?2:1).times(hasUpgrade("p",64)?2:1)}
|
||||||
},
|
},
|
||||||
43:{
|
43:{
|
||||||
title: "Increase again",
|
title: "Increase again",
|
||||||
description(){return "Tetrate the previous upgrade by 1.01. Currently: ^^"+format(this.effect())},
|
description(){return "Tetrate the previous upgrade by 1.01. Currently: ^^"+format(this.effect)},
|
||||||
cost(){return new Decimal(1)},
|
cost(){return new Decimal(1)},
|
||||||
unlocked(){return hasUpgrade(this.layer,42)},
|
unlocked(){return hasUpgrade(this.layer,42)},
|
||||||
effect(){return new Decimal(1.01).pentate(hasUpgrade("p",44)?layers.p.upgrades[44].effect():1).times(hasUpgrade("p",63)?2:1).times(hasUpgrade("p",64)?2:1)}
|
effect(){return new Decimal(1.01).pentate(hasUpgrade("p",44)?layers.p.upgrades[44].effect:1).times(hasUpgrade("p",63)?2:1).times(hasUpgrade("p",64)?2:1)}
|
||||||
},
|
},
|
||||||
44:{
|
44:{
|
||||||
title: "Increase again",
|
title: "Increase again",
|
||||||
description(){return "Pentate the previous upgrade by 1.01. Currently: ^^^"+format(this.effect())},
|
description(){return "Pentate the previous upgrade by 1.01. Currently: ^^^"+format(this.effect)},
|
||||||
cost(){return new Decimal(1)},
|
cost(){return new Decimal(1)},
|
||||||
unlocked(){return hasUpgrade(this.layer,43)},
|
unlocked(){return hasUpgrade(this.layer,43)},
|
||||||
effect(){return new Decimal(1.01).times(hasUpgrade("p",63)?2:1).times(hasUpgrade("p",64)?2:1)}
|
effect(){return new Decimal(1.01).times(hasUpgrade("p",63)?2:1).times(hasUpgrade("p",64)?2:1)}
|
||||||
|
@ -373,88 +374,88 @@ export default {
|
||||||
title: "Prestige",
|
title: "Prestige",
|
||||||
description: "Pointy points multiply points",
|
description: "Pointy points multiply points",
|
||||||
cost(){return new Decimal(1)},
|
cost(){return new Decimal(1)},
|
||||||
canAfford(){return getBuyableAmount(this.layer,22).gte(this.cost())},
|
canAfford(){return getBuyableAmount(this.layer,22).gte(this.cost)},
|
||||||
pay(){setBuyableAmount(this.layer,22,getBuyableAmount(this.layer,22).sub(this.cost()))},
|
pay(){setBuyableAmount(this.layer,22,getBuyableAmount(this.layer,22).sub(this.cost))},
|
||||||
unlocked(){return (hasMilestone("i",5)&&layers.p.activeSubtab!="Upgrades")},
|
unlocked(){return (hasMilestone("i",5)&&layers.p.activeSubtab!="Upgrades")},
|
||||||
},
|
},
|
||||||
212:{
|
212:{
|
||||||
title: "Pointy",
|
title: "Pointy",
|
||||||
description: "Pointy prestige points reduce the cost scaling of pointy points",
|
description: "Pointy prestige points reduce the cost scaling of pointy points",
|
||||||
cost(){return new Decimal(2)},
|
cost(){return new Decimal(2)},
|
||||||
canAfford(){return getBuyableAmount(this.layer,22).gte(this.cost())},
|
canAfford(){return getBuyableAmount(this.layer,22).gte(this.cost)},
|
||||||
pay(){setBuyableAmount(this.layer,22,getBuyableAmount(this.layer,22).sub(this.cost()))},
|
pay(){setBuyableAmount(this.layer,22,getBuyableAmount(this.layer,22).sub(this.cost))},
|
||||||
unlocked(){return (hasMilestone("i",5)&&layers.p.activeSubtab!="Upgrades"&&hasUpgrade(this.layer,211))},
|
unlocked(){return (hasMilestone("i",5)&&layers.p.activeSubtab!="Upgrades"&&hasUpgrade(this.layer,211))},
|
||||||
},
|
},
|
||||||
213:{
|
213:{
|
||||||
title: "Time",
|
title: "Time",
|
||||||
description: "Generator power also multiplies point gain",
|
description: "Generator power also multiplies point gain",
|
||||||
cost(){return new Decimal(6)},
|
cost(){return new Decimal(6)},
|
||||||
canAfford(){return getBuyableAmount(this.layer,22).gte(this.cost())},
|
canAfford(){return getBuyableAmount(this.layer,22).gte(this.cost)},
|
||||||
pay(){setBuyableAmount(this.layer,22,getBuyableAmount(this.layer,22).sub(this.cost()))},
|
pay(){setBuyableAmount(this.layer,22,getBuyableAmount(this.layer,22).sub(this.cost))},
|
||||||
unlocked(){return (hasMilestone("i",5)&&layers.p.activeSubtab!="Upgrades"&&hasUpgrade(this.layer,212))},
|
unlocked(){return (hasMilestone("i",5)&&layers.p.activeSubtab!="Upgrades"&&hasUpgrade(this.layer,212))},
|
||||||
},
|
},
|
||||||
214:{
|
214:{
|
||||||
title: "^0",
|
title: "^0",
|
||||||
description: "Further reduce the pointy point scaling",
|
description: "Further reduce the pointy point scaling",
|
||||||
cost(){return new Decimal(11)},
|
cost(){return new Decimal(11)},
|
||||||
canAfford(){return getBuyableAmount(this.layer,22).gte(this.cost())},
|
canAfford(){return getBuyableAmount(this.layer,22).gte(this.cost)},
|
||||||
pay(){setBuyableAmount(this.layer,22,getBuyableAmount(this.layer,22).sub(this.cost()))},
|
pay(){setBuyableAmount(this.layer,22,getBuyableAmount(this.layer,22).sub(this.cost))},
|
||||||
unlocked(){return (hasMilestone("i",5)&&layers.p.activeSubtab!="Upgrades"&&hasUpgrade(this.layer,213))},
|
unlocked(){return (hasMilestone("i",5)&&layers.p.activeSubtab!="Upgrades"&&hasUpgrade(this.layer,213))},
|
||||||
},
|
},
|
||||||
215:{
|
215:{
|
||||||
title: "bulk",
|
title: "bulk",
|
||||||
description: "Auto-pointy points now buys 10 per tick",
|
description: "Auto-pointy points now buys 10 per tick",
|
||||||
cost(){return new Decimal(27)},
|
cost(){return new Decimal(27)},
|
||||||
canAfford(){return getBuyableAmount(this.layer,22).gte(this.cost())},
|
canAfford(){return getBuyableAmount(this.layer,22).gte(this.cost)},
|
||||||
pay(){setBuyableAmount(this.layer,22,getBuyableAmount(this.layer,22).sub(this.cost()))},
|
pay(){setBuyableAmount(this.layer,22,getBuyableAmount(this.layer,22).sub(this.cost))},
|
||||||
unlocked(){return (hasMilestone("i",5)&&layers.p.activeSubtab!="Upgrades"&&hasUpgrade(this.layer,214))},
|
unlocked(){return (hasMilestone("i",5)&&layers.p.activeSubtab!="Upgrades"&&hasUpgrade(this.layer,214))},
|
||||||
},
|
},
|
||||||
221:{
|
221:{
|
||||||
title: "^-1",
|
title: "^-1",
|
||||||
description: "^0 is even more powerful",
|
description: "^0 is even more powerful",
|
||||||
cost(){return new Decimal(28)},
|
cost(){return new Decimal(28)},
|
||||||
canAfford(){return getBuyableAmount(this.layer,22).gte(this.cost())},
|
canAfford(){return getBuyableAmount(this.layer,22).gte(this.cost)},
|
||||||
pay(){setBuyableAmount(this.layer,22,getBuyableAmount(this.layer,22).sub(this.cost()))},
|
pay(){setBuyableAmount(this.layer,22,getBuyableAmount(this.layer,22).sub(this.cost))},
|
||||||
unlocked(){return (hasMilestone("i",5)&&layers.p.activeSubtab!="Upgrades"&&hasUpgrade(this.layer,215))},
|
unlocked(){return (hasMilestone("i",5)&&layers.p.activeSubtab!="Upgrades"&&hasUpgrade(this.layer,215))},
|
||||||
},
|
},
|
||||||
222:{
|
222:{
|
||||||
title: "???",
|
title: "???",
|
||||||
description: "square <b>bulk</b> and pointy prestige points multiply prestige points",
|
description: "square <b>bulk</b> and pointy prestige points multiply prestige points",
|
||||||
cost(){return new Decimal(90)},
|
cost(){return new Decimal(90)},
|
||||||
canAfford(){return getBuyableAmount(this.layer,22).gte(this.cost())},
|
canAfford(){return getBuyableAmount(this.layer,22).gte(this.cost)},
|
||||||
pay(){setBuyableAmount(this.layer,22,getBuyableAmount(this.layer,22).sub(this.cost()))},
|
pay(){setBuyableAmount(this.layer,22,getBuyableAmount(this.layer,22).sub(this.cost))},
|
||||||
unlocked(){return (hasMilestone("i",5)&&layers.p.activeSubtab!="Upgrades"&&hasUpgrade(this.layer,221))},
|
unlocked(){return (hasMilestone("i",5)&&layers.p.activeSubtab!="Upgrades"&&hasUpgrade(this.layer,221))},
|
||||||
},
|
},
|
||||||
223:{
|
223:{
|
||||||
title: "more automation",
|
title: "more automation",
|
||||||
description: "Automatically gain pointy prestige points",
|
description: "Automatically gain pointy prestige points",
|
||||||
cost(){return new Decimal(96)},
|
cost(){return new Decimal(96)},
|
||||||
canAfford(){return getBuyableAmount(this.layer,22).gte(this.cost())},
|
canAfford(){return getBuyableAmount(this.layer,22).gte(this.cost)},
|
||||||
pay(){setBuyableAmount(this.layer,22,getBuyableAmount(this.layer,22).sub(this.cost()))},
|
pay(){setBuyableAmount(this.layer,22,getBuyableAmount(this.layer,22).sub(this.cost))},
|
||||||
unlocked(){return (hasMilestone("i",5)&&layers.p.activeSubtab!="Upgrades"&&hasUpgrade(this.layer,222))},
|
unlocked(){return (hasMilestone("i",5)&&layers.p.activeSubtab!="Upgrades"&&hasUpgrade(this.layer,222))},
|
||||||
},
|
},
|
||||||
224:{
|
224:{
|
||||||
title: "Generation",
|
title: "Generation",
|
||||||
description: "Generator costs are divided by generator effect",
|
description: "Generator costs are divided by generator effect",
|
||||||
cost(){return new Decimal(100)},
|
cost(){return new Decimal(100)},
|
||||||
canAfford(){return getBuyableAmount(this.layer,22).gte(this.cost())},
|
canAfford(){return getBuyableAmount(this.layer,22).gte(this.cost)},
|
||||||
pay(){setBuyableAmount(this.layer,22,getBuyableAmount(this.layer,22).sub(this.cost()))},
|
pay(){setBuyableAmount(this.layer,22,getBuyableAmount(this.layer,22).sub(this.cost))},
|
||||||
unlocked(){return (hasMilestone("i",5)&&layers.p.activeSubtab!="Upgrades"&&hasUpgrade(this.layer,223))},
|
unlocked(){return (hasMilestone("i",5)&&layers.p.activeSubtab!="Upgrades"&&hasUpgrade(this.layer,223))},
|
||||||
},
|
},
|
||||||
225:{
|
225:{
|
||||||
title: "Boosters",
|
title: "Boosters",
|
||||||
description: "Unlock boosters (next update)",
|
description: "Unlock boosters (next update)",
|
||||||
cost(){return new Decimal(135)},
|
cost(){return new Decimal(135)},
|
||||||
canAfford(){return getBuyableAmount(this.layer,22).gte(this.cost())},
|
canAfford(){return getBuyableAmount(this.layer,22).gte(this.cost)},
|
||||||
pay(){setBuyableAmount(this.layer,22,getBuyableAmount(this.layer,22).sub(this.cost()))},
|
pay(){setBuyableAmount(this.layer,22,getBuyableAmount(this.layer,22).sub(this.cost))},
|
||||||
unlocked(){return (hasMilestone("i",5)&&layers.p.activeSubtab!="Upgrades"&&hasUpgrade(this.layer,224))},
|
unlocked(){return (hasMilestone("i",5)&&layers.p.activeSubtab!="Upgrades"&&hasUpgrade(this.layer,224))},
|
||||||
},
|
},
|
||||||
231:{
|
231:{
|
||||||
title: "Blue",
|
title: "Blue",
|
||||||
description: "The generator effect also affects prestige points",
|
description: "The generator effect also affects prestige points",
|
||||||
cost(){return new Decimal(4)},
|
cost(){return new Decimal(4)},
|
||||||
canAfford(){return getBuyableAmount(this.layer,23).gte(this.cost())},
|
canAfford(){return getBuyableAmount(this.layer,23).gte(this.cost)},
|
||||||
pay(){setBuyableAmount(this.layer,23,getBuyableAmount(this.layer,23).sub(this.cost()))},
|
pay(){setBuyableAmount(this.layer,23,getBuyableAmount(this.layer,23).sub(this.cost))},
|
||||||
unlocked(){return (layers.p.activeSubtab!="Upgrades"&&hasMilestone(this.layer,11))},
|
unlocked(){return (layers.p.activeSubtab!="Upgrades"&&hasMilestone(this.layer,11))},
|
||||||
currencyDisplayName: "pointy boosters"
|
currencyDisplayName: "pointy boosters"
|
||||||
},
|
},
|
||||||
|
@ -462,8 +463,8 @@ export default {
|
||||||
title: "Red",
|
title: "Red",
|
||||||
description: "Unlock a third way to buy generators",
|
description: "Unlock a third way to buy generators",
|
||||||
cost(){return new Decimal(5)},
|
cost(){return new Decimal(5)},
|
||||||
canAfford(){return getBuyableAmount(this.layer,23).gte(this.cost())},
|
canAfford(){return getBuyableAmount(this.layer,23).gte(this.cost)},
|
||||||
pay(){setBuyableAmount(this.layer,23,getBuyableAmount(this.layer,23).sub(this.cost()))},
|
pay(){setBuyableAmount(this.layer,23,getBuyableAmount(this.layer,23).sub(this.cost))},
|
||||||
unlocked(){return (layers.p.activeSubtab!="Upgrades"&&hasMilestone(this.layer,12))},
|
unlocked(){return (layers.p.activeSubtab!="Upgrades"&&hasMilestone(this.layer,12))},
|
||||||
currencyDisplayName: "pointy boosters"
|
currencyDisplayName: "pointy boosters"
|
||||||
},
|
},
|
||||||
|
@ -471,8 +472,8 @@ export default {
|
||||||
title: "Green",
|
title: "Green",
|
||||||
description: "Prestige points do not reset your pointy points and boosters don't reset generators",
|
description: "Prestige points do not reset your pointy points and boosters don't reset generators",
|
||||||
cost(){return new Decimal(5)},
|
cost(){return new Decimal(5)},
|
||||||
canAfford(){return getBuyableAmount(this.layer,23).gte(this.cost())},
|
canAfford(){return getBuyableAmount(this.layer,23).gte(this.cost)},
|
||||||
pay(){setBuyableAmount(this.layer,23,getBuyableAmount(this.layer,23).sub(this.cost()))},
|
pay(){setBuyableAmount(this.layer,23,getBuyableAmount(this.layer,23).sub(this.cost))},
|
||||||
unlocked(){return (layers.p.activeSubtab!="Upgrades"&&hasMilestone(this.layer,12))},
|
unlocked(){return (layers.p.activeSubtab!="Upgrades"&&hasMilestone(this.layer,12))},
|
||||||
currencyDisplayName: "pointy boosters"
|
currencyDisplayName: "pointy boosters"
|
||||||
},
|
},
|
||||||
|
@ -480,8 +481,8 @@ export default {
|
||||||
title: "Yellow",
|
title: "Yellow",
|
||||||
description: "Divide the cost of the third generator buyable based on boosters",
|
description: "Divide the cost of the third generator buyable based on boosters",
|
||||||
cost(){return new Decimal(6)},
|
cost(){return new Decimal(6)},
|
||||||
canAfford(){return getBuyableAmount(this.layer,23).gte(this.cost())},
|
canAfford(){return getBuyableAmount(this.layer,23).gte(this.cost)},
|
||||||
pay(){setBuyableAmount(this.layer,23,getBuyableAmount(this.layer,23).sub(this.cost()))},
|
pay(){setBuyableAmount(this.layer,23,getBuyableAmount(this.layer,23).sub(this.cost))},
|
||||||
unlocked(){return (layers.p.activeSubtab!="Upgrades"&&hasMilestone(this.layer,12))},
|
unlocked(){return (layers.p.activeSubtab!="Upgrades"&&hasMilestone(this.layer,12))},
|
||||||
currencyDisplayName: "pointy boosters"
|
currencyDisplayName: "pointy boosters"
|
||||||
},
|
},
|
||||||
|
@ -489,8 +490,8 @@ export default {
|
||||||
title: "Orange",
|
title: "Orange",
|
||||||
description: "Raise the Infinity effect to the 6.9420th power",
|
description: "Raise the Infinity effect to the 6.9420th power",
|
||||||
cost(){return new Decimal(8)},
|
cost(){return new Decimal(8)},
|
||||||
canAfford(){return getBuyableAmount(this.layer,23).gte(this.cost())},
|
canAfford(){return getBuyableAmount(this.layer,23).gte(this.cost)},
|
||||||
pay(){setBuyableAmount(this.layer,23,getBuyableAmount(this.layer,23).sub(this.cost()))},
|
pay(){setBuyableAmount(this.layer,23,getBuyableAmount(this.layer,23).sub(this.cost))},
|
||||||
unlocked(){return (layers.p.activeSubtab!="Upgrades"&&hasMilestone(this.layer,12))},
|
unlocked(){return (layers.p.activeSubtab!="Upgrades"&&hasMilestone(this.layer,12))},
|
||||||
currencyDisplayName: "pointy boosters"
|
currencyDisplayName: "pointy boosters"
|
||||||
},
|
},
|
||||||
|
@ -517,8 +518,8 @@ challenges:{
|
||||||
11:{
|
11:{
|
||||||
name: "Time dilation",
|
name: "Time dilation",
|
||||||
challengeDescription(){return "Point gain exponent is raised to the ^0.75"},
|
challengeDescription(){return "Point gain exponent is raised to the ^0.75"},
|
||||||
goal(){return new Decimal(100).times(new Decimal(10).pow(new Decimal(player[this.layer].challenges[this.id]).times(new Decimal(1).sub(new Decimal(layers[this.layer].challenges[12].effect()).div(100))).pow(2)))},
|
goal(){return new Decimal(100).times(new Decimal(10).pow(new Decimal(player[this.layer].challenges[this.id]).times(new Decimal(1).sub(new Decimal(layers[this.layer].challenges[12].effect).div(100))).pow(2)))},
|
||||||
rewardDescription(){return "You have completed this challenge "+player[this.layer].challenges[this.id]+"/"+this.completionLimit()+" times. Multiply <b>Increase</b>'s effect by challenge completions+1. Currently: x"+format(new Decimal(player[this.layer].challenges[this.id]+1).pow(hasUpgrade(this.layer,121)?1.2:1))},
|
rewardDescription(){return "You have completed this challenge "+player[this.layer].challenges[this.id]+"/"+this.completionLimit+" times. Multiply <b>Increase</b>'s effect by challenge completions+1. Currently: x"+format(new Decimal(player[this.layer].challenges[this.id]).add(1).pow(hasUpgrade(this.layer,121)?1.2:1))},
|
||||||
unlocked(){return hasUpgrade("p",51)||hasChallenge(this.layer,this.id)},
|
unlocked(){return hasUpgrade("p",51)||hasChallenge(this.layer,this.id)},
|
||||||
completionLimit(){
|
completionLimit(){
|
||||||
if (hasUpgrade("p",62))return 7
|
if (hasUpgrade("p",62))return 7
|
||||||
|
@ -532,7 +533,7 @@ challenges:{
|
||||||
name: "Point",
|
name: "Point",
|
||||||
challengeDescription: "Points are pointed",
|
challengeDescription: "Points are pointed",
|
||||||
goal(){return new Decimal(100)},
|
goal(){return new Decimal(100)},
|
||||||
rewardDescription(){return "You have completed this challenge "+player[this.layer].challenges[this.id]+"/"+this.completionLimit()+" times, making previous challenge goal scale "+(layers[this.layer].challenges[this.id].effect())+"% slower."},
|
rewardDescription(){return "You have completed this challenge "+player[this.layer].challenges[this.id]+"/"+this.completionLimit+" times, making previous challenge goal scale "+(layers[this.layer].challenges[this.id].effect)+"% slower."},
|
||||||
unlocked(){return hasUpgrade("p",61)||hasChallenge(this.layer,this.id)},
|
unlocked(){return hasUpgrade("p",61)||hasChallenge(this.layer,this.id)},
|
||||||
effect(){
|
effect(){
|
||||||
if (!hasChallenge(this.layer,this.id)) return 0
|
if (!hasChallenge(this.layer,this.id)) return 0
|
||||||
|
@ -569,9 +570,9 @@ challenges:{
|
||||||
11: {
|
11: {
|
||||||
cost() { return new Decimal(0)},
|
cost() { return new Decimal(0)},
|
||||||
display() { return "Reset all upgrades and challenges, but get a boost. You have reset "+getBuyableAmount(this.layer,this.id)+" times.<br>"+(getBuyableAmount(this.layer,this.id).eq(6)?"You can't buy more than 6 boosts!":"You need all upgrades to reset.") },
|
display() { return "Reset all upgrades and challenges, but get a boost. You have reset "+getBuyableAmount(this.layer,this.id)+" times.<br>"+(getBuyableAmount(this.layer,this.id).eq(6)?"You can't buy more than 6 boosts!":"You need all upgrades to reset.") },
|
||||||
canAfford() { return (player[this.layer].points.gte(this.cost())&&hasUpgrade(this.layer,74)&&hasUpgrade(this.layer,64))&&getBuyableAmount(this.layer,this.id).lt(6) },
|
canAfford() { return (player[this.layer].points.gte(this.cost)&&hasUpgrade(this.layer,74)&&hasUpgrade(this.layer,64))&&getBuyableAmount(this.layer,this.id).lt(6) },
|
||||||
buy() {
|
buy() {
|
||||||
player[this.layer].points = player[this.layer].points.sub(this.cost())
|
player[this.layer].points = player[this.layer].points.sub(this.cost)
|
||||||
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
||||||
player[this.layer].points=new Decimal(0)
|
player[this.layer].points=new Decimal(0)
|
||||||
player[this.layer].upgrades=[]
|
player[this.layer].upgrades=[]
|
||||||
|
@ -579,7 +580,7 @@ challenges:{
|
||||||
if (hasMilestone(this.layer,3))player[this.layer].upgrades=[11,12,13,14,21,22,23,24,31,32,33,34,41,42,43,44,51,52,53,54,61,62,63,64]
|
if (hasMilestone(this.layer,3))player[this.layer].upgrades=[11,12,13,14,21,22,23,24,31,32,33,34,41,42,43,44,51,52,53,54,61,62,63,64]
|
||||||
if (!hasMilestone(this.layer,2)){
|
if (!hasMilestone(this.layer,2)){
|
||||||
for (let c in layers[this.layer].challenges){
|
for (let c in layers[this.layer].challenges){
|
||||||
player[this.layer].challenges[c]=0
|
player[this.layer].challenges[c]=new Decimal(0)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -587,10 +588,10 @@ challenges:{
|
||||||
},
|
},
|
||||||
12: {
|
12: {
|
||||||
cost() { return new Decimal(1).times(new Decimal(hasChallenge(this.layer,21)?4:10).sub(hasUpgrade(this.layer,122)?2:0).pow(player.p.buyables[this.id])).div(hasUpgrade(this.layer,224)?(hasUpgrade("p",132)?player.p.gp.plus(1).pow(new Decimal(1).div(2)):hasUpgrade("p",101)?player.p.gp.plus(1).pow(new Decimal(1).div(3)):hasUpgrade("p",93)?player.p.gp.plus(1).pow(0.2):player.p.gp.plus(1).log10()):1)},
|
cost() { return new Decimal(1).times(new Decimal(hasChallenge(this.layer,21)?4:10).sub(hasUpgrade(this.layer,122)?2:0).pow(player.p.buyables[this.id])).div(hasUpgrade(this.layer,224)?(hasUpgrade("p",132)?player.p.gp.plus(1).pow(new Decimal(1).div(2)):hasUpgrade("p",101)?player.p.gp.plus(1).pow(new Decimal(1).div(3)):hasUpgrade("p",93)?player.p.gp.plus(1).pow(0.2):player.p.gp.plus(1).log10()):1)},
|
||||||
display() { return "Buy a generator for "+format(this.cost())+" points" },
|
display() { return "Buy a generator for "+format(this.cost)+" points" },
|
||||||
canAfford() { return (player.points.gte(this.cost())&&hasMilestone(this.layer,5)) },
|
canAfford() { return (player.points.gte(this.cost)&&hasMilestone(this.layer,5)) },
|
||||||
buy() {
|
buy() {
|
||||||
if (!hasMilestone("p",13))player.points = player.points.sub(this.cost())
|
if (!hasMilestone("p",13))player.points = player.points.sub(this.cost)
|
||||||
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
||||||
player[this.layer].g=player[this.layer].g.plus(1)
|
player[this.layer].g=player[this.layer].g.plus(1)
|
||||||
},
|
},
|
||||||
|
@ -598,10 +599,10 @@ challenges:{
|
||||||
},
|
},
|
||||||
13: {
|
13: {
|
||||||
cost() { return new Decimal(1).times(new Decimal(2).pow(player.p.buyables[this.id])).div(hasUpgrade(this.layer,224)?(hasUpgrade("p",132)?player.p.gp.plus(1).pow(new Decimal(1).div(2)):hasUpgrade("p",101)?player.p.gp.plus(1).pow(new Decimal(1).div(3)):hasUpgrade("p",93)?player.p.gp.plus(1).pow(0.2):player.p.gp.plus(1).log10()):1)},
|
cost() { return new Decimal(1).times(new Decimal(2).pow(player.p.buyables[this.id])).div(hasUpgrade(this.layer,224)?(hasUpgrade("p",132)?player.p.gp.plus(1).pow(new Decimal(1).div(2)):hasUpgrade("p",101)?player.p.gp.plus(1).pow(new Decimal(1).div(3)):hasUpgrade("p",93)?player.p.gp.plus(1).pow(0.2):player.p.gp.plus(1).log10()):1)},
|
||||||
display() { return "Buy a generator for "+format(this.cost())+" prestige points" },
|
display() { return "Buy a generator for "+format(this.cost)+" prestige points" },
|
||||||
canAfford() { return (player.p.points.gte(this.cost())&&hasUpgrade("p",82)) },
|
canAfford() { return (player.p.points.gte(this.cost)&&hasUpgrade("p",82)) },
|
||||||
buy() {
|
buy() {
|
||||||
if (!hasMilestone("p",13))player.p.points = player.p.points.sub(this.cost())
|
if (!hasMilestone("p",13))player.p.points = player.p.points.sub(this.cost)
|
||||||
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
||||||
player[this.layer].g=player[this.layer].g.plus(1)
|
player[this.layer].g=player[this.layer].g.plus(1)
|
||||||
},
|
},
|
||||||
|
@ -609,10 +610,10 @@ challenges:{
|
||||||
},
|
},
|
||||||
14: {
|
14: {
|
||||||
cost() { return new Decimal(900).mul(new Decimal(1.01).pow(getBuyableAmount(this.layer,this.id))).round().div(hasUpgrade(this.layer,234)?getBuyableAmount(this.layer,23).pow(0.3).plus(1):1)},
|
cost() { return new Decimal(900).mul(new Decimal(1.01).pow(getBuyableAmount(this.layer,this.id))).round().div(hasUpgrade(this.layer,234)?getBuyableAmount(this.layer,23).pow(0.3).plus(1):1)},
|
||||||
display() { return "Buy a generator for "+format(this.cost())+" Infinity points" },
|
display() { return "Buy a generator for "+format(this.cost)+" Infinity points" },
|
||||||
canAfford() { return (player.i.points.gte(this.cost())&&hasUpgrade("p",232)) },
|
canAfford() { return (player.i.points.gte(this.cost)&&hasUpgrade("p",232)) },
|
||||||
buy() {
|
buy() {
|
||||||
if (!hasMilestone("p",13))player.i.points = player.i.points.sub(this.cost()).round()
|
if (!hasMilestone("p",13))player.i.points = player.i.points.sub(this.cost).round()
|
||||||
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
||||||
player[this.layer].g=player[this.layer].g.plus(1)
|
player[this.layer].g=player[this.layer].g.plus(1)
|
||||||
},
|
},
|
||||||
|
@ -620,8 +621,8 @@ challenges:{
|
||||||
},
|
},
|
||||||
21: {
|
21: {
|
||||||
cost() { return new Decimal(20).plus(getBuyableAmount(this.layer, this.id).pow(new Decimal(2).sub(new Decimal(hasUpgrade(this.layer,221)?0.9:hasUpgrade(this.layer,214)?0.6:0.3).times(hasUpgrade(this.layer,212)?(new Decimal(1).sub(new Decimal(0.75).pow(getBuyableAmount(this.layer,22)))):0))))},
|
cost() { return new Decimal(20).plus(getBuyableAmount(this.layer, this.id).pow(new Decimal(2).sub(new Decimal(hasUpgrade(this.layer,221)?0.9:hasUpgrade(this.layer,214)?0.6:0.3).times(hasUpgrade(this.layer,212)?(new Decimal(1).sub(new Decimal(0.75).pow(getBuyableAmount(this.layer,22)))):0))))},
|
||||||
display() { return "Reset your generators for +1 pointy point! Cost: "+format(this.cost())+" Generators" },
|
display() { return "Reset your generators for +1 pointy point! Cost: "+format(this.cost)+" Generators" },
|
||||||
canAfford() { return (player.p.g.gte(this.cost())&&hasUpgrade("p",104)) },
|
canAfford() { return (player.p.g.gte(this.cost)&&hasUpgrade("p",104)) },
|
||||||
buy() {
|
buy() {
|
||||||
if (!hasMilestone("i",1))player.p.g = new Decimal(0)
|
if (!hasMilestone("i",1))player.p.g = new Decimal(0)
|
||||||
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
||||||
|
@ -633,20 +634,20 @@ challenges:{
|
||||||
},
|
},
|
||||||
22: {
|
22: {
|
||||||
cost() { return new Decimal(8).plus(getBuyableAmount(this.layer,this.id))},
|
cost() { return new Decimal(8).plus(getBuyableAmount(this.layer,this.id))},
|
||||||
display() { return "Gain a pointy prestige point. Cost: "+format(this.cost())+" Pointy Points" },
|
display() { return "Gain a pointy prestige point. Cost: "+format(this.cost)+" Pointy Points" },
|
||||||
canAfford() { return (getBuyableAmount(this.layer,21).gte(this.cost())&&(hasMilestone("i",5))) },
|
canAfford() { return (getBuyableAmount(this.layer,21).gte(this.cost)&&(hasMilestone("i",5))) },
|
||||||
buy() {
|
buy() {
|
||||||
if (!hasUpgrade(this.layer,233))setBuyableAmount(this.layer,21, getBuyableAmount(this.layer,21).sub(this.cost()))
|
if (!hasUpgrade(this.layer,233))setBuyableAmount(this.layer,21, getBuyableAmount(this.layer,21).sub(this.cost))
|
||||||
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
||||||
},
|
},
|
||||||
unlocked(){return (hasMilestone("i",5))}
|
unlocked(){return (hasMilestone("i",5))}
|
||||||
},
|
},
|
||||||
23: {
|
23: {
|
||||||
cost() { return new Decimal(124).plus(getBuyableAmount(this.layer,this.id).times(2).pow(2))},
|
cost() { return new Decimal(124).plus(getBuyableAmount(this.layer,this.id).times(2).pow(2))},
|
||||||
display() { return "Gain a booster. Cost: "+format(this.cost())+" Pointy Points" },
|
display() { return "Gain a booster. Cost: "+format(this.cost)+" Pointy Points" },
|
||||||
canAfford() { return (getBuyableAmount(this.layer,21).gte(this.cost())&&(hasMilestone("i",5))) },
|
canAfford() { return (getBuyableAmount(this.layer,21).gte(this.cost)&&(hasMilestone("i",5))) },
|
||||||
buy() {
|
buy() {
|
||||||
if (!hasMilestone(this.layer,15))setBuyableAmount(this.layer,21, getBuyableAmount(this.layer,21).sub(this.cost()))
|
if (!hasMilestone(this.layer,15))setBuyableAmount(this.layer,21, getBuyableAmount(this.layer,21).sub(this.cost))
|
||||||
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
||||||
if (!hasMilestone(this.layer,15)){
|
if (!hasMilestone(this.layer,15)){
|
||||||
if (!hasMilestone(this.layer,12)){player.p.upgrades=player.p.upgrades.filter((x)=>{return (x<200||x>230)})
|
if (!hasMilestone(this.layer,12)){player.p.upgrades=player.p.upgrades.filter((x)=>{return (x<200||x>230)})
|
||||||
|
@ -665,43 +666,43 @@ challenges:{
|
||||||
},
|
},
|
||||||
31: {
|
31: {
|
||||||
cost() { return new Decimal(1e93).times(new Decimal(1.5).pow(getBuyableAmount(this.layer,this.id))).times(new Decimal(1.1).pow(getBuyableAmount(this.layer,this.id).pow(2)))},
|
cost() { return new Decimal(1e93).times(new Decimal(1.5).pow(getBuyableAmount(this.layer,this.id))).times(new Decimal(1.1).pow(getBuyableAmount(this.layer,this.id).pow(2)))},
|
||||||
effect(){return new Decimal(2).plus(layers.p.buyables[33].effect()).pow(getBuyableAmount(this.layer,this.id).plus(layers.p.buyables[51].effect()))},
|
effect(){return new Decimal(2).plus(layers.p.buyables[33].effect).pow(getBuyableAmount(this.layer,this.id).plus(layers.p.buyables[51].effect))},
|
||||||
display() { return "Double point gain. \nCurrently: x"+format(this.effect())+"\nCost: "+format(this.cost())+" Prestige points" },
|
display() { return "Double point gain. \nCurrently: x"+format(this.effect)+"\nCost: "+format(this.cost)+" Prestige points" },
|
||||||
canAfford() { return (player.p.points.gte(this.cost())&&(hasMilestone("p",13))) },
|
canAfford() { return (player.p.points.gte(this.cost)&&(hasMilestone("p",13))) },
|
||||||
buy() {
|
buy() {
|
||||||
player.p.points=player.p.points.sub(this.cost())
|
player.p.points=player.p.points.sub(this.cost)
|
||||||
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
||||||
},
|
},
|
||||||
unlocked(){return (hasMilestone("p",13))}
|
unlocked(){return (hasMilestone("p",13))}
|
||||||
},
|
},
|
||||||
32: {
|
32: {
|
||||||
cost() { return new Decimal(1e95).times(new Decimal(2).pow(getBuyableAmount(this.layer,this.id))).times(new Decimal(1.01).pow(getBuyableAmount(this.layer,this.id).pow(2)))},
|
cost() { return new Decimal(1e95).times(new Decimal(2).pow(getBuyableAmount(this.layer,this.id))).times(new Decimal(1.01).pow(getBuyableAmount(this.layer,this.id).pow(2)))},
|
||||||
display() { return "Double prestige point gain. \nCurrently: x"+format(new Decimal(2).plus(layers.p.buyables[33].effect()).pow(getBuyableAmount(this.layer,this.id)))+"\nCost: "+format(this.cost())+" Prestige points" },
|
display() { return "Double prestige point gain. \nCurrently: x"+format(new Decimal(2).plus(layers.p.buyables[33].effect).pow(getBuyableAmount(this.layer,this.id)))+"\nCost: "+format(this.cost)+" Prestige points" },
|
||||||
canAfford() { return (player.p.points.gte(this.cost())&&(hasMilestone("p",13))) },
|
canAfford() { return (player.p.points.gte(this.cost)&&(hasMilestone("p",13))) },
|
||||||
buy() {
|
buy() {
|
||||||
player.p.points=player.p.points.sub(this.cost())
|
player.p.points=player.p.points.sub(this.cost)
|
||||||
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
||||||
},
|
},
|
||||||
unlocked(){return (hasMilestone("p",13)&&getBuyableAmount(this.layer,31).gte(5))}
|
unlocked(){return (hasMilestone("p",13)&&getBuyableAmount(this.layer,31).gte(5))}
|
||||||
},
|
},
|
||||||
33: {
|
33: {
|
||||||
cost() { return new Decimal(1e100).times(new Decimal(10).pow(getBuyableAmount(this.layer,this.id))).times(new Decimal(1.01).pow(getBuyableAmount(this.layer,this.id).pow(2)))},
|
cost() { return new Decimal(1e100).times(new Decimal(10).pow(getBuyableAmount(this.layer,this.id))).times(new Decimal(1.01).pow(getBuyableAmount(this.layer,this.id).pow(2)))},
|
||||||
effect(){return new Decimal(0.01).mul(getBuyableAmount(this.layer,this.id)).times(layers.p.buyables[43].effect())},
|
effect(){return new Decimal(0.01).mul(getBuyableAmount(this.layer,this.id)).times(layers.p.buyables[43].effect)},
|
||||||
display() { return "Add 0.01 to the previous 2 buyable bases. \nCurrently: +"+format(this.effect())+"\nCost: "+format(this.cost())+" Prestige points" },
|
display() { return "Add 0.01 to the previous 2 buyable bases. \nCurrently: +"+format(this.effect)+"\nCost: "+format(this.cost)+" Prestige points" },
|
||||||
canAfford() { return (player.p.points.gte(this.cost())&&(hasMilestone("p",13))) },
|
canAfford() { return (player.p.points.gte(this.cost)&&(hasMilestone("p",13))) },
|
||||||
buy() {
|
buy() {
|
||||||
player.p.points=player.p.points.sub(this.cost())
|
player.p.points=player.p.points.sub(this.cost)
|
||||||
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
||||||
},
|
},
|
||||||
unlocked(){return (hasMilestone("p",13)&&(getBuyableAmount(this.layer,this.id).gt(0)||player.p.points.gte(1e100)))}
|
unlocked(){return (hasMilestone("p",13)&&(getBuyableAmount(this.layer,this.id).gt(0)||player.p.points.gte(1e100)))}
|
||||||
},
|
},
|
||||||
41: {
|
41: {
|
||||||
cost() { return new Decimal(1e110).times(new Decimal(10).pow(getBuyableAmount(this.layer,this.id))).times(new Decimal(10).pow(getBuyableAmount(this.layer,this.id).pow(2)))},
|
cost() { return new Decimal(1e110).times(new Decimal(10).pow(getBuyableAmount(this.layer,this.id))).times(new Decimal(10).pow(getBuyableAmount(this.layer,this.id).pow(2)))},
|
||||||
effect(){return new Decimal(0.01).mul(getBuyableAmount(this.layer,this.id).plus(layers.p.buyables[51].effect()))},
|
effect(){return new Decimal(0.01).mul(getBuyableAmount(this.layer,this.id).plus(layers.p.buyables[51].effect))},
|
||||||
display() { return "Add 0.01 to the booster effect base. \nCurrently: +"+format(this.effect())+"\nCost: "+format(this.cost())+" Prestige points" },
|
display() { return "Add 0.01 to the booster effect base. \nCurrently: +"+format(this.effect)+"\nCost: "+format(this.cost)+" Prestige points" },
|
||||||
canAfford() { return (player.p.points.gte(this.cost())&&(hasMilestone("p",13))) },
|
canAfford() { return (player.p.points.gte(this.cost)&&(hasMilestone("p",13))) },
|
||||||
buy() {
|
buy() {
|
||||||
player.p.points=player.p.points.sub(this.cost())
|
player.p.points=player.p.points.sub(this.cost)
|
||||||
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
||||||
},
|
},
|
||||||
unlocked(){return (hasMilestone("p",13)&&(getBuyableAmount(this.layer,this.id).gt(0)||player.p.points.gte(1e110)))}
|
unlocked(){return (hasMilestone("p",13)&&(getBuyableAmount(this.layer,this.id).gt(0)||player.p.points.gte(1e110)))}
|
||||||
|
@ -718,10 +719,10 @@ challenges:{
|
||||||
if (f.gte(3))f=new Decimal(3)
|
if (f.gte(3))f=new Decimal(3)
|
||||||
return f
|
return f
|
||||||
},
|
},
|
||||||
display() { return "Raise point gain to the 1.001 \nCurrently: ^"+format(this.effect())+(this.effect().eq(3)?"(hardcapped)":"")+"\nCost: "+format(this.cost())+" Prestige points" },
|
display() { return "Raise point gain to the 1.001 \nCurrently: ^"+format(this.effect)+(this.effect.eq(3)?"(hardcapped)":"")+"\nCost: "+format(this.cost)+" Prestige points" },
|
||||||
canAfford() { return (player.p.points.gte(this.cost())&&(hasMilestone("p",13)))&&this.effect().lt(3) },
|
canAfford() { return (player.p.points.gte(this.cost)&&(hasMilestone("p",13)))&&this.effect.lt(3) },
|
||||||
buy() {
|
buy() {
|
||||||
player.p.points=player.p.points.sub(this.cost())
|
player.p.points=player.p.points.sub(this.cost)
|
||||||
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
||||||
},
|
},
|
||||||
unlocked(){return (hasMilestone("p",13)&&(getBuyableAmount(this.layer,this.id).gt(0)||player.p.points.gte(1e270)))}
|
unlocked(){return (hasMilestone("p",13)&&(getBuyableAmount(this.layer,this.id).gt(0)||player.p.points.gte(1e270)))}
|
||||||
|
@ -729,10 +730,10 @@ challenges:{
|
||||||
43: {
|
43: {
|
||||||
cost() { return new Decimal("1e375").times(new Decimal(10).pow(getBuyableAmount(this.layer,this.id))).times(new Decimal(10).pow(getBuyableAmount(this.layer,this.id).pow(2)))},
|
cost() { return new Decimal("1e375").times(new Decimal(10).pow(getBuyableAmount(this.layer,this.id))).times(new Decimal(10).pow(getBuyableAmount(this.layer,this.id).pow(2)))},
|
||||||
effect(){return new Decimal(0.01).mul(getBuyableAmount(this.layer,this.id)).plus(1)},
|
effect(){return new Decimal(0.01).mul(getBuyableAmount(this.layer,this.id)).plus(1)},
|
||||||
display() { return "Multiply the above buyable effect. \nCurrently: *"+format(this.effect())+"\nCost: "+format(this.cost())+" Prestige points" },
|
display() { return "Multiply the above buyable effect. \nCurrently: *"+format(this.effect)+"\nCost: "+format(this.cost)+" Prestige points" },
|
||||||
canAfford() { return (player.p.points.gte(this.cost())&&(hasMilestone("p",13))) },
|
canAfford() { return (player.p.points.gte(this.cost)&&(hasMilestone("p",13))) },
|
||||||
buy() {
|
buy() {
|
||||||
player.p.points=player.p.points.sub(this.cost())
|
player.p.points=player.p.points.sub(this.cost)
|
||||||
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
||||||
},
|
},
|
||||||
unlocked(){return (hasMilestone("p",13)&&(getBuyableAmount(this.layer,this.id).gt(0)||player.p.points.gte("1e375")))}
|
unlocked(){return (hasMilestone("p",13)&&(getBuyableAmount(this.layer,this.id).gt(0)||player.p.points.gte("1e375")))}
|
||||||
|
@ -740,10 +741,10 @@ challenges:{
|
||||||
51: {
|
51: {
|
||||||
cost() { return new Decimal("1e1740").times(new Decimal(10).pow(getBuyableAmount(this.layer,this.id))).times(new Decimal(1e10).pow(getBuyableAmount(this.layer,this.id).pow(2)))},
|
cost() { return new Decimal("1e1740").times(new Decimal(10).pow(getBuyableAmount(this.layer,this.id))).times(new Decimal(1e10).pow(getBuyableAmount(this.layer,this.id).pow(2)))},
|
||||||
effect(){return getBuyableAmount(this.layer,this.id).pow(0.55)},
|
effect(){return getBuyableAmount(this.layer,this.id).pow(0.55)},
|
||||||
display() { return "Add free levels to the above 2 buyables \nCurrently: "+format(this.effect())+"\nCost: "+format(this.cost())+" Prestige points" },
|
display() { return "Add free levels to the above 2 buyables \nCurrently: "+format(this.effect)+"\nCost: "+format(this.cost)+" Prestige points" },
|
||||||
canAfford() { return (player.p.points.gte(this.cost())&&(hasMilestone("p",13))) },
|
canAfford() { return (player.p.points.gte(this.cost)&&(hasMilestone("p",13))) },
|
||||||
buy() {
|
buy() {
|
||||||
player.p.points=player.p.points.sub(this.cost())
|
player.p.points=player.p.points.sub(this.cost)
|
||||||
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
setBuyableAmount(this.layer, this.id, getBuyableAmount(this.layer, this.id).add(1))
|
||||||
},
|
},
|
||||||
unlocked(){return (hasMilestone("p",15)&&(getBuyableAmount(this.layer,this.id).gt(0)||player.p.points.gte("1e1700")))}
|
unlocked(){return (hasMilestone("p",15)&&(getBuyableAmount(this.layer,this.id).gt(0)||player.p.points.gte("1e1700")))}
|
||||||
|
@ -751,86 +752,86 @@ challenges:{
|
||||||
},
|
},
|
||||||
milestones: {
|
milestones: {
|
||||||
0: {
|
0: {
|
||||||
requirementDescription: "1 reset",
|
requirementDisplay: "1 reset",
|
||||||
effectDescription: "Add 0.01 to base point gain and prestige requirement, and <b>1</b> doesn't reset upgrades",
|
effectDisplay: "Add 0.01 to base point gain and prestige requirement, and <b>1</b> doesn't reset upgrades",
|
||||||
done() { return getBuyableAmount("p",11).gte(1) },
|
done() { return getBuyableAmount("p",11).gte(1) },
|
||||||
unlocked(){return layers.p.activeSubtab!="Pointy points"}
|
unlocked(){return layers.p.activeSubtab!="Pointy points"}
|
||||||
},
|
},
|
||||||
1: {
|
1: {
|
||||||
requirementDescription: "2 resets",
|
requirementDisplay: "2 resets",
|
||||||
effectDescription: "<b>2</b> and <b>3</b> don't reset upgrades, and start with the first 8 upgrades on reset",
|
effectDisplay: "<div><b>2</b> and <b>3</b> don't reset upgrades, and start with the first 8 upgrades on reset</div>",
|
||||||
done() { return getBuyableAmount("p",11).gte(2) },
|
done() { return getBuyableAmount("p",11).gte(2) },
|
||||||
unlocked(){return hasMilestone(this.layer,this.id-1)&&layers.p.activeSubtab!="Pointy points"}
|
unlocked(){return hasMilestone(this.layer,this.id-1)&&layers.p.activeSubtab!="Pointy points"}
|
||||||
},
|
},
|
||||||
2: {
|
2: {
|
||||||
requirementDescription: "3 resets",
|
requirementDisplay: "3 resets",
|
||||||
effectDescription: "<b>4</b> doesn't reset upgrades, and permanently fix the bug where you can't buy upgrades when you have 1 prestige point",
|
effectDisplay: "<div><b>4</b> doesn't reset upgrades, and permanently fix the bug where you can't buy upgrades when you have 1 prestige point</div>",
|
||||||
done() { return getBuyableAmount("p",11).gte(3) },
|
done() { return getBuyableAmount("p",11).gte(3) },
|
||||||
unlocked(){return hasMilestone(this.layer,this.id-1)&&layers.p.activeSubtab!="Pointy points"}
|
unlocked(){return hasMilestone(this.layer,this.id-1)&&layers.p.activeSubtab!="Pointy points"}
|
||||||
},
|
},
|
||||||
3: {
|
3: {
|
||||||
requirementDescription: "4 resets",
|
requirementDisplay: "4 resets",
|
||||||
effectDescription: "Don't reset challenges, add 1 to <b>Point</b> maximum completions, and start with 24 upgrades",
|
effectDisplay: "Don't reset challenges, add 1 to <b>Point</b> maximum completions, and start with 24 upgrades",
|
||||||
done() { return getBuyableAmount("p",11).gte(4) },
|
done() { return getBuyableAmount("p",11).gte(4) },
|
||||||
unlocked(){return hasMilestone(this.layer,this.id-1)&&layers.p.activeSubtab!="Pointy points"}
|
unlocked(){return hasMilestone(this.layer,this.id-1)&&layers.p.activeSubtab!="Pointy points"}
|
||||||
},
|
},
|
||||||
4: {
|
4: {
|
||||||
requirementDescription: "5 resets",
|
requirementDisplay: "5 resets",
|
||||||
effectDescription: "Each useless upgrade adds 0.1 to base point gain",
|
effectDisplay: "Each useless upgrade adds 0.1 to base point gain",
|
||||||
done() { return getBuyableAmount("p",11).gte(5) },
|
done() { return getBuyableAmount("p",11).gte(5) },
|
||||||
unlocked(){return hasMilestone(this.layer,this.id-1)&&layers.p.activeSubtab!="Pointy points"}
|
unlocked(){return hasMilestone(this.layer,this.id-1)&&layers.p.activeSubtab!="Pointy points"}
|
||||||
},
|
},
|
||||||
5: {
|
5: {
|
||||||
requirementDescription: "6 resets",
|
requirementDisplay: "6 resets",
|
||||||
effectDescription: "Unlock something",
|
effectDisplay: "Unlock something",
|
||||||
done() { return getBuyableAmount("p",11).gte(6) },
|
done() { return getBuyableAmount("p",11).gte(6) },
|
||||||
unlocked(){return hasMilestone(this.layer,this.id-1)&&layers.p.activeSubtab!="Pointy points"}
|
unlocked(){return hasMilestone(this.layer,this.id-1)&&layers.p.activeSubtab!="Pointy points"}
|
||||||
},
|
},
|
||||||
6: {
|
6: {
|
||||||
requirementDescription: "1 pointy point",
|
requirementDisplay: "1 pointy point",
|
||||||
effectDescription: "Unlock the upgrade tree",
|
effectDisplay: "Unlock the upgrade tree",
|
||||||
done() { return getBuyableAmount("p",21).gte(1) },
|
done() { return getBuyableAmount("p",21).gte(1) },
|
||||||
unlocked(){return hasMilestone(this.layer,this.id-1)&&(hasUpgrade(this.layer,104)||player.i.unlocked)&&layers.p.activeSubtab!="Pointy points"}
|
unlocked(){return hasMilestone(this.layer,this.id-1)&&(hasUpgrade(this.layer,104)||player.i.unlocked)&&layers.p.activeSubtab!="Pointy points"}
|
||||||
},
|
},
|
||||||
7: {
|
7: {
|
||||||
requirementDescription: "7 pointy points",
|
requirementDisplay: "7 pointy points",
|
||||||
effectDescription: "You can now buy both first and second row upgrade tree upgrades",
|
effectDisplay: "You can now buy both first and second row upgrade tree upgrades",
|
||||||
done() { return getBuyableAmount("p",21).gte(7) },
|
done() { return getBuyableAmount("p",21).gte(7) },
|
||||||
unlocked(){return hasMilestone(this.layer,this.id-1)&&(hasUpgrade(this.layer,111)||player.i.unlocked)&&layers.p.activeSubtab!="Pointy points"}
|
unlocked(){return hasMilestone(this.layer,this.id-1)&&(hasUpgrade(this.layer,111)||player.i.unlocked)&&layers.p.activeSubtab!="Pointy points"}
|
||||||
},
|
},
|
||||||
8: {
|
8: {
|
||||||
requirementDescription: "8 pointy points",
|
requirementDisplay: "8 pointy points",
|
||||||
effectDescription: "Unlock another layer",
|
effectDisplay: "Unlock another layer",
|
||||||
done() { return getBuyableAmount("p",21).gte(8) },
|
done() { return getBuyableAmount("p",21).gte(8) },
|
||||||
unlocked(){return hasMilestone(this.layer,this.id-1)&&(hasUpgrade(this.layer,141)||hasUpgrade(this.layer,143)||hasUpgrade(this.layer,142)||player.i.unlocked)&&layers.p.activeSubtab!="Pointy points"}
|
unlocked(){return hasMilestone(this.layer,this.id-1)&&(hasUpgrade(this.layer,141)||hasUpgrade(this.layer,143)||hasUpgrade(this.layer,142)||player.i.unlocked)&&layers.p.activeSubtab!="Pointy points"}
|
||||||
},
|
},
|
||||||
11: {
|
11: {
|
||||||
requirementDescription: "3 boosters",
|
requirementDisplay: "3 boosters",
|
||||||
effectDescription: "Keep automation on booster reset",
|
effectDisplay: "Keep automation on booster reset",
|
||||||
done() { return getBuyableAmount("p",23).gte(3) },
|
done() { return getBuyableAmount("p",23).gte(3) },
|
||||||
unlocked(){return (getBuyableAmount("p",23).gt(0)||hasMilestone(this.layer,this.id))}
|
unlocked(){return (getBuyableAmount("p",23).gt(0)||hasMilestone(this.layer,this.id))}
|
||||||
},
|
},
|
||||||
12: {
|
12: {
|
||||||
requirementDescription: "5 boosters",
|
requirementDisplay: "5 boosters",
|
||||||
effectDescription: "Keep all prestige upgrades on booster reset and buy max infinity points",
|
effectDisplay: "Keep all prestige upgrades on booster reset and buy max infinity points",
|
||||||
done() { return getBuyableAmount("p",23).gte(5) },
|
done() { return getBuyableAmount("p",23).gte(5) },
|
||||||
unlocked(){return (getBuyableAmount("p",23).gt(0)||hasMilestone(this.layer,this.id))}
|
unlocked(){return (getBuyableAmount("p",23).gt(0)||hasMilestone(this.layer,this.id))}
|
||||||
},
|
},
|
||||||
13: {
|
13: {
|
||||||
requirementDescription: "10 boosters",
|
requirementDisplay: "10 boosters",
|
||||||
effectDescription: "Generators cost nothing",
|
effectDisplay: "Generators cost nothing",
|
||||||
done() { return getBuyableAmount("p",23).gte(10) },
|
done() { return getBuyableAmount("p",23).gte(10) },
|
||||||
unlocked(){return (getBuyableAmount("p",23).gt(0)||hasMilestone(this.layer,this.id))}
|
unlocked(){return (getBuyableAmount("p",23).gt(0)||hasMilestone(this.layer,this.id))}
|
||||||
},
|
},
|
||||||
14: {
|
14: {
|
||||||
requirementDescription: "15 boosters",
|
requirementDisplay: "15 boosters",
|
||||||
effectDescription: "Auto buy the first 3 buyables and buy max pointy prestige points",
|
effectDisplay: "Auto buy the first 3 buyables and buy max pointy prestige points",
|
||||||
done() { return getBuyableAmount("p",23).gte(15) },
|
done() { return getBuyableAmount("p",23).gte(15) },
|
||||||
unlocked(){return (getBuyableAmount("p",41).gt(0)||hasMilestone(this.layer,this.id))}
|
unlocked(){return (getBuyableAmount("p",41).gt(0)||hasMilestone(this.layer,this.id))}
|
||||||
},
|
},
|
||||||
15: {
|
15: {
|
||||||
requirementDescription: "20 boosters",
|
requirementDisplay: "20 boosters",
|
||||||
effectDescription: "Boosters reset nothing and auto booster",
|
effectDisplay: "Boosters reset nothing and auto booster",
|
||||||
done() { return getBuyableAmount("p",23).gte(16) },
|
done() { return getBuyableAmount("p",23).gte(16) },
|
||||||
unlocked(){return (getBuyableAmount("p",41).gt(0)||hasMilestone(this.layer,this.id))}
|
unlocked(){return (getBuyableAmount("p",41).gt(0)||hasMilestone(this.layer,this.id))}
|
||||||
},
|
},
|
||||||
|
@ -856,7 +857,7 @@ challenges:{
|
||||||
if (hasUpgrade("p",94)) geff=geff.times(player.p.cmult)
|
if (hasUpgrade("p",94)) geff=geff.times(player.p.cmult)
|
||||||
if (hasUpgrade("p",104)) geff=geff.times(new Decimal(player.p.buyables[21]).plus(1))
|
if (hasUpgrade("p",104)) geff=geff.times(new Decimal(player.p.buyables[21]).plus(1))
|
||||||
if (hasUpgrade("p",143)) geff=geff.times(new Decimal(player.timePlayed).div(3600).max(1))
|
if (hasUpgrade("p",143)) geff=geff.times(new Decimal(player.timePlayed).div(3600).max(1))
|
||||||
if (hasUpgrade("p",225)) geff=geff.pow(new Decimal(player.p.buyables[23]).div(10).mul(new Decimal(0.1).plus(layers.p.buyables[41].effect()).times(10)).plus(1))
|
if (hasUpgrade("p",225)) geff=geff.pow(new Decimal(player.p.buyables[23]).div(10).mul(new Decimal(0.1).plus(layers.p.buyables[41].effect).times(10)).plus(1))
|
||||||
player.p.geff=geff
|
player.p.geff=geff
|
||||||
if (hasChallenge("p",22)&&(!hasUpgrade("p",141)||hasUpgrade("i",12)))player.p.cmult=player.p.cmult.plus(hasUpgrade("p",141)?1:0.01)
|
if (hasChallenge("p",22)&&(!hasUpgrade("p",141)||hasUpgrade("i",12)))player.p.cmult=player.p.cmult.plus(hasUpgrade("p",141)?1:0.01)
|
||||||
if (!hasUpgrade("p",111)) player.p.cmult=player.p.cmult.min(100)
|
if (!hasUpgrade("p",111)) player.p.cmult=player.p.cmult.min(100)
|
||||||
|
@ -869,99 +870,78 @@ challenges:{
|
||||||
if (layers.p.buyables[23].canAfford())layers.p.buyables[23].buy()
|
if (layers.p.buyables[23].canAfford())layers.p.buyables[23].buy()
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
tabFormat: {
|
subtabs: {
|
||||||
Upgrades: {
|
"Upgrades": {
|
||||||
content:[
|
display: `<div v-frag>
|
||||||
"main-display",
|
<main-display />
|
||||||
"blank",
|
<spacer />
|
||||||
["prestige-button", function(){}],
|
<prestige-button display="" />
|
||||||
"blank",
|
<spacer />
|
||||||
"blank",
|
<spacer />
|
||||||
"upgrades"
|
<upgrades />
|
||||||
]
|
</div>`
|
||||||
},
|
},
|
||||||
Challenges: {
|
"Challenges": {
|
||||||
unlocked(){return hasUpgrade("p",51)||hasMilestone("p",0)},
|
unlocked() { return hasUpgrade("p", 51) || hasMilestone("p", 0); },
|
||||||
content:[
|
display: `<div v-frag>
|
||||||
"blank",
|
<spacer />
|
||||||
"blank",
|
<spacer />
|
||||||
"challenges"
|
<challenges />
|
||||||
],
|
</div>`
|
||||||
},
|
},
|
||||||
"Buyables and Milestones": {
|
"Buyables and Milestones": {
|
||||||
unlocked(){return hasUpgrade("p",74)||hasMilestone("p",0)},
|
unlocked(){return hasUpgrade("p",74)||hasMilestone("p",0)},
|
||||||
content:[
|
display: `<div v-frag>
|
||||||
"blank",
|
<spacer />
|
||||||
"blank",
|
<spacer />
|
||||||
["buyable",11],
|
<row><buyable id="11" /></row>
|
||||||
"blank",
|
<spacer />
|
||||||
["display-text", function(){
|
<div v-if="hasMilestone('p', 0)">Your boosts are making the point challenge {{ getBuyableAmount('p', 11).plus(1) }}x less pointy</div>
|
||||||
if (!hasMilestone("p",0))return ""
|
<spacer />
|
||||||
return "Your boosts are making the point challenge "+getBuyableAmount("p",11).plus(1)+"x less pointy"}],
|
<milestones />
|
||||||
"blank",
|
</div>`
|
||||||
"milestones"
|
|
||||||
],
|
|
||||||
},
|
},
|
||||||
"Generators": {
|
"Generators": {
|
||||||
unlocked(){return hasMilestone("p",5)||player.i.points.gte(1)},
|
unlocked(){return hasMilestone("p",5)||player.i.points.gte(1)},
|
||||||
content:[
|
display: `<div v-frag>
|
||||||
"blank",
|
<spacer />
|
||||||
["display-text", function(){return "You have "+format(player.p.gp)+" generator points, adding "+format(hasUpgrade("p",132)?player.p.gp.plus(1).pow(new Decimal(1).div(2)):hasUpgrade("p",101)?player.p.gp.plus(1).pow(new Decimal(1).div(3)):hasUpgrade("p",93)?player.p.gp.plus(1).pow(0.2):player.p.gp.plus(1).log10())+" to point gain."}],
|
<div>You have {{ format(player.p.gp) }} generator points, adding {{ format(hasUpgrade("p",132)?player.p.gp.plus(1).pow(new Decimal(1).div(2)):hasUpgrade("p",101)?player.p.gp.plus(1).pow(new Decimal(1).div(3)):hasUpgrade("p",93)?player.p.gp.plus(1).pow(0.2):player.p.gp.plus(1).log10()) }} to point gain</div>
|
||||||
["display-text", function(){return "You have "+format(player.p.g)+" generators, generating "+format(player.p.g.times(player.p.geff))+" generator points per second"}],
|
<div>You have {{ format(player.p.g) }} generators, generating {{ format(player.p.g.times(player.p.geff)) }} generator points per second</div>
|
||||||
["display-text", function(){
|
<div>Generator efficiency is {{ format(player.p.geff) }}</div>
|
||||||
return "Generator efficiency is "+format(player.p.geff)
|
<spacer />
|
||||||
}],
|
<spacer />
|
||||||
"blank",
|
<buyables :buyables="[12, 13, 14]" />
|
||||||
"blank",
|
<row><clickable id="11" /></row>
|
||||||
["column", [["row", [["buyable",12],["buyable",13],["buyable",14]]]]],
|
</div>`
|
||||||
["clickable",11]
|
|
||||||
]
|
|
||||||
},
|
},
|
||||||
"Pointy points":{
|
"Pointy Points": {
|
||||||
unlocked(){return hasUpgrade("p",104)||player.i.points.gte(1)},
|
unlocked(){return hasUpgrade("p",104)||player.i.points.gte(1)},
|
||||||
content:[
|
display: `<div v-frag>
|
||||||
["display-text",
|
<div style="color: red; font-size: 32px; font-family: Comic Sans MS">{{ format(player.p.buyables[21]) }} pointy points</div>
|
||||||
function() { return 'I have ' + format(player.p.buyables[21]) + ' pointy points!' },
|
<div style="color: red; font-size: 32px; font-family: Comic Sans MS">My pointy points are multiplying generator efficiency by {{ format(new Decimal(player.p.buyables[21]).plus(1)) }}</div>
|
||||||
{ "color": "red", "font-size": "32px", "font-family": "Comic Sans MS" }],
|
<spacer />
|
||||||
["display-text",
|
<spacer />
|
||||||
function() { return 'My pointy points are multiplying generator efficiency by '+format(new Decimal(player.p.buyables[21]).plus(1)) },
|
<row><buyable id="21" /></row>
|
||||||
{ "color": "red", "font-size": "32px", "font-family": "Comic Sans MS" }],
|
<div v-if="hasMilestone('i', 5)" style="color: red; font-size: 32px; font-family: Comic Sans MS">I have {{ format(player.p.buyables[22]) }} pointy prestige points</div>
|
||||||
"blank","blank",
|
<row><buyable id="22" /></row>
|
||||||
["buyable",21],
|
<spacer />
|
||||||
["display-text",
|
<upgrades :upgrades="[211, 212, 213, 214, 215]" />
|
||||||
function() {
|
<upgrades :upgrades="[221, 222, 223, 224, 225]" />
|
||||||
if (!hasMilestone("i",5))return ""
|
<div v-if="hasMilestone('p', 225)" style="color: red; font-size: 32px; font-family: Comic Sans MS">I have {{ format(player.p.buyables[23]) }} pointy boosters!</div>
|
||||||
return 'I have ' + format(player.p.buyables[22]) + ' pointy prestige points!' },
|
<row><buyable id="23" /></row>
|
||||||
{ "color": "red", "font-size": "32px", "font-family": "Comic Sans MS" }],
|
<div v-if="hasMilestone('p', 225) || getBuyableAmount('p', 23).gt(0)" style="color: red; font-size: 32px; font-family: Comic Sans MS">My pointy boosters are raising generator efficiency to the ^{{ format(new Decimal(player.p.buyables[23]).div(10).mul(new Decimal(0.1).plus(layers.p.buyables[41].effect).times(10)).plus(1)) }}</div>
|
||||||
["buyable",22],
|
<spacer />
|
||||||
"blank",
|
<spacer />
|
||||||
["column", [["row", [["upgrade",211],["upgrade",212],["upgrade",213],["upgrade",214],["upgrade",215]]]]],
|
<div v-if="hasMilestone('p', 11)" style="font-size: 24px">Booster upgrades</div>
|
||||||
["column", [["row", [["upgrade",221],["upgrade",222],["upgrade",223],["upgrade",224],["upgrade",225]]]]],
|
<upgrades :upgrades="[231, 232, 233, 234, 235]" />
|
||||||
["display-text",
|
</div>`
|
||||||
function() {
|
|
||||||
if (!hasUpgrade("p",225)&&getBuyableAmount("p",23).eq(0))return ""
|
|
||||||
return 'I have ' + format(player.p.buyables[23]) + ' pointy boosters!' },
|
|
||||||
{ "color": "red", "font-size": "32px", "font-family": "Comic Sans MS" }],
|
|
||||||
["buyable",23],
|
|
||||||
["display-text",
|
|
||||||
function() {if (!hasUpgrade("p",225)&&getBuyableAmount("p",23).eq(0))return ""
|
|
||||||
return 'My pointy boosters are raising generator efficiency to the ^'+format(new Decimal(player.p.buyables[23]).div(10).mul(new Decimal(0.1).plus(layers.p.buyables[41].effect()).times(10)).plus(1)) },
|
|
||||||
{ "color": "red", "font-size": "32px", "font-family": "Comic Sans MS" }],
|
|
||||||
"blank","blank",
|
|
||||||
["display-text",
|
|
||||||
function() {if (!hasMilestone("p",11))return ""
|
|
||||||
return 'Booster upgrades' },
|
|
||||||
{"font-size": "24px"}],
|
|
||||||
["column", [["row", [["upgrade",231],["upgrade",232],["upgrade",233],["upgrade",234],["upgrade",235]]]]],
|
|
||||||
]
|
|
||||||
},
|
},
|
||||||
"Buyables": {
|
"Buyables": {
|
||||||
unlocked(){return hasMilestone("p",13)},
|
unlocked(){return hasMilestone("p",13)},
|
||||||
content:["main-display",
|
display: `<div v-frag>
|
||||||
["column", [["row", [["buyable",31],["buyable",32],["buyable",33]]]]],
|
<buyables :buyables="[31, 32, 33]" />
|
||||||
["column", [["row", [["buyable",41],["buyable",42],["buyable",43]]]]],
|
<buyables :buyables="[41, 42, 43]" />
|
||||||
//["column", [["row", [["buyable",51],["buyable",52],["buyable",53]]]]],
|
</div>`
|
||||||
]
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -1,4 +1,4 @@
|
||||||
import { hasUpgrade, upgradeEffect } from '../util/features';
|
import { hasUpgrade, upgradeEffect, hasMilestone, inChallenge, getBuyableAmount } from '../util/features';
|
||||||
import { layers } from '../store/layers';
|
import { layers } from '../store/layers';
|
||||||
import { player } from '../store/proxies';
|
import { player } from '../store/proxies';
|
||||||
import Decimal from '../util/bignum';
|
import Decimal from '../util/bignum';
|
||||||
|
@ -8,6 +8,8 @@ import modInfo from './modInfo';
|
||||||
import f from './layers/aca/f.js';
|
import f from './layers/aca/f.js';
|
||||||
import c from './layers/aca/c.js';
|
import c from './layers/aca/c.js';
|
||||||
import a from './layers/aca/a.js';
|
import a from './layers/aca/a.js';
|
||||||
|
import demoLayer from './layers/demo.js';
|
||||||
|
import demoInfinityLayer from './layers/demo-infinity.js';
|
||||||
const g = {
|
const g = {
|
||||||
id: "g",
|
id: "g",
|
||||||
symbol: "TH",
|
symbol: "TH",
|
||||||
|
@ -54,7 +56,7 @@ const main = {
|
||||||
name: "Tree"
|
name: "Tree"
|
||||||
};
|
};
|
||||||
|
|
||||||
export const getInitialLayers = () => [ main, f, c, a, g, h, spook ];
|
export const getInitialLayers = () => [ main, f, c, a, g, h, spook, demoLayer, demoInfinityLayer ];
|
||||||
|
|
||||||
export function getStartingData() {
|
export function getStartingData() {
|
||||||
return {
|
return {
|
||||||
|
@ -69,8 +71,42 @@ export const getters = {
|
||||||
pointGain() {
|
pointGain() {
|
||||||
if(!hasUpgrade("c", 11))
|
if(!hasUpgrade("c", 11))
|
||||||
return new Decimal(0);
|
return new Decimal(0);
|
||||||
let gain = new Decimal(1)
|
let gain = new Decimal(3.19)
|
||||||
if (hasUpgrade("c", 12)) gain = gain.times(upgradeEffect("c", 12))
|
if (hasUpgrade("c", 12)) gain = gain.times(upgradeEffect("c", 12))
|
||||||
|
if (hasMilestone("p",0))gain=gain.plus(0.01)
|
||||||
|
if (hasMilestone("p",4)){
|
||||||
|
if (hasUpgrade("p",12))gain=gain.plus(0.1)
|
||||||
|
if (hasUpgrade("p",13))gain=gain.plus(0.1)
|
||||||
|
if (hasUpgrade("p",14))gain=gain.plus(0.1)
|
||||||
|
if (hasUpgrade("p",21))gain=gain.plus(0.1)
|
||||||
|
if (hasUpgrade("p",22))gain=gain.plus(0.1)
|
||||||
|
if (hasUpgrade("p",23))gain=gain.plus(0.1)
|
||||||
|
if (hasUpgrade("p",31))gain=gain.plus(0.1)
|
||||||
|
if (hasUpgrade("p",32))gain=gain.plus(0.1)
|
||||||
|
if (hasUpgrade("p",33))gain=gain.plus(0.1)
|
||||||
|
}
|
||||||
|
if (hasUpgrade("p",11))gain=gain.plus(hasUpgrade("p",34)?(new Decimal(1).plus(layers.p.upgrades[34].effect)):1)
|
||||||
|
if (hasUpgrade("p",12))gain=gain.times(hasUpgrade("p",34)?(new Decimal(1).plus(layers.p.upgrades[34].effect)):1)
|
||||||
|
if (hasUpgrade("p",13))gain=gain.pow(hasUpgrade("p",34)?(new Decimal(1).plus(layers.p.upgrades[34].effect)):1)
|
||||||
|
if (hasUpgrade("p",14))gain=gain.tetrate(hasUpgrade("p",34)?(new Decimal(1).plus(layers.p.upgrades[34].effect)):1)
|
||||||
|
|
||||||
|
if (hasUpgrade("p",71)) gain=gain.plus(1.1)
|
||||||
|
if (hasUpgrade("p",72)) gain=gain.times(1.1)
|
||||||
|
if (hasUpgrade("p",73)) gain=gain.pow(1.1)
|
||||||
|
if (hasUpgrade("p",74)) gain=gain.tetrate(1.1)
|
||||||
|
if (hasMilestone("p",5)&&!inChallenge("p",22)){
|
||||||
|
let asdf = (hasUpgrade("p",132)?player.p.gp.plus(1).pow(new Decimal(1).div(2)):hasUpgrade("p",101)?player.p.gp.plus(1).pow(new Decimal(1).div(3)):hasUpgrade("p",93)?player.p.gp.plus(1).pow(0.2):player.p.gp.plus(1).log10())
|
||||||
|
gain=gain.plus(asdf)
|
||||||
|
if (hasUpgrade("p",213))gain=gain.mul(asdf.plus(1))
|
||||||
|
}
|
||||||
|
if (hasUpgrade("p",104)) gain=gain.times(player.p.points.plus(1).pow(0.5))
|
||||||
|
if (hasUpgrade("p",142))gain=gain.times(5)
|
||||||
|
if (player.i.unlocked)gain=gain.times(player.i.points.plus(1).pow(hasUpgrade("p",235)?6.9420:1))
|
||||||
|
if (inChallenge("p",11)||inChallenge("p",21))gain=new Decimal(10).pow(gain.log10().pow(0.75))
|
||||||
|
if (inChallenge("p",12)||inChallenge("p",21))gain=gain.pow(new Decimal(1).sub(new Decimal(1).div(getBuyableAmount("p",11).plus(1))))
|
||||||
|
if (hasUpgrade("p",211))gain=gain.times(getBuyableAmount("p",21).plus(1))
|
||||||
|
if (hasMilestone("p",13))gain=gain.times(layers.p.buyables[31].effect)
|
||||||
|
if (hasMilestone("p",13))gain=gain.pow(layers.p.buyables[42].effect)
|
||||||
return gain;
|
return gain;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
|
@ -190,7 +190,7 @@ export function addLayer(layer, player = null) {
|
||||||
return Decimal.gt(this.completionLimit, 1) && this.maxed;
|
return Decimal.gt(this.completionLimit, 1) && this.maxed;
|
||||||
});
|
});
|
||||||
setDefault(layer.challenges[id], 'canComplete', function() {
|
setDefault(layer.challenges[id], 'canComplete', function() {
|
||||||
if (this.active) {
|
if (!this.active) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
if (this.currencyInternalName) {
|
if (this.currencyInternalName) {
|
||||||
|
@ -232,8 +232,10 @@ export function addLayer(layer, player = null) {
|
||||||
setDefault(layer.buyables[id], 'sellAll', null, false);
|
setDefault(layer.buyables[id], 'sellAll', null, false);
|
||||||
if (layer.buyables[id].cost != undefined) {
|
if (layer.buyables[id].cost != undefined) {
|
||||||
setDefault(layer.buyables[id], 'buy', function() {
|
setDefault(layer.buyables[id], 'buy', function() {
|
||||||
|
if (this.canBuy) {
|
||||||
playerProxy[this.layer].points = playerProxy[this.layer].points.sub(this.cost());
|
playerProxy[this.layer].points = playerProxy[this.layer].points.sub(this.cost());
|
||||||
this.amount = this.amount.add(1);
|
this.amount = this.amount.add(1);
|
||||||
|
}
|
||||||
}, false);
|
}, false);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
import { player } from '../store/proxies';
|
import { player } from '../store/proxies';
|
||||||
import { layers } from '../store/layers';
|
import { layers } from '../store/layers';
|
||||||
|
import { hasUpgrade, hasMilestone, hasAchievement, hasChallenge, maxedChallenge, challengeCompletions, inChallenge, getBuyableAmount, setBuyableAmount, getClickableState, setClickableState, getGridData, setGridData, upgradeEffect, challengeEffect, buyableEffect, clickableEffect, achievementEffect, gridEffect } from './features';
|
||||||
import Decimal, * as numberUtils from './bignum';
|
import Decimal, * as numberUtils from './bignum';
|
||||||
|
|
||||||
let vue;
|
let vue;
|
||||||
|
@ -26,7 +27,7 @@ export function coerceComponent(component, defaultWrapper = 'span') {
|
||||||
component = `<${defaultWrapper}>${component}</${defaultWrapper}>`;
|
component = `<${defaultWrapper}>${component}</${defaultWrapper}>`;
|
||||||
}
|
}
|
||||||
|
|
||||||
return { template: component, computed, data, inject: [ 'tab' ] };
|
return { template: component, computed, data, inject: [ 'tab' ], methods: { hasUpgrade, hasMilestone, hasAchievement, hasChallenge, maxedChallenge, challengeCompletions, inChallenge, getBuyableAmount, setBuyableAmount, getClickableState, setClickableState, getGridData, setGridData, upgradeEffect, challengeEffect, buyableEffect, clickableEffect, achievementEffect, gridEffect } };
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return component;
|
return component;
|
||||||
|
@ -34,8 +35,9 @@ export function coerceComponent(component, defaultWrapper = 'span') {
|
||||||
|
|
||||||
export function getFiltered(objects, filter = null) {
|
export function getFiltered(objects, filter = null) {
|
||||||
if (filter) {
|
if (filter) {
|
||||||
|
filter = filter.map(v => v.toString());
|
||||||
return Object.keys(objects)
|
return Object.keys(objects)
|
||||||
.filter(key => key in filter)
|
.filter(key => filter.includes(key))
|
||||||
.reduce((acc, curr) => {
|
.reduce((acc, curr) => {
|
||||||
acc[curr] = objects[curr];
|
acc[curr] = objects[curr];
|
||||||
return acc;
|
return acc;
|
||||||
|
|
Loading…
Reference in a new issue