Template:Infobox weapon/doc
This is a documentation subpage for Template:Infobox weapon.
It contains usage information and other content that is not part of the original template page. |
This template is used to create an infobox in an article about empty water container, medical, drying, remote controller and other miscellaneous items.
Usage
To use this template in an article, copy the template below, then paste the template into an article.
All parameters are optional – those you do not populate with data will not show up in the infobox when the article is saved.
It is strongly advised to only include variables that are relevant to the specific item in question, i.e. parameters that do not display as false or 0.
{{Infobox weapon |display_name=display_name |name_colour=default |name_text_colour=default |image=image.png |alternate_image=image.png |alternate_name=alternate_name |alternate_link= |category=category |weight=weight |function=function |equipped=equipped |secondary_item=secondary_item |type=type |min_range=min_range |max_range=max_range |swing_time=swing_time |condition_max=condition_max |min_damage=min_damage |max_damage=max_damage |push_back=push_back |knockdown=knockdown |kill_move=kill_move |ammo_type=ammo_type |clip_size=clip_size |sound_radius=sound_radius |hit_chance=hit_chance |recoil_delay=recoil_delay |reload_time=reload_time |aiming_time=aiming_time |effect_power=effect_power |effect_range=effect_range |effect_timer=effect_timer |effect_type=effect_type |sensor_range=sensor_range |class_name=class_name }}
Parameters
General
- display_name
- The display name of the item as it appears in-game. Leaving blank will display the pagename.
- image
- An image of the icon displayed at 120px. A 120px variant should be used if it has one.
- alternate_image
- An alternate image displayed at 32px. Can be an empty, packaged, open or any other variant.
- alternate_name
- The name of the alternate item image. Leaving blank will display no name when the image is hovered over.
- alternate_link
- An optional link to the alternate image page. Leaving blank will have no link.
- weight
- The base weight of the item.
- "_bkg" suffix
- Will display a slightly darker background over the row; used for simpler identification between each row. Leaving blank will leave white, whereas inserting anything will give the darkened background. (same for each parameter with _bkg)
- weapon_type
- The skill this item belongs to, such as: blunt, blade or firearm. Any throwable weapon should be given the "Throwable" value.
- primary_use
- The item's primary use. Can usually be removed if the item isn't considered a tool by the wiki. (remove if value is empty)
- secondary_use
- The item's secondary use if it has one. Can usually be removed if the item isn't considered a tool by the wiki. (remove if value is empty)
- equipped
- In which hand this item needs to be equipped: primary, secondary or both; one-hand or two-hands.
- secondary_item
- The item required in the secondary slot to use this item, such as the Molotov Cocktail. (remove if value is empty)
- min_range
- The item's minimum range, regardless of whether it's melee or ranged.
- max_range
- The item's maximum range, regardless of whether it's melee or ranged. (remove if value is empty)
- min_damage
- The item's minimum damage it can deal. (remove if value is empty)
- max_damage
- The item's maximum damage it can deal. (remove if value is empty)
- class_name
- The item's class name.
Firearms
- ammo
- The ammo type this weapon uses if it has one. (remove if value is empty)
- clip_size
- The amount of ammo/bullets in a single clip/magazine. (remove if value is empty)
- sound_radius
- The radius of sound that is given off from using the item. (remove if value is empty)
Throwables
- secondary_item
- The item that must be in the secondary hand/slot to use this weapon. (remove if value is empty)
- explosion_power
- The power of the explosion caused by the item. (remove if value is empty)
- sensor_range
- How close an entity needs to be before the trap is triggered. (remove if value is empty)
- explosion_timer
- Time before trap is triggered. Defined by the
ExplosionTimer
variable. (remove if value is empty) - effect_range
- The range of the trap's effect. Defined by either
ExplosionRange
,FireRange
,SmokeRange
orNoiseRange
. (remove if value is empty) - effect_type
- The effect given-off by the trap. Can be either: "explosion", "fire", "smoke" or "noise". Any other value will display as "Effect range". (remove if value is empty)
Examples
Blunt weapons, displaying the Baseball Bat infobox
Baseball Bat | ||
---|---|---|
Baseball Bat | ||
| ||
General | ||
Category | Weapon | |
Encumbrance | 2 | |
Equipped | Two-handed | |
Condition max. | 15 | |
Damage | ||
Range | 0.61–1.5 tiles | |
Damage | 0.8–1.5 | |
Technical details | ||
Base ID | Base.BaseballBat | |
{{Infobox weapon |display_name=Baseball Bat |image=Baseballbat.png |alternate_image=BaseballBatNails.png |alternate_name=Spiked Baseball Bat |alternate_link=Spiked Baseball Bat |weight=2 |weight_bkg=1 |weapon_type=Blunt |equipped=Two-handed |equipped_bkg=1 |condition_max=15 |min_range=0.61 |max_range=1.5 |range_bkg=1 |min_damage=0.8 |max_damage=1.5 |class_name=Base.BaseballBat |class_name_bkg=1 }}
Blade weapons, displaying the Kitchen Knife infobox
Kitchen Knife | |
---|---|
General | |
Category | Weapon |
Encumbrance | 0.3 |
Function |
Weapon Knife in recipes |
Equipped | One-handed |
Condition max. | 10 |
Damage | |
Range | 0.61–0.9 tiles |
Damage | 0.3–0.3 |
Technical details | |
Base ID | Base.KitchenKnife |
{{Infobox weapon |display_name=Kitchen Knife |image=KnifeChopping.png |weight=0.3 |weight_bkg=1 |weapon_type=Blade |primary_use=Weapon |primary_use_bkg=1 |secondary_use=Knife in recipes |equipped=One-handed |equipped_bkg=1 |condition_max=10 |min_range=0.61 |max_range=0.9 |range_bkg=1 |min_damage=0.3 |max_damage=0.3 |class_name=Base.KitchenKnife |class_name_bkg=1 }}
Firearm weapons, displaying the Pistol (disambiguation) infobox
Pistol | ||
---|---|---|
| ||
General | ||
Category | Weapon | |
Encumbrance | 2 | |
Equipped | One-handed | |
Condition max. | 10 | |
Characteristics | ||
Ammo type | ||
Magazine size | 15 | |
Noise radius | 150 tiles | |
Damage | ||
Range | 0.61–10 tiles | |
Damage | 1–1.6 | |
Technical details | ||
Base ID | Base.Pistol | |
{{Infobox weapon |display_name=Pistol |image=HandGun.png |alternate_image=40calAmmoBox.png |alternate_name=9mm Rounds |alternate_link=9mm Rounds |weight=2 |weight_bkg=1 |weapon_type=Firearm |equipped=One-handed |equipped_bkg=1 |ammo=[[9mm Rounds]]<br>[[9mm Magazine]] |clip_size=15 |condition_max=10 |clip_size_bkg=1 |min_range=0.61 |max_range=10 |range_bkg=1 |min_damage=1 |max_damage=1.6 |sound_radius=150 |sound_radius_bkg=1 |class_name=Base.Pistol }}
Throwable weapons, displaying the Molotov Cocktail infobox
Molotov Cocktail | |
---|---|
Molotov Cocktail | |
General | |
Category | Weapon |
Encumbrance | 1.5 |
Equipped | One-handed |
Secondary | |
Damage | |
Range | 0–8 tiles |
fire range | 4 tiles |
Technical details | |
Base ID | Base.Molotov |
{{Infobox weapon |display_name=Molotov Cocktail |image=Molotov_120px.png |weight=1.5 |weight_bkg=1 |weapon_type=Throwable |equipped=One-handed |equipped_bkg=1 |secondary_item=[[Lighter]] |min_range=0 |max_range=8 |range_bkg=1 |effect_type=fire |effect_range=4 |class_name=Base.Molotov |class_name_bkg=1 }}
Trap weapons, displaying the Aerosol Bomb with Timer infobox
Aerosol Bomb with Timer | ||
---|---|---|
| ||
General | ||
Category | Weapon | |
Encumbrance | 1.5 | |
Equipped | One-Handed | |
Damage | ||
Range | 0–10 tiles | |
explosion range | 6 tiles | |
Technical details | ||
Base ID | Base.AerosolbombTriggered | |
{{Infobox weapon |display_name=Aerosol Bomb with Timer |image=AerosolbombTimer.png |alternate_image=Aerosolbomb.png |alternate_name=Aerosol Bomb |alternate_link=Aerosol Bomb |weight=1.5 |weight_bkg=1 |weapon_type=Throwable |equipped=One-Handed |equipped_bkg=1 |min_range=0 |max_range=10 |explosion_power=70 |explosion_power_bkg=1 |explosion_timer=10 |effect_type=explosion |effect_range=6 |effect_bkg=1 |class_name=Base.AerosolbombTriggered }}