mirror of
https://github.com/Acamaeda/The-Modding-Tree.git
synced 2024-11-25 01:41:45 +00:00
Added glowColor
This commit is contained in:
parent
cbb303c21b
commit
69dc926eb6
4 changed files with 7 additions and 1 deletions
|
@ -1,10 +1,11 @@
|
||||||
# The Modding Tree changelog:
|
# The Modding Tree changelog:
|
||||||
|
|
||||||
# v2.4.2 (beta)
|
# v2.5 (beta)
|
||||||
- Optimizations, hopefully a significant amount.
|
- Optimizations, hopefully a significant amount.
|
||||||
- Added OOM/s point gen display at high values (thanks to Ducdat!)
|
- Added OOM/s point gen display at high values (thanks to Ducdat!)
|
||||||
- Only one tab will display if the window is not wide enough (also thanks to Ducdat!)
|
- Only one tab will display if the window is not wide enough (also thanks to Ducdat!)
|
||||||
- Layer nodes will be highlighted even if the player is on the same tab.
|
- Layer nodes will be highlighted even if the player is on the same tab.
|
||||||
|
- Added customizable node glowColor.
|
||||||
- Added buyable purchaseLimit.
|
- Added buyable purchaseLimit.
|
||||||
- Amount is automatically supplied to buyable cost and effect functions.
|
- Amount is automatically supplied to buyable cost and effect functions.
|
||||||
- Locked (not yet visible) milestones no longer take up space. Also fixed hidden milestones taking a tiny bit of space.
|
- Locked (not yet visible) milestones no longer take up space. Also fixed hidden milestones taking a tiny bit of space.
|
||||||
|
|
|
@ -155,6 +155,8 @@ You can make almost any value dynamic by using a function in its place, includin
|
||||||
|
|
||||||
- shouldNotify: **optional**. A function to return true if this layer should be highlighted in the tree. The layer will automatically be highlighted if you can buy an upgrade whether you have this or not.
|
- shouldNotify: **optional**. A function to return true if this layer should be highlighted in the tree. The layer will automatically be highlighted if you can buy an upgrade whether you have this or not.
|
||||||
|
|
||||||
|
- glowColor: **optional**. The color that this layer will be highlighted if it should notify. The default is red. You can use this if you want several different notification types!
|
||||||
|
|
||||||
- componentStyles: **optional**. An object that contains a set of functions returning CSS objects. Each of these will be applied to any components on the layer with the type of its id. Example:
|
- componentStyles: **optional**. An object that contains a set of functions returning CSS objects. Each of these will be applied to any components on the layer with the type of its id. Example:
|
||||||
|
|
||||||
```js
|
```js
|
||||||
|
|
|
@ -355,6 +355,7 @@ addLayer("c", {
|
||||||
'color': '#3325CC',
|
'color': '#3325CC',
|
||||||
'text-decoration': 'underline'
|
'text-decoration': 'underline'
|
||||||
}},
|
}},
|
||||||
|
glowColor: "orange", // If the node is highlighted, it will be this color (default is red)
|
||||||
componentStyles: {
|
componentStyles: {
|
||||||
"challenge"() {return {'height': '200px'}},
|
"challenge"() {return {'height': '200px'}},
|
||||||
"prestige-button"() {return {'color': '#AA66AA'}},
|
"prestige-button"() {return {'color': '#AA66AA'}},
|
||||||
|
|
|
@ -18,6 +18,8 @@ function constructNodeStyle(layer){
|
||||||
style.push({'background-color': tmp[layer].color})
|
style.push({'background-color': tmp[layer].color})
|
||||||
if (tmp[layer].image !== undefined)
|
if (tmp[layer].image !== undefined)
|
||||||
style.push({'background-image': 'url("' + tmp[layer].image + '")'})
|
style.push({'background-image': 'url("' + tmp[layer].image + '")'})
|
||||||
|
if(tmp[layer].glowColor !== undefined && tmp[layer].notify && player[layer].unlocked)
|
||||||
|
style.push({'box-shadow': 'var(--hqProperty2a), 0 0 20px ' + tmp[layer].glowColor})
|
||||||
style.push(tmp[layer].nodeStyle)
|
style.push(tmp[layer].nodeStyle)
|
||||||
return style
|
return style
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue