Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 25 additions & 8 deletions js/layers.js
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
addLayer("p", {
name: "prestige", // This is optional, only used in a few places, If absent it just uses the layer id.
symbol: "P", // This appears on the layer's node. Default is the id with the first letter capitalized
name: "ZERO", // This is optional, only used in a few places, If absent it just uses the layer id.
symbol: "0P", // This appears on the layer's node. Default is the id with the first letter capitalized
position: 0, // Horizontal position within a row. By default it uses the layer id and sorts in alphabetical order
startData() { return {
unlocked: true,
points: new Decimal(0),
}},
color: "#4BDC13",
requires: new Decimal(10), // Can be a function that takes requirement increases into account
resource: "prestige points", // Name of prestige currency
color: "#0B5725",
requires: new Decimal(16), // Can be a function that takes requirement increases into account
resource: "zero points", // Name of prestige currency
baseResource: "points", // Name of resource prestige is based on
baseAmount() {return player.points}, // Get the current amount of baseResource
type: "normal", // normal: cost to gain currency depends on amount gained. static: cost depends on how much you already have
exponent: 0.5, // Prestige currency exponent
exponent: 0.4, // Prestige currency exponent
gainMult() { // Calculate the multiplier for main currency from bonuses
mult = new Decimal(1)
return mult
Expand All @@ -22,7 +22,24 @@ addLayer("p", {
},
row: 0, // Row the layer is in on the tree (0 is the first row)
hotkeys: [
{key: "p", description: "P: Reset for prestige points", onPress(){if (canReset(this.layer)) doReset(this.layer)}},
{key: "a", description: "A: Reset for zero points", onPress(){if (canReset(this.layer)) doReset(this.layer)}},
],
layerShown(){return true}
upgrades: {
11: {
title: "ex 1",
description: "Square your point gain.",
cost: new Decimal(1),
},
12: {
title: "ex 2",
description: "Cube your point gain.",
cost: new Decimal(5)
},
21: {
title: "boost",
description: "boost your point gain by zero points.",
cost: new Decimal(15)
}
},
})

30 changes: 17 additions & 13 deletions js/mod.js
Original file line number Diff line number Diff line change
@@ -1,26 +1,28 @@
let modInfo = {
name: "The ??? Tree",
id: "mymod",
author: "nobody",
name: "The Number Tree",
id: "JumPsCarE357",
author: "sombody",
pointsName: "points",
modFiles: ["layers.js", "tree.js"],

discordName: "",
discordLink: "",
initialStartPoints: new Decimal (10), // Used for hard resets and new players
offlineLimit: 1, // In hours
initialStartPoints: new Decimal (0), // Used for hard resets and new players
offlineLimit: 0, // In hours
}

// Set your version in num and name
let VERSION = {
num: "0.0",
name: "Literally nothing",
num: "0.0.1.1",
name: "the e apocalypse",
}

let changelog = `<h1>Changelog:</h1><br>
<h3>v0.0</h3><br>
<h3>v0.0.1.1</h3><br>
- Added changelog!
<h3>v0.0.1</h3><br>
- Added things.<br>
- Added stuff.`
- Added everything.`

let winText = `Congratulations! You have reached the end and beaten this game, but for now...`

Expand All @@ -42,7 +44,9 @@ function getPointGen() {
if(!canGenPoints())
return new Decimal(0)

let gain = new Decimal(1)
let gain = new Decimal(2)
if (hasUpgrade('p', 11)) gain = gain.pow(2)
if (hasUpgrade('p', 12)) gain = gain.pow(3)
return gain
}

Expand All @@ -56,7 +60,7 @@ var displayThings = [

// Determines when the game "ends"
function isEndgame() {
return player.points.gte(new Decimal("e280000000"))
return player.points.gte(new Decimal("e100"))
}


Expand All @@ -70,10 +74,10 @@ var backgroundStyle = {

// You can change this if you have things that can be messed up by long tick lengths
function maxTickLength() {
return(3600) // Default is 1 hour which is just arbitrarily large
return(360) // Default is 1 hour which is just arbitrarily large
}

// Use this if you need to undo inflation from an older version. If the version is older than the version that fixed the issue,
// you can cap their current resources with this.
function fixOldSave(oldVersion){
}
}