Template:Condition page: Difference between revisions

Jump to navigation Jump to search
Only checks if stack id is unique if there is a stack id. Added new features to stack ID documentation.
m (added __NOTOC__ again to remove table of contents appearing in the middle of the tooltip box.)
(Only checks if stack id is unique if there is a stack id. Added new features to stack ID documentation.)
Line 8: Line 8:
<!--backwards compat for disease-->
<!--backwards compat for disease-->
| {{#ifeq:{{{disease|}}}|yes|disease|{{{type|}}} }}
| {{#ifeq:{{{disease|}}}|yes|disease|{{{type|}}} }}
}}<!-- Check if the stack ID is used by any other conditions and save it as #lvar:stackid --> {{#vardefine:counter|0
}}<!-- Check if the stack ID is used by any other conditions and save it as #lvar:stackid --> {{#if:{{{stack id|}}}|{{#vardefine:counter|0
}}{{#cargo_query:tables=conditions|fields=name|where=stack_id='{{{stack id}}}'|format=template|template=counter
}}{{#cargo_query:tables=conditions|fields=name|where=stack_id='{{{stack id}}}'|format=template|template=counter
}}{{#lvardef:stackid|{{#if:{{{stack id|}}}|{{#ifeq:{{#var:counter}}|1||1}}}}
}}{{#lvardef:stackid|{{#if:{{{stack id|}}}|{{#ifeq:{{#var:counter}}|1||1}}}}}}


}}{{PageSeo
}}{{PageSeo
Line 217: Line 217:
},
},
"stack id": {
"stack id": {
"description": "Stack ID for the condition. Conditions with the same Stack ID can not be present at the same time.",
"description": "Stack ID for the condition. Conditions with the same stack ID can not be present at the same time. If a stack ID is specified, it will only display if there are other conditions with that stack ID. It will also display those conditions. ",
"type": "string",
"type": "string",
"example": "HASTE, Polymorph_WildShape "
"example": "HASTE, Polymorph_WildShape "

Navigation menu