Difference between revisions of "Template:UserCharacterChecklist"
Jump to navigation
Jump to search
(Undo revision 2672 - the code still kills the pages if too many, need to be precautious next time) |
m (i actually forgot to remove sorting) |
||
(5 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
<includeonly> | |||
{| class="wikitable | {| class="wikitable" style="width: 50%; text-align: center;" | ||
!Characters | !Characters | ||
!☆3 | !☆3 | ||
Line 6: | Line 6: | ||
!☆5 | !☆5 | ||
|- | |- | ||
{{#vardefine: setColor|inherit}} | |||
{{ | {{ | ||
#forargs: c | #forargs: c | ||
| | | character | ||
| | | flags | ||
| <nowiki/> | | <nowiki/> | ||
{{ #if: {{ #pos: {{ #var: character }} | GroupColor }} | |||
{{!}}- | | {{ #vardefine: setColor|{{ #var: flags }} }} | ||
| {{!}} style="background-color: {{ #if: {{ #var: setColor }} | {{ #var: setColor }} | inherit }};" {{!}} [[ {{ #var: character }} |<span style="color:black; font-weight: bold;">{{ #var: character }}</span> ]]{{ | |||
#loop: star | |||
| 3 | |||
| 3 | |||
| {{!}}{{!}}{{ | |||
#if: {{ #pos: {{ #explode: {{ #var: flags }}|/|0 }} | {{ #var: star }} }} | |||
| style="background-color: lime;" {{!}} ✔ | |||
| {{ | |||
#if: {{ #pos: {{ #explode: {{ #var: flags }}|/|1 }} | {{ #var: star }} }} | |||
| style="background-color: red;" {{!}} ✘ | |||
| style="background-color: black;" {{!}} - | |||
}} | |||
}} | |||
}} | |||
{{!}}- | |||
}} | |||
}} | }} | ||
|} | |} | ||
</includeonly><noinclude> | |||
=Template Usage= | |||
The template is fairly simple to use, you just have to make sure that the variables are CASE-SENSITIVE; otherwise you will end up with a broken template. | |||
This template is only used to checklist the characters you do have in the game, unlike any other PAD/Gacha styled games, this can be a collect-a-thon. | |||
==To call the template== | |||
<nowiki> | |||
{{UserCharacterChecklist | |||
<<< stuff >>> | |||
}} | |||
</nowiki> | |||
==The defined variables== | |||
All attributes has to start with "c", any attribute that does not start with "c" will be ignored based on the args loop. | |||
<nowiki> | |||
|c<character name>=<do have>/<don't have> | |||
eg. | |||
|cYoul=34 | |||
|cSitri=3/4 | |||
|cMoritaka=4/35 | |||
|cJebb=/35 | |||
---------- | |||
|cGroupColor<type>=<color> | |||
eg. | |||
|cGroupColorFire=red | |||
</nowiki> | |||
==Setting up the group colors== | |||
<nowiki> | |||
{{UserCharacterChecklist | |||
|cGroupColorFire=lightcoral | |||
}} | |||
</nowiki> | |||
This will set any future character the set group color. To set a new color for other characters, it has to be placed before the characters are defined. | |||
<nowiki> | |||
eg. | |||
|cGroupColorWater=blue | |||
|cSomeCharacter=345 | |||
|cGroupColorWhatever=... | |||
</nowiki> | |||
* Do notice that '''#''' will break the format when being parsed, so either use '''Color(r, g, b)''' or '''BY THE NAME COLOR''' by using a html color code table at whatever page it has. | |||
== Additional Notes == | |||
* This template has no way of verifying if the character name is typed correctly. You are responsible to type the names correctly. | |||
* This template has no way of verifying if the color is correctly set. If wrong, the template will break. | |||
* This template has no way of adding the characters automatically. Make sure to update properly when needed | |||
</noinclude> |
Latest revision as of 06:03, 28 April 2017
Template Usage
The template is fairly simple to use, you just have to make sure that the variables are CASE-SENSITIVE; otherwise you will end up with a broken template.
This template is only used to checklist the characters you do have in the game, unlike any other PAD/Gacha styled games, this can be a collect-a-thon.
To call the template
{{UserCharacterChecklist <<< stuff >>> }}
The defined variables
All attributes has to start with "c", any attribute that does not start with "c" will be ignored based on the args loop.
|c<character name>=<do have>/<don't have> eg. |cYoul=34 |cSitri=3/4 |cMoritaka=4/35 |cJebb=/35 ---------- |cGroupColor<type>=<color> eg. |cGroupColorFire=red
Setting up the group colors
{{UserCharacterChecklist |cGroupColorFire=lightcoral }}
This will set any future character the set group color. To set a new color for other characters, it has to be placed before the characters are defined.
eg. |cGroupColorWater=blue |cSomeCharacter=345 |cGroupColorWhatever=...
- Do notice that # will break the format when being parsed, so either use Color(r, g, b) or BY THE NAME COLOR by using a html color code table at whatever page it has.
Additional Notes
- This template has no way of verifying if the character name is typed correctly. You are responsible to type the names correctly.
- This template has no way of verifying if the color is correctly set. If wrong, the template will break.
- This template has no way of adding the characters automatically. Make sure to update properly when needed