From 2f588b52153124410a6ffb72687b454ccda1b535 Mon Sep 17 00:00:00 2001 From: Acamaeda Date: Thu, 1 Oct 2020 01:45:05 -0400 Subject: [PATCH] Fixed documentation --- docs/basic-layer-breakdown.md | 4 ++-- docs/buyables.md | 20 ++++++++++---------- docs/challenges.md | 14 +++++++------- docs/custom-tab-layouts.md | 4 ++-- 4 files changed, 21 insertions(+), 21 deletions(-) diff --git a/docs/basic-layer-breakdown.md b/docs/basic-layer-breakdown.md index cd62249..c9ce769 100644 --- a/docs/basic-layer-breakdown.md +++ b/docs/basic-layer-breakdown.md @@ -2,7 +2,7 @@ This is a very minimal layer with minimal features. Most things will require additional features: -``p: { + p: { startData() { return { // startData is a function that returns default data for a layer. unl: false, // You can add more variables here to add them to your layer. points: new Decimal(0), // "points" is the internal name for the main resource of the layer. @@ -30,4 +30,4 @@ This is a very minimal layer with minimal features. Most things will require add }, layerShown() {return true}, // Returns a bool for if this layer's node should be visible in the tree. - }, `` \ No newline at end of file + }, \ No newline at end of file diff --git a/docs/buyables.md b/docs/buyables.md index 4ae7c58..d776fd6 100644 --- a/docs/buyables.md +++ b/docs/buyables.md @@ -5,18 +5,18 @@ the player can reset the purchases to get their currency back. Buyables should be formatted like this: -``buyables: { - rows: # of rows - cols: # of columns - respec() {}, **optional**, implement it to reset things and give back your currency. - Having this function makes a respec button appear - respecText: **optional**, text that appears on the respec button - 11: { - desc: "Blah", + buyables: { + rows: # of rows + cols: # of columns + respec() {}, **optional**, implement it to reset things and give back your currency. + Having this function makes a respec button appear + respecText: **optional**, text that appears on the respec button + 11: { + desc: "Blah", + etc + } etc } - etc -}`` Features: diff --git a/docs/challenges.md b/docs/challenges.md index dafee20..bbc9a06 100644 --- a/docs/challenges.md +++ b/docs/challenges.md @@ -2,15 +2,15 @@ Challenges are stored in the following format: -``challs: { - rows: # of rows - cols: # of columns - 11: { - name: "Ouch", + challs: { + rows: # of rows + cols: # of columns + 11: { + name: "Ouch", + etc + } etc } - etc -}`` You can use inChall(layer, id) and hasChall(layer, id) to determine if the player is currently in a challenge, or has completed the challenge, respectively. These are useful for implementing effects. diff --git a/docs/custom-tab-layouts.md b/docs/custom-tab-layouts.md index 773f71d..f1ed5e8 100644 --- a/docs/custom-tab-layouts.md +++ b/docs/custom-tab-layouts.md @@ -2,7 +2,7 @@ Custom tab layouts can be used to do basically anything in a tab window, especially combined with the "style" layer feature. The tabFormat feature is an array of things, like this: -`` + tabFormat: ["main-display", ["prestige-button", function(){return "Melt your points into "}], ["raw-html", function() {return ""}], @@ -11,7 +11,7 @@ Custom tab layouts can be used to do basically anything in a tab window, especia {"color": "red", "font-size": "32px", "font-family": "Comic Sans MS"}], "blank", ["toggle", ["c", "beep"]], - "milestones", "blank", "blank", "upgrades"] `` + "milestones", "blank", "blank", "upgrades"] It is a list of components, which can be either just a name, or an array with arguments. If it's an array, the first item is the name of the component, the second is the data passed into it, and the third (optional) is a CSS object, which applies its style to the component.