Anonymous

Template:VColor: Difference between revisions

From Melvor Idle
Add Base parameter
(Initial creation)
 
(Add Base parameter)
Line 4: Line 4:
"params": {
"params": {
"1": {
"1": {
"label": "Version number",
"label": "Version Number",
                        "description": "Version number to be compared to current game version",
"description": "Version number to be compared to current game version",
"type": "number",
"type": "number",
"required": true
"required": true
Line 25: Line 25:
"type": "string",
"type": "string",
"description": "Text to be displayed instead of the version number"
"description": "Text to be displayed instead of the version number"
},
"Base": {
"label": "Base Version",
"description": "Version to compare \"Version Number\" against if not the current version",
"type": "number"
}
}
},
},
Line 45: Line 50:
| {{T|VColor|0.17|Text=Out of date|ColorOld=#FF0000}}
| {{T|VColor|0.17|Text=Out of date|ColorOld=#FF0000}}
{{VColor|0.17|Text=Out of date|ColorOld=#C00000}}
{{VColor|0.17|Text=Out of date|ColorOld=#C00000}}
|-
| {{T|VColor|0.40|Base=1.00|Text=Always out of date}}
{{VColor|0.40|Base=1.00|Text=Always out of date}}
|}
|}


Line 50: Line 58:
Template begins --><noinclude>{| class="wikitable"
Template begins --><noinclude>{| class="wikitable"
|-
|-
</noinclude><td style="background-color:{{#ifexpr:{{{1|0}}} >= {{CurrentVersion}}|{{{ColorCurrent|#E8FFEB}}}|{{{ColorOld|#FFE8E8}}}}};">{{{Text|{{{1}}}}}}</td><noinclude>
</noinclude><td style="background-color:{{#ifexpr:{{{1|0}}} >= {{{Base|{{CurrentVersion}}}}}|{{{ColorCurrent|#E8FFEB}}}|{{{ColorOld|#FFE8E8}}}}};">{{{Text|{{{1}}}}}}</td><noinclude>
|}</noinclude>
|}</noinclude>