1
0
Fork 0
mirror of https://github.com/Acamaeda/The-Modding-Tree.git synced 2024-11-21 16:13:55 +00:00

Moved respec checkbox to respec-button, update version+changelog

This commit is contained in:
Harley White 2021-04-29 23:42:17 -04:00
parent a80184ee0a
commit bbcb4802ff
5 changed files with 17 additions and 10 deletions

View file

@ -1,5 +1,10 @@
# The Modding Tree changelog: # The Modding Tree changelog:
# v2.4.1 - 4/29/21
- A number of minor fixes, many thanks to thepaperpilot.
- The respec confirmation checkbox is now part of the respec-button component.
- Added a few missing changes to the 2.4 changelog (the two at the bottom)
## v2.4: Rationalized Edition - 4/29/21 ## v2.4: Rationalized Edition - 4/29/21
- Completely reworked tooltips. Shift-click a node to force its tooltip to stay displayed. (And hopefully finally fixed flickering!) - Completely reworked tooltips. Shift-click a node to force its tooltip to stay displayed. (And hopefully finally fixed flickering!)
- Added text-input and slider components. - Added text-input and slider components.
@ -10,10 +15,12 @@
- You no longer need to supply 'rows' and 'cols' for any Big Features. - You no longer need to supply 'rows' and 'cols' for any Big Features.
- Node symbols can use HTML. - Node symbols can use HTML.
- Added documentation for the respec button. - Added documentation for the respec button.
- Added ctrlDown and shiftDown variables.
- Added prestigeNotify to subtabs, and prestigeNotify in subtabs also highlights the layer node. - Added prestigeNotify to subtabs, and prestigeNotify in subtabs also highlights the layer node.
- The version number no longer contains special characters or irrational numbers. - The version number no longer contains special characters or irrational numbers.
- Added ctrlDown and shiftDown variables.
- Tooltips now use HTML (this means you need to replace any newlines with <br>)
# v2.π.1 - 4/7/21 # v2.π.1 - 4/7/21
- Fixed formatting for some larger numbers. - Fixed formatting for some larger numbers.

View file

@ -360,7 +360,7 @@ addLayer("c", {
}, },
tooltip() { // Optional, tooltip displays when the layer is unlocked tooltip() { // Optional, tooltip displays when the layer is unlocked
let tooltip = formatWhole(player[this.layer].points) + " " + this.resource let tooltip = formatWhole(player[this.layer].points) + " " + this.resource
if (player[this.layer].buyables[11].gt(0)) tooltip += "\n" + formatWhole(player[this.layer].buyables[11]) + " Exhancers" if (player[this.layer].buyables[11].gt(0)) tooltip += "<br>" + formatWhole(player[this.layer].buyables[11]) + " Exhancers"
return tooltip return tooltip
}, },
shouldNotify() { // Optional, layer will be highlighted on the tree if true. shouldNotify() { // Optional, layer will be highlighted on the tree if true.

View file

@ -11,7 +11,7 @@ let modInfo = {
// Set your version in num and name // Set your version in num and name
let VERSION = { let VERSION = {
num: "2.4", num: "2.4.1",
name: "Rationalized Edition", name: "Rationalized Edition",
} }

View file

@ -241,10 +241,7 @@ function loadVue() {
props: ['layer', 'data'], props: ['layer', 'data'],
template: ` template: `
<div v-if="tmp[layer].buyables" class="upgTable"> <div v-if="tmp[layer].buyables" class="upgTable">
<div> <respec-button v-if="tmp[layer].buyables.respec && !(tmp[layer].buyables.showRespec !== undefined && tmp[layer].buyables.showRespec == false)" :layer = "layer" v-bind:style="[{'margin-bottom': '12px'}, tmp[layer].componentStyles['respec-button']]"></respec-button>
<div class="tooltipBox"><input type="checkbox" v-model="player[layer].noRespecConfirm" ><tooltip v-bind:text="'Disable respec confirmation'"></tooltip></div>
<respec-button v-if="tmp[layer].buyables.respec && !(tmp[layer].buyables.showRespec !== undefined && tmp[layer].buyables.showRespec == false)" :layer = "layer" v-bind:style="[{'margin-bottom': '12px'}, tmp[layer].componentStyles['respec-button']]"></respec-button>
</div>
<div v-for="row in tmp[layer].buyables.rows" class="upgRow"> <div v-for="row in tmp[layer].buyables.rows" class="upgRow">
<div v-for="col in tmp[layer].buyables.cols"><div v-if="tmp[layer].buyables[row*10+col]!== undefined && tmp[layer].buyables[row*10+col].unlocked" class="upgAlign" v-bind:style="{'margin-left': '7px', 'margin-right': '7px', 'height': (data ? data : 'inherit'),}"> <div v-for="col in tmp[layer].buyables.cols"><div v-if="tmp[layer].buyables[row*10+col]!== undefined && tmp[layer].buyables[row*10+col].unlocked" class="upgAlign" v-bind:style="{'margin-left': '7px', 'margin-right': '7px', 'height': (data ? data : 'inherit'),}">
<buyable :layer = "layer" :data = "row*10+col" :size = "data"></buyable> <buyable :layer = "layer" :data = "row*10+col" :size = "data"></buyable>
@ -276,10 +273,13 @@ function loadVue() {
Vue.component('respec-button', { Vue.component('respec-button', {
props: ['layer', 'data'], props: ['layer', 'data'],
template: ` template: `
<button v-if="tmp[layer].buyables && tmp[layer].buyables.respec && !(tmp[layer].buyables.showRespec !== undefined && tmp[layer].buyables.showRespec == false)" v-on:click="respecBuyables(layer)" v-bind:class="{ longUpg: true, can: player[layer].unlocked, locked: !player[layer].unlocked }">{{tmp[layer].buyables.respecText ? tmp[layer].buyables.respecText : "Respec"}}</button> <div>
<div class="tooltipBox"><input type="checkbox" v-model="player[layer].noRespecConfirm" ><tooltip v-bind:text="'Disable respec confirmation'"></tooltip></div>
<button v-if="tmp[layer].buyables && tmp[layer].buyables.respec && !(tmp[layer].buyables.showRespec !== undefined && tmp[layer].buyables.showRespec == false)" v-on:click="respecBuyables(layer)" v-bind:class="{ longUpg: true, can: player[layer].unlocked, locked: !player[layer].unlocked }">{{tmp[layer].buyables.respecText ? tmp[layer].buyables.respecText : "Respec"}}</button>
</div>
` `
}) })
// data = button size, in px // data = button size, in px
Vue.component('clickables', { Vue.component('clickables', {
props: ['layer', 'data'], props: ['layer', 'data'],

View file

@ -5,7 +5,7 @@ var scrolled = false;
// Don't change this // Don't change this
const TMT_VERSION = { const TMT_VERSION = {
tmtNum: "2.4.0.1", tmtNum: "2.4.1",
tmtName: "Rationalized Edition" tmtName: "Rationalized Edition"
} }