Difference between revisions of "Template:Weapon info card"
Jump to navigation
Jump to search
Lua error: Error: Table Weapons not found..
Lua error: Error: Table Weapons not found..
>Mornsta-gpuser |
>Eave (simplify the number of queries being made by using the vardefine template) |
||
| (18 intermediate revisions by 2 users not shown) | |||
| Line 1: | Line 1: | ||
| − | <noinclude>{{doc}}[[Category:Templates]]</noinclude><includeonly>{{# | + | <noinclude>{{doc}}[[Category:Info Card Templates]]</noinclude><includeonly><!-- |
| + | -->{{#invoke:CargoQuery|main | ||
| + | |q?tables=Weapons | ||
| + | |q?where=WeaponName="{{{1|{{{Name|}}}}}}" | ||
| + | |q?fields=_pageName=pageName,WeaponName,ElementalType,Rarity,Obtain, | ||
| + | MinHp,MinAtk,MaxHp,MaxAtk,SkillName,Abilities11,Abilities21, | ||
| + | CONCAT('File:',BaseId, ' 01 ', FormId,'.png')=Portrait | ||
| + | |?groupBy=_pageName | ||
| + | |template=vardefine}}<!-- | ||
| − | Content display | + | Content display |
| − | --><div class="panel" style="display:inline-block; padding-bottom:1em;{{#ifeq:{{{noborder|0}}} | 0 | | border:1px solid gray}}"> | + | --><div class="panel" style="display:inline-block; padding-bottom:1em;{{#ifeq:{{{noborder|0}}} | 0 | | border:1px solid gray}}"> |
| − | <div class="panel-heading">[[{{ | + | <div class="panel-heading">[[{{#var:pageName}}|{{#var:WeaponName}}]]</div> |
| − | <div class="panel-body" style="display:flex;flex-wrap:wrap;justify-content:center;"> | + | <div class="panel-body" style="display:flex;flex-wrap:wrap;justify-content:center;"> |
| − | <div> | + | <div>{{#ifexist:{{#var:Portrait}}| |
| − | {{#ifexist:{{# | + | [[{{#var:Portrait}}|110px|link={{#var:pageName}}]] |
| − | </div> | + | |[[File:Unknown.png|110px|link={{{1|{{{Name|}}}}}}]]}} |
| − | + | </div> | |
| − | <div style="min-width:300px;display:flex;flex-direction:column"> | + | <div style="min-width:300px;display:flex;flex-direction:column"> |
| − | <div> | + | <div> |
| − | {{TermDescription|Element|{{InlineIcon|Icon Element|{{#var: | + | {{TermDescription|Element|{{InlineIcon|Icon Element|{{#var:ElementalType}}}} {{#var:ElementalType}}}} |
| − | {{TermDescription|HP|{{#var: | + | {{TermDescription|HP|{{#var:MinHp}} - {{#var:MaxHp}} }} |
| − | {{TermDescription|Str|{{#var: | + | {{TermDescription|Str|{{#var:MinAtk}} - {{#var:MaxAtk}} }} |
| − | {{TermDescription|Rarity|[[File:Icon Rarity Row {{#var: | + | {{TermDescription|Rarity|[[File:Icon Rarity Row {{#var:Rarity}}.png|75px|link=]]}} |
| − | {{TermDescription|Obtained From|{{# | + | {{TermDescription|Obtained From|{{#var:Obtain}} }} |
| − | </div> | + | </div> |
| − | + | <hr style="margin:1em;"> | |
| − | <hr style="margin:1em;"> | + | <div style="width:360px"> |
| − | + | <div>'''Skill''': {{SkillTooltip|{{#var:SkillName}}}}</div> | |
| − | + | <div>'''Abilities''': <!-- | |
| − | + | -->{{#ifeq:{{#var:Abilities11}} | 0 | |
| − | <div style=" | + | | None |
| − | '''Skill''': | + | |{{AbilityIconTooltip|{{#var:Abilities11}} }}<!-- |
| − | < | + | -->{{#ifeq:{{#var:Abilities21}} | 0 | |
| − | + | |, {{AbilityIconTooltip|{{#var:Abilities21}} }} | |
| − | '''Abilities''': {{#ifeq:{{# | + | }} |
| − | </div> | + | }} |
| − | + | </div> | |
| − | </div> | + | </div> |
| − | + | </div> | |
| − | </div> | + | </div> |
| − | |||
| − | </div> | ||
</div></includeonly> | </div></includeonly> | ||
Latest revision as of 07:24, 12 April 2020
Example
Lua error: Error: Table Weapons not found..[[|]]
Skill:
Error: Table Skills not found.
[[]]Lv. 1: Error: Table Skills not found.
Expression error: Unexpected < operator.Expression error: Unexpected < operator.Expression error: Unexpected < operator. Abilities:
Error: Table Abilities not found.
[[Error: Table Abilities not found.
]]Lv. 1: Error: Table Abilities not found.
, Error: Table Abilities not found.
[[Error: Table Abilities not found.
]]Lv. 1: Error: Table Abilities not found.
[[|]]
Skill:
Error: Table Skills not found.
[[]]Lv. 1: Error: Table Skills not found.
Expression error: Unexpected < operator.Expression error: Unexpected < operator.Expression error: Unexpected < operator. Abilities:
Error: Table Abilities not found.
[[Error: Table Abilities not found.
]]Lv. 1: Error: Table Abilities not found.
, Error: Table Abilities not found.
[[Error: Table Abilities not found.
]]Lv. 1: Error: Table Abilities not found.
[[|]]
Skill:
Error: Table Skills not found.
[[]]Lv. 1: Error: Table Skills not found.
Expression error: Unexpected < operator.Expression error: Unexpected < operator.Expression error: Unexpected < operator. Abilities:
Error: Table Abilities not found.
[[Error: Table Abilities not found.
]]Lv. 1: Error: Table Abilities not found.
, Error: Table Abilities not found.
[[Error: Table Abilities not found.
]]Lv. 1: Error: Table Abilities not found.