Difference between revisions of "Template:Weapon infobox"

From Valve Cut Content
Jump to: navigation, search
(implement 1, no if-present checks tho)
(now with if statements)
Line 8: Line 8:
 
|caption3={{{caption3}}} }}
 
|caption3={{{caption3}}} }}
 
|  header1 = Basic Information
 
|  header1 = Basic Information
|  label2 = Name      |  data2 = {{{name}}}
+
{{#if: {{{name|}}} | |  label2 = Name      |  data2 = {{{name}}} }}
|  label3 = Faction      |  data3 = {{{faction}}}
+
{{#if: {{{faction|}}} | |  label3 = Faction      |  data3 = {{{faction}}} }}
|  label4 = Origin      |  data4 = {{{origin}}}
+
{{#if: {{{origin|}}} | |  label4 = Origin      |  data4 = {{{origin}}} }}
|  label5 = Usage      |  data5 = {{{ugroup1}}}
+
{{#if: {{{ugroup1|}}} | |  label5 = Usage      |  data5 = {{{ugroup1}}} }}
 
|  header6 = Technical Specifications
 
|  header6 = Technical Specifications
|  label7 = Fire Rate      |  data7 = {{{fire_rate}}}
+
{{#if: {{{fire_rate|}}} | |  label7 = Fire Rate      |  data7 = {{{fire_rate}}} }}
|  label8 = Damage      |  data8 = {{{damage}}}
+
{{#if: {{{damage|}}} | |  label8 = Damage      |  data8 = {{{damage}}} }}
|  label9 = Accuracy      |  data9 = {{{accuracy}}}
+
{{#if: {{{accuracy|}}} | |  label9 = Accuracy      |  data9 = {{{accuracy}}} }}
|  label10 = Fire Mode      |  data10 = {{{firemode}}}
+
{{#if: {{{firemode|}}} | |  label10 = Fire Mode      |  data10 = {{{firemode}}} }}
|  label11 = Recoil      |  data11 = {{{recoil}}}
+
{{#if: {{{recoil|}}} | |  label11 = Recoil      |  data11 = {{{recoil}}} }}
|  label12 = Ammo Type      |  data12 = {{{ammo_type}}}
+
{{#if: {{{ammo_type|}}} | |  label12 = Ammo Type      |  data12 = {{{ammo_type}}} }}
|  label13 = Clip Size      |  data13 = {{{clipsize}}}
+
{{#if: {{{clipsize|}}} | |  label13 = Clip Size      |  data13 = {{{clipsize}}} }}
|  label14 = Max. Clips (including active)      |  data14 = {{{clips}}}
+
{{#if: {{{clips|}}} | |  label14 = Max. Clips (including active)      |  data14 = {{{clips}}} }}
|  label15 = Ammo on weapon pickup      |  data15 = {{{faction}}}
+
{{#if: {{{faction|}}} | |  label15 = Ammo on weapon pickup      |  data15 = {{{faction}}} }}
|  label16 = Ammo on ammopack pickup      |  data16 = {{{origin}}}
+
{{#if: {{{origin|}}} | |  label16 = Ammo on ammopack pickup      |  data16 = {{{origin}}} }}
 
|  header17 = Technical Specifications (Altfire)
 
|  header17 = Technical Specifications (Altfire)
|  label18 = Fire Rate      |  data18 = {{{fire_rate2}}}
+
{{#if: {{{fire_rate2|}}} ||  label18 = Fire Rate      |  data18 = {{{fire_rate2}}} }}
|  label19 = Damage      |  data19 = {{{damage2}}}
+
{{#if: {{{damage2|}}} | |  label19 = Damage      |  data19 = {{{damage2}}} }}
|  label20 = Accuracy      |  data20 = {{{accuracy2}}}
+
{{#if: {{{accuracy2|}}} | |  label20 = Accuracy      |  data20 = {{{accuracy2}}} }}
|  label21 = Fire Mode      |  data21 = {{{firemode2}}}
+
{{#if: {{{firemode2|}}} | |  label21 = Fire Mode      |  data21 = {{{firemode2}}} }}
|  label22 = Recoil      |  data22 = {{{recoil2}}}
+
{{#if: {{{recoil2|}}} | |  label22 = Recoil      |  data22 = {{{recoil2}}} }}
|  label23 = Ammo Type      |  data23 = {{{ammo_type2}}}
+
{{#if: {{{ammo_type2|}}} | |  label23 = Ammo Type      |  data23 = {{{ammo_type2}}} }}
|  label24 = Clip Size      |  data24 = {{{clipsize2}}}
+
{{#if: {{{clipsize2|}}} | |  label24 = Clip Size      |  data24 = {{{clipsize2}}} }}
 
|  header25 = Game Information
 
|  header25 = Game Information
|  label26 = View Model      |  data26 = {{{vmodel_name}}}
+
{{#if: {{{vmodel_name|}}} | |  label26 = View Model      |  data26 = {{{vmodel_name}}} }}
|  label27 = World Model      |  data27 = {{{wmodel_name}}}
+
{{#if: {{{wmodel_name|}}} | |  label27 = World Model      |  data27 = {{{wmodel_name}}} }}
|  label28 = Weapon Entity(s)      |  data28 = {{{weapon_ent_info}}}
+
{{#if: {{{weapon_ent_info|}}} | |  label28 = Weapon Entity(s)      |  data28 = {{{weapon_ent_info}}} }}
|  label29 = Ammo Entity(s)      |  data29 = {{{ammo_ent_info}}}
+
{{#if: {{{ammo_ent_info|}}} | |  label29 = Ammo Entity(s)      |  data29 = {{{ammo_ent_info}}} }}
|  label30 = Ammo Type      |  data30 = {{{ammo_type}}}
+
{{#if: {{{ammo_type|}}} | |  label30 = Ammo Type      |  data30 = {{{ammo_type}}} }}
 
}}
 
}}
 
<noinclude>
 
<noinclude>

Revision as of 18:16, 21 November 2018

Weapon infobox
Basic Information

label2 = Name label3 = Faction label4 = Origin

label5 = Usage
Technical Specifications

label7 = Fire Rate label8 = Damage label9 = Accuracy label10 = Fire Mode label11 = Recoil label12 = Ammo Type label13 = Clip Size label14 = Max. Clips (including active) label15 = Ammo on weapon pickup

label16 = Ammo on ammopack pickup
Technical Specifications (Altfire)

label18 = Fire Rate label19 = Damage label20 = Accuracy label21 = Fire Mode label22 = Recoil label23 = Ammo Type

label24 = Clip Size
Game Information

label26 = View Model label27 = World Model label28 = Weapon Entity(s) label29 = Ammo Entity(s)

label30 = Ammo Type

Example usage:

{{Weapon infobox
|title1=Example<!-- Article title -->
|image1=Example<!-- Viewmodel front -->
|caption1=Viewmodel front
|image2=Example<!-- Viewmodel side-->
|caption2=Viewmodel side
|image3=Example<!-- Worldmodel -->
|caption3=Worldmodel
<!--- Basic Information --->
|name=Example <!-- technical name -->
|faction=Example <!---(combine, rebels, conscripts, etc)--->
|origin=Example <!---What faction it originates from--->
<!--- Technical specifications --->
|alt_fire= <!---(Yes/No) "is there altfire?"--->
|fire_rate=
|damage= <!--- Enter like this: 
*100 (To you)
*20 (To enemies)
--->
|accuracy= <!---(aka spread)--->
|range= <!-- Maximum range of the weapon, in HU. Generally intended for melee weapons. -->
|firemode= <!---(i.e. full-auto; semi-auto; burst-fire)--->
|recoil=
|clipsize= 
|clips= <!---(max qty of clips, including "active" one)--->
|ammo_on_wpickup= <!---(when you pick this weapon up how much ammo do you get)--->
|ammo_on_apickup= <!---(when you pick an ammopack (if applicable) up how much ammo do you get)--->
|ammo_on_apickuplrg= <!---How much ammo is gained when a large ammopack for this is picked up--->
<!--- Technical specifications for ALTFIRE--->
|fire_rate2=
|damage2=
|accuracy2=
|range2=
|firemode2=
|recoil2=
|clipsize2= 
|clips2=
|ammo_on_apickup2= <!---(when you pick an ammopack (for the altfire!) up how much ammo do you get)--->
<!--- Usage --->
|ugroup1= <!---Who uses the weapon?, in "normal" circumstances? Enter like this: (bulleted list)
*combine
*monkey boy
*shit on my floor
*god damn it
--->
<!--- Game Info --->
|vmodel_name=Example <!---(the .mdl file; view model)--->
|wmodel_name=Example <!---(the .mdl file; world model)--->
|weapon_ent_info=<!---The weapon's entity name in hammer--->
|ammo_ent_info=<!---Entities related to the weapon's ammo; Enter like this: (bulleted list)
*item_ammo_ar2<br>(ammo entity)
*item_ammo_ar2_large<br>(ammo entity, large)
*item_ammo_ar2_altfire<br>(ball ammo entity)
If there's only one ammo entity, just put that one without any bulleting.--->
|ammo_type=<!---What type of "leak-era" ammo it uses. Buckshot, Medium round, Small round, Sniper round, etc.--->
}}