mirror of
https://github.com/Acamaeda/The-Modding-Tree.git
synced 2025-03-22 22:21:46 +00:00
Made a few things not display if they are""
This commit is contained in:
parent
66d7d5b4fb
commit
399d0bce9f
4 changed files with 11 additions and 4 deletions
|
@ -1,4 +1,8 @@
|
||||||
# The Modding Tree changelog:
|
# Incrementum changelog:
|
||||||
|
|
||||||
|
- Upgrade effectDisplay and grid tooltip no longer display if they return "".
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# v2.6.6.2 = 9/9/21
|
# v2.6.6.2 = 9/9/21
|
||||||
- nodeStyle can now be used to set fonts.
|
- nodeStyle can now be used to set fonts.
|
||||||
|
|
|
@ -60,6 +60,9 @@ addLayer("a", {
|
||||||
getDisplay(data, id) {
|
getDisplay(data, id) {
|
||||||
return data
|
return data
|
||||||
},
|
},
|
||||||
|
getTooltip(data, id) {
|
||||||
|
return(12)
|
||||||
|
}
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
)
|
)
|
|
@ -178,7 +178,7 @@ function loadVue() {
|
||||||
<span v-else>
|
<span v-else>
|
||||||
<span v-if= "tmp[layer].upgrades[data].title"><h3 v-html="tmp[layer].upgrades[data].title"></h3><br></span>
|
<span v-if= "tmp[layer].upgrades[data].title"><h3 v-html="tmp[layer].upgrades[data].title"></h3><br></span>
|
||||||
<span v-html="tmp[layer].upgrades[data].description"></span>
|
<span v-html="tmp[layer].upgrades[data].description"></span>
|
||||||
<span v-if="layers[layer].upgrades[data].effectDisplay"><br>Currently: <span v-html="run(layers[layer].upgrades[data].effectDisplay, layers[layer].upgrades[data])"></span></span>
|
<span v-if="layers[layer].upgrades[data].effectDisplay && run(layers[layer].upgrades[data].effectDisplay, layers[layer].upgrades[data]) !== ''"><br>Currently: <span v-html="run(layers[layer].upgrades[data].effectDisplay, layers[layer].upgrades[data])"></span></span>
|
||||||
<br><br>Cost: {{ formatWhole(tmp[layer].upgrades[data].cost) }} {{(tmp[layer].upgrades[data].currencyDisplayName ? tmp[layer].upgrades[data].currencyDisplayName : tmp[layer].resource)}}
|
<br><br>Cost: {{ formatWhole(tmp[layer].upgrades[data].cost) }} {{(tmp[layer].upgrades[data].currencyDisplayName ? tmp[layer].upgrades[data].currencyDisplayName : tmp[layer].resource)}}
|
||||||
</span>
|
</span>
|
||||||
<tooltip v-if="tmp[layer].upgrades[data].tooltip" :text="tmp[layer].upgrades[data].tooltip"></tooltip>
|
<tooltip v-if="tmp[layer].upgrades[data].tooltip" :text="tmp[layer].upgrades[data].tooltip"></tooltip>
|
||||||
|
@ -401,7 +401,7 @@ function loadVue() {
|
||||||
v-on:click="clickGrid(layer, data)" @mousedown="start" @mouseleave="stop" @mouseup="stop" @touchstart="start" @touchend="stop" @touchcancel="stop">
|
v-on:click="clickGrid(layer, data)" @mousedown="start" @mouseleave="stop" @mouseup="stop" @touchstart="start" @touchend="stop" @touchcancel="stop">
|
||||||
<span v-if= "layers[layer].grid.getTitle"><h3 v-html="gridRun(this.layer, 'getTitle', player[this.layer].grid[this.data], this.data)"></h3><br></span>
|
<span v-if= "layers[layer].grid.getTitle"><h3 v-html="gridRun(this.layer, 'getTitle', player[this.layer].grid[this.data], this.data)"></h3><br></span>
|
||||||
<span v-bind:style="{'white-space': 'pre-line'}" v-html="gridRun(this.layer, 'getDisplay', player[this.layer].grid[this.data], this.data)"></span>
|
<span v-bind:style="{'white-space': 'pre-line'}" v-html="gridRun(this.layer, 'getDisplay', player[this.layer].grid[this.data], this.data)"></span>
|
||||||
<tooltip v-if="layers[layer].grid.getTooltip" :text="gridRun(this.layer, 'getTooltip', player[this.layer].grid[this.data], this.data)"></tooltip>
|
<tooltip v-if="layers[layer].grid.getTooltip && gridRun(this.layer, 'getTooltip', player[this.layer].grid[this.data], this.data) !== ''" :text="gridRun(this.layer, 'getTooltip', player[this.layer].grid[this.data], this.data)"></tooltip>
|
||||||
|
|
||||||
</button>
|
</button>
|
||||||
`,
|
`,
|
||||||
|
|
|
@ -11,7 +11,7 @@ var activeFunctions = [
|
||||||
"effectDescription", "display", "fullDisplay", "effectDisplay", "rewardDisplay",
|
"effectDescription", "display", "fullDisplay", "effectDisplay", "rewardDisplay",
|
||||||
"tabFormat", "content",
|
"tabFormat", "content",
|
||||||
"onComplete", "onPurchase", "onEnter", "onExit", "done",
|
"onComplete", "onPurchase", "onEnter", "onExit", "done",
|
||||||
"getUnlocked", "getStyle", "getCanClick", "getTitle", "getDisplay"
|
"getUnlocked", "getStyle", "getCanClick", "getTitle", "getDisplay", "getTooltip",
|
||||||
]
|
]
|
||||||
|
|
||||||
var noCall = doNotCallTheseFunctionsEveryTick
|
var noCall = doNotCallTheseFunctionsEveryTick
|
||||||
|
|
Loading…
Add table
Reference in a new issue