mirror of
https://github.com/Acamaeda/The-Modding-Tree.git
synced 2025-05-13 05:11:10 +00:00
Fixed many tabFormat issues
This commit is contained in:
parent
2d56c25917
commit
f4b4ec20d0
8 changed files with 27 additions and 45 deletions
js/technical
|
@ -143,9 +143,7 @@ function constructTabFormat(layer, id, family){
|
|||
|
||||
}
|
||||
if (isFunction(tabLayer)) {
|
||||
|
||||
let bound = tabLayer.bind(layers[layer])
|
||||
Vue.set(tabTemp, key, bound())
|
||||
return tabLayer()
|
||||
}
|
||||
updateTempData(tabLayer, tabTemp, tabFunc)
|
||||
return tabTemp
|
||||
|
@ -173,7 +171,7 @@ function updateTabFormat(layer) {
|
|||
|
||||
// Check for embedded layer
|
||||
if (isPlainObject(tmp[layer].tabFormat) && tmp[layer].tabFormat[tab].embedLayer !== undefined) {
|
||||
constructTabFormat(tmp[layer].tabFormat[tab].embedLayer)
|
||||
updateTabFormat(tmp[layer].tabFormat[tab].embedLayer)
|
||||
}
|
||||
|
||||
// Update microtabs
|
||||
|
@ -183,9 +181,9 @@ function updateTabFormat(layer) {
|
|||
if (tmp[layer].microtabs[family][tab]) {
|
||||
|
||||
if (tmp[layer].microtabs[family][tab].embedLayer)
|
||||
constructTabFormat(tmp[layer].microtabs[family][tab].embedLayer)
|
||||
updateTabFormat(tmp[layer].microtabs[family][tab].embedLayer)
|
||||
else
|
||||
constructTabFormat(layer, tab, family)
|
||||
Vue.set(temp[layer].microtabs[family][tab], 'content', constructTabFormat(layer, tab, family))
|
||||
}
|
||||
}
|
||||
}
|
|
@ -118,12 +118,14 @@ function setupLayer(layer){
|
|||
layers[layer].buyables[thing].layer = layer
|
||||
if (layers[layer].buyables[thing].unlocked === undefined)
|
||||
layers[layer].buyables[thing].unlocked = true
|
||||
}
|
||||
layers[layer].buyables[thing].canBuy = function() {return canBuyBuyable(this.layer, this.id)}
|
||||
if (layers[layer].buyables[thing].purchaseLimit === undefined) layers[layer].buyables[thing].purchaseLimit = new Decimal(Infinity)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if (layers[layer].clickables){
|
||||
layers[layer].clickables.layer = layer
|
||||
setRowCol(layers[layer].clickables)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue