Template:Infobox weapon: Difference between revisions
Template page
More actions
Technochips (talk | contribs) removing align=right; this should be automatic with the class |
m typo fix |
||
| (16 intermediate revisions by 4 users not shown) | |||
| Line 1: | Line 1: | ||
{| class="infobox" width= | {| class="infobox" width=320px | ||
|+ | |+ | ||
! colspan="2" class="infobox-title" | | ! colspan="2" class="infobox-title" | {{{title|{{ROOTPAGENAME}}}}} | ||
{{#ifexist: File:Backpack | {{#ifexist: File:Backpack {{{image|{{ROOTPAGENAME}}}}}.png | | ||
{{!}}- | {{!}}- | ||
{{!}} colspan="2" style="padding:10px" class="infobox-image" {{!}} | {{!}} colspan="2" style="padding:10px" class="infobox-image" {{!}} | ||
[[File:Backpack | [[File:Backpack {{{image|{{BASEPAGENAME}}}}}.png|center|frameless|200px]] | ||
}} | }} | ||
{{#ifexist: File:killicon_{{lc | {{#ifexist: File:killicon_{{lc:{{{kill-icon|{{BASEPAGENAME}}}}}}}.png | | ||
{{!}}+ | {{!}}+ | ||
! colspan="2" {{!}} Kill Icons | ! colspan="2" {{!}} {{Lang | ||
| en = Kill Icons | |||
| fr = Icône de Frag | |||
}} | |||
{{!}}- | {{!}}- | ||
{{!}} colspan="2" class="killicon" {{!}} [[File:killicon_{{lc | {{!}} colspan="2" class="killicon" {{!}} [[File:killicon_{{lc:{{{kill-icon|{{BASEPAGENAME}}}}}}}.png|center|frameless]] | ||
{{#if: {{{kill-icon-2|}}}| | {{#if: {{{kill-icon-2|}}}| | ||
{{!}}- | {{!}}- | ||
{{!}} colspan="2" class="killicon" {{!}} [[File:killicon_ | {{!}} colspan="2" class="killicon" {{!}} [[File:killicon_{{{kill-icon-2}}}.png|center|frameless]] | ||
}} | }} | ||
{{#if: {{{kill-icon-3|}}}| | {{#if: {{{kill-icon-3|}}}| | ||
{{!}}- | {{!}}- | ||
{{!}} colspan="2" class="killicon" {{!}} [[File:killicon_ | {{!}} colspan="2" class="killicon" {{!}} [[File:killicon_{{{kill-icon-3}}}.png|center|frameless]] | ||
}} | }} | ||
{{#if: {{{kill-icon-4|}}}| | {{#if: {{{kill-icon-4|}}}| | ||
{{!}}- | {{!}}- | ||
{{!}} colspan="2" class="killicon" {{!}} [[File:killicon_{{ | {{!}} colspan="2" class="killicon" {{!}} [[File:killicon_{{{kill-icon-4}}}.png|center|frameless]] | ||
}} | |||
{{#if: {{{kill-icon-5|}}}| | |||
{{!}}- | |||
{{!}} colspan="2" class="killicon" {{!}} [[File:killicon_{{{kill-icon-5}}}.png|center|frameless]] | |||
}} | |||
{{#if: {{{kill-icon-6|}}}| | |||
{{!}}- | |||
{{!}} colspan="2" class="killicon" {{!}} [[File:killicon_{{{kill-icon-6}}}.png|center|frameless]] | |||
}} | |||
{{#if: {{{kill-icon-7|}}}| | |||
{{!}}- | |||
{{!}} colspan="2" class="killicon" {{!}} [[File:killicon_{{{kill-icon-7}}}.png|center|frameless]] | |||
}} | |||
{{#if: {{{kill-icon-8|}}}| | |||
{{!}}- | |||
{{!}} colspan="2" class="killicon" {{!}} [[File:killicon_{{{kill-icon-8}}}.png|center|frameless]] | |||
}} | |||
{{#if: {{{kill-icon-9|}}}| | |||
{{!}}- | |||
{{!}} colspan="2" class="killicon" {{!}} [[File:killicon_{{{kill-icon-9}}}.png|center|frameless]] | |||
}} | |||
{{#if: {{{kill-icon-10|}}}| | |||
{{!}}- | |||
{{!}} colspan="2" class="killicon" {{!}} [[File:killicon_{{{kill-icon-10}}}.png|center|frameless]] | |||
}} | }} | ||
}} | }} | ||
|+ | |+ | ||
! colspan="2" | Basic Information | ! colspan="2" | {{Lang | ||
| en = Basic Information | |||
| fr = Informations de base | |||
}} | |||
{{#if: {{{used-by|}}} | | {{#if: {{{used-by|}}} | | ||
{{!}}- | {{!}}- | ||
{{!}} Used by {{!!}} [[{{{used-by}}}]]{{#if: {{{used-by-2|}}} |, [[{{{used-by-2}}}]]}}{{#if: {{{used-by-3|}}} |, [[{{{used-by-3}}}]]}}{{#if: {{{used-by-4|}}} |, [[{{{used-by-4}}}]]}} | {{!}} {{Lang | ||
| en = Used by | |||
| fr = Utilisé par | |||
}} {{!!}} [[{{{used-by}}}]]{{#if: {{{used-by-2|}}} |, [[{{{used-by-2}}}]]}}{{#if: {{{used-by-3|}}} |, [[{{{used-by-3}}}]]}}{{#if: {{{used-by-4|}}} |, [[{{{used-by-4}}}]]}} | |||
}} | }} | ||
{{#if: {{{slot|}}} | | {{#if: {{{slot|}}} | | ||
{{!}}- | {{!}}- | ||
{{!}} Slot {{!!}} [[:Category:{{{slot}}} weapons|{{{slot}}}]]{{#if: {{{slot-2|}}} |, [[:Category:{{{slot-2}}} weapons|{{{slot-2}}}]]}} | {{!}} {{Lang | ||
| en = Slot | |||
| fr = Emplacement | |||
}} {{!!}} [[:Category:{{{slot}}} weapons|{{{slot}}}]]{{#if: {{{slot-2|}}} |, [[:Category:{{{slot-2}}} weapons|{{{slot-2}}}]]}} | |||
}} | }} | ||
{{#if: {{{ammo-loaded|}}} | | {{#if: {{{ammo-loaded|}}} | | ||
{{!}}+ | {{!}}+ | ||
! colspan="2" {{!}} Ammo | ! colspan="2" {{!}} {{Lang | ||
| en = Ammo | |||
| fr = Munitions | |||
}} | |||
{{!}}- | {{!}}- | ||
{{!}} Ammo loaded {{!!}} {{{ammo-loaded}}} | {{!}} {{Lang | ||
| en = Ammo loaded | |||
| fr = Munitions chargées | |||
}} {{!!}} {{{ammo-loaded}}} | |||
{{#if: {{{ammo-carried|}}} | | {{#if: {{{ammo-carried|}}} | | ||
{{!}}- | {{!}}- | ||
{{!}} Ammo carried{{!!}} {{{ammo-carried}}} | {{!}} {{Lang | ||
| en = Ammo carried | |||
| fr = Munitions transportées | |||
}}{{!!}} {{{ammo-carried}}} | |||
}} | }} | ||
{{#if: {{{reload-type|}}} | | {{#if: {{{reload-type|}}} | | ||
{{!}}- | {{!}}- | ||
{{!}} Reload type{{!!}} {{{reload-type}}} | {{!}} {{Lang | ||
| en = Reload type | |||
| fr = Type de recharge | |||
}}{{!!}} {{{reload-type}}} | |||
}} | }} | ||
}} | }} | ||
{{#if: {{{loadout|}}} | | {{#if: {{{loadout|}}} | | ||
{{!}}+ | {{!}}+ | ||
! colspan="2" {{!}} Loadout Stats | ! colspan="2" {{!}} {{Lang | ||
| en = Loadout Stats | |||
| fr = Statistiques d'inventaire | |||
}} | |||
{{!}}- | {{!}}- | ||
{{!}} colspan="2" class="loadout-tooltip-container" {{!}} {{Loadout name|{{#if: {{{loadout-propername|}}}|The}} {{{loadout-name|{{ | {{!}} colspan="2" class="loadout-tooltip-container" {{!}} {{Loadout name|{{#if: {{{loadout-propername|}}}|The}} {{{loadout-name|{{{title|{{BASEPAGENAME}}}}}}}}|{{#if: {{{loadout-2|}}}|{{{used-by}}}}}}}{{Loadout type|{{{loadout-kind|{{{title|{{BASEPAGENAME}}}}}}}}}}{{#if: {{{loadout-attributes|}}}|{{{loadout-attributes}}}}} | ||
{{#if: {{{loadout-2|}}} | | {{#if: {{{loadout-2|}}} | | ||
{{!}}- | {{!}}- | ||
{{!}} colspan="2" class="loadout-tooltip-container" {{!}} {{Loadout name|{{#if: {{{loadout-propername|}}}|The}} {{{loadout-name|{{ | {{!}} colspan="2" class="loadout-tooltip-container" {{!}} {{Loadout name|{{#if: {{{loadout-propername|}}}|The}} {{{loadout-name|{{{title|{{BASEPAGENAME}}}}}}}}|{{{used-by-2}}}}}{{Loadout type|{{{loadout-kind|{{{title|{{BASEPAGENAME}}}}}}}}}}{{#if: {{{loadout-2-attributes|}}}|{{{loadout-2-attributes}}}}} | ||
}} | }} | ||
{{#if: {{{loadout-3|}}} | | {{#if: {{{loadout-3|}}} | | ||
{{!}}- | {{!}}- | ||
{{!}} colspan="2" class="loadout-tooltip-container" {{!}} {{Loadout name|{{#if: {{{loadout-propername|}}}|The}} {{{loadout-name|{{ | {{!}} colspan="2" class="loadout-tooltip-container" {{!}} {{Loadout name|{{#if: {{{loadout-propername|}}}|The}} {{{loadout-name|{{{title|{{BASEPAGENAME}}}}}}}}|{{{used-by-3}}}}}{{Loadout type|{{{loadout-kind|{{{title|{{BASEPAGENAME}}}}}}}}}}{{#if: {{{loadout-3-attributes|}}}|{{{loadout-3-attributes}}}}} | ||
}} | }} | ||
{{#if: {{{loadout-4|}}} | | {{#if: {{{loadout-4|}}} | | ||
{{!}}- | {{!}}- | ||
{{!}} colspan="2" class="loadout-tooltip-container" {{!}} {{Loadout name|{{#if: {{{loadout-propername|}}}|The}} {{{loadout-name|{{ | {{!}} colspan="2" class="loadout-tooltip-container" {{!}} {{Loadout name|{{#if: {{{loadout-propername|}}}|The}} {{{loadout-name|{{{title|{{BASEPAGENAME}}}}}}}}|{{{used-by-4}}}}}{{Loadout type|{{{loadout-kind|{{{title|{{BASEPAGENAME}}}}}}}}}}{{#if: {{{loadout-4-attributes|}}}|{{{loadout-4-attributes}}}}} | ||
}} | }} | ||
}} | }} | ||
|} | |} | ||
<includeonly>[[Category:Weapons]] | <includeonly>[[Category:Weapons{{#ifeq:{{PAGELANGUAGE}}|en||/{{PAGELANGUAGE}}}}]] | ||
{{#if: {{{used-by|}}} | [[Category:{{{used-by}}}]]}} | {{#if: {{{used-by|}}} | [[Category:{{{used-by}}}{{#ifeq:{{PAGELANGUAGE}}|en||/{{PAGELANGUAGE}}}}]]}} | ||
{{#if: {{{used-by-2|}}} | [[Category:{{{used-by-2}}}]]}} | {{#if: {{{used-by-2|}}} | [[Category:{{{used-by-2}}}{{#ifeq:{{PAGELANGUAGE}}|en||/{{PAGELANGUAGE}}}}]]}} | ||
{{#if: {{{used-by-3|}}} | [[Category:{{{used-by-3}}}]]}} | {{#if: {{{used-by-3|}}} | [[Category:{{{used-by-3}}}{{#ifeq:{{PAGELANGUAGE}}|en||/{{PAGELANGUAGE}}}}]]}} | ||
{{#if: {{{used-by-4|}}} | [[Category:{{{used-by-4}}}]]}} | {{#if: {{{used-by-4|}}} | [[Category:{{{used-by-4}}}{{#ifeq:{{PAGELANGUAGE}}|en||/{{PAGELANGUAGE}}}}]]}} | ||
{{#if: {{{slot|}}} | [[Category:{{{slot}}} weapons]]}} | {{#if: {{{slot|}}} | [[Category:{{{slot}}} weapons{{#ifeq:{{PAGELANGUAGE}}|en||/{{PAGELANGUAGE}}}}]]}} | ||
{{#if: {{{slot-2|}}} | [[Category:{{{slot-2}}} weapons]]}}</includeonly><noinclude> | {{#if: {{{slot-2|}}} | [[Category:{{{slot-2}}} weapons{{#ifeq:{{PAGELANGUAGE}}|en||/{{PAGELANGUAGE}}}}]]}}</includeonly><noinclude> | ||
Example usage: | Example usage: | ||
<pre> | <pre> | ||
{{Infobox weapon | {{Infobox weapon | ||
| title=Shotgun | | title=Shotgun <!-- optional, uses the article's name! --> | ||
| image=Shotgun | | image=Shotgun <!-- optional, attempts to use the article's name! --> | ||
| kill-icon=shotgun | | kill-icon=shotgun <!-- optional, attempts to get kill icon using the article's name! see [[Category:Kill icons]] for all kill icons --> | ||
| kill-icon-2=taunt_pyro | | kill-icon-2=taunt_pyro <!-- optional, to use whenever the weapon has multiple kill icons. can have up to 10 kill icons. --> | ||
| used-by=Engineer | | used-by=Engineer <!-- must be a class name --> | ||
| used-by-2=Soldier | | used-by-2=Soldier <!-- optional --> | ||
| used-by-3=Pyro | | used-by-3=Pyro | ||
| used-by-4=Heavy | | used-by-4=Heavy | ||
| slot=Primary | | slot=Primary <!-- must be a weapon slot type --> | ||
| slot-2=Secondary | | slot-2=Secondary <!-- optional --> | ||
| ammo-loaded=6 | | ammo-loaded=6 | ||
| ammo-carried=32 | | ammo-carried=32 | ||
| reload=Single | | reload-type=Single | ||
| loadout=yes | | loadout=yes <!-- use to make the loadout shows up --> | ||
| loadout-attributes={{Loadout neutral| | | loadout-kind=Shotgun <!-- optional, uses the article's name by default. use whenever the weapon "type" is different ingame! --> | ||
| loadout-2=yes | | loadout-propername=yes <!-- optional, to use whenever the weapon is shown as "The Shotgun" ingame! --> | ||
| loadout-2-attributes={{Loadout neutral| | | loadout-attributes= <!-- the attributes must match the ingame attributes --> | ||
{{Loadout positive|+200% damage}} | |||
{{Loadout negative|-50% fire speed}} | |||
<br> <!-- new line --> | |||
{{Loadout neutral|Sometimes, you just have to do things yourself.}} | |||
| loadout-2=yes <!-- completely optional, only usable with multiple "used-by" tags --> | |||
| loadout-2-attributes={{Loadout neutral|My shotgun disagrees with your will to live, maggot!}} | |||
| loadout-3=yes | | loadout-3=yes | ||
| loadout-4=yes | | loadout-4=yes | ||
| loadout-4-attributes={{Loadout neutral| | | loadout-4-attributes={{Loadout neutral|Heavy will make do with this.}} | ||
}} | }} | ||
</pre> | </pre> | ||
[[Category:Infobox]] | [[Category:Infobox templates]] | ||
</noinclude> | </noinclude> | ||