Template:Infobox hero: Difference between revisions

From Deadlock Wiki
Jump to navigation Jump to search
mNo edit summary
Let's hope I didn't break anything
Line 1: Line 1:
<!--
-->{{#if: {{{key|}}} |<!-- If key is provided
-->{{#vardefine:hero_key_or_en|{{{key}}}}}<!-- key
-->{{#vardefine:hero_en|{{#invoke:Lang|get_string|{{{key}}}|lang_code_override=en}}}}<!-- en
-->|<!-- If key is not provided, use {{{1}}} and assume its in english where it will be re-localized to current language in called functions
-->{{#vardefine:hero_key_or_en|{{{1}}}}}<!-- en
-->{{#vardefine:hero_en|{{{1}}}}}<!-- en
-->}}<!--
-->
<div style="margin-left: 2em;">
<div style="margin-left: 2em;">
{| class="wikitable infobox" style="color: #FFEFD7; background-color: #2F2F2F; font-weight: bold"
{| class="wikitable infobox" style="color: #FFEFD7; background-color: #2F2F2F; font-weight: bold"
Line 17: Line 26:
|-
|-
! style="color: #999999; background-color: #2F2F2F" | DPS
! style="color: #999999; background-color: #2F2F2F" | DPS
| {{Icon/Brown|[[File:Damage.png|20px|link=Damage per second]]|{{{dps}}}}}
| {{Icon/Brown|[[File:Damage.png|20px|link=Damage per second]]|{{{dps|{{#invoke:HeroData|get_hero_var|{{#var:hero_key_or_en}}|DPS|2}} }}}}}
|-
|-
! style="color: #999999; background-color: #2F2F2F" | Bullet Damage
! style="color: #999999; background-color: #2F2F2F" | Bullet Damage
| {{Icon/Brown|[[File:Bullet damage.png|20px|link=Bullet Damage]]|{{{bullet_damage}}}}}
| {{Icon/Brown|[[File:Bullet damage.png|20px|link=Bullet Damage]]|{{{bullet_damage|{{#invoke:HeroData|get_hero_var|{{#var:hero_key_or_en}}|BulletDamage|3}}}}}}}
|-
|-
! style="color: #999999; background-color: #2F2F2F" | Ammo
! style="color: #999999; background-color: #2F2F2F" | Ammo
| {{Icon/Grey|[[File:Clip size icon.png|20px|link=Ammo]]|{{{ammo}}}}}
| {{Icon/Grey|[[File:Clip size icon.png|20px|link=Ammo]]|{{{ammo|{{#invoke:HeroData|get_hero_var|{{#var:hero_key_or_en}}|ClipSize|3}}}}}}}
|-
|-
! style="color: #999999; background-color: #2F2F2F" | Bullets per sec
! style="color: #999999; background-color: #2F2F2F" | Bullets per sec
| {{Icon/Grey|[[File:Bullets per sec icon.png|20px|link=Fire Rate]]|{{{bullets_per_sec}}}}}
| {{Icon/Grey|[[File:Bullets per sec icon.png|20px|link=Fire Rate]]|{{{bullets_per_sec|{{#invoke:HeroData|get_hero_var|{{#var:hero_key_or_en}}|RoundsPerSecond|3}}}}}}}
|-
|-
! style="color: #999999; background-color: #2F2F2F" | Reload Time
! style="color: #999999; background-color: #2F2F2F" | Reload Time
| {{Icon/Grey|[[File:AttributeIconReloadTime.png|20px|link=Reload Time]]|{{{reload_time}}} s}}
| {{Icon/Grey|[[File:AttributeIconReloadTime.png|20px|link=Reload Time]]|{{{reload_time|{{#invoke:HeroData|get_hero_var|{{#var:hero_key_or_en}}|ReloadTime|3}}}}}&ThinSpace;s}}
|-
|-
! style="color: #999999; background-color: #2F2F2F" | Bullet Velocity
! style="color: #999999; background-color: #2F2F2F" | Bullet Velocity
| {{Icon/Grey|[[File:AttributeIconBulletSpeed.png|20px|link=Bullet Velocity]]|{{{bullet_velocity}}} m/s}}
| {{Icon/Grey|[[File:AttributeIconBulletSpeed.png|20px|link=Bullet Velocity]]|{{{bullet_velocity|{{#invoke:HeroData|get_hero_var|{{#var:hero_key_or_en}}|BulletSpeed|3}}}}}&ThinSpace;m/s}}
|-
|-
! style="color: #999999; background-color: #2F2F2F" | Light Melee
! style="color: #999999; background-color: #2F2F2F" | Light Melee
| {{Icon/Brown|[[File:Melee damage.png|20px|link=Melee attack#Light]]|{{{light_melee}}}}}
| {{Icon/Brown|[[File:Melee damage.png|20px|link=Melee attack#Light]]|{{{light_melee|{{#invoke:HeroData|get_hero_var|{{#var:hero_key_or_en}}|LightMeleeDamage|3}}}}}}}
|-
|-
! style="color: #999999; background-color: #2F2F2F" | Heavy Melee
! style="color: #999999; background-color: #2F2F2F" | Heavy Melee
| {{Icon/Brown|[[File:Melee damage.png|20px|link=Melee attack#Heavy]]|{{{heavy_melee}}}}}
| {{Icon/Brown|[[File:Melee damage.png|20px|link=Melee attack#Heavy]]|{{{heavy_melee|{{#invoke:HeroData|get_hero_var|{{#var:hero_key_or_en}}|HeavyMeleeDamage|3}}}}}}}
|-
|-
! style="color: #999999; background-color: #2F2F2F" | Falloff Range
! style="color: #999999; background-color: #2F2F2F" | Falloff Range
| {{Icon/Brown||{{{range}}}}}
| {{Icon/Brown||{{{range|{{#invoke:HeroData|get_hero_var|{{#var:hero_key_or_en}}|FalloffStartRange|2}}&ThinSpace;m → {{#invoke:HeroData|get_hero_var|{{#var:hero_key_or_en}}|FalloffEndRange|2}}&ThinSpace;}}}m}}
|-
|-
! colspan="2" style="background-color: #74b01c; font-weight: bold; font-size: 17px; font-family: 'Retail Demo', 'PT Serif','Palatino','Georgia',serif; font-weight: bold; text-shadow: 0px 2px 4px black, 1px 1px 2px black, 0px 0px 1px black; color:#FFEFD7; border-bottom: none"  | [[Stats#Vitality|<span style="font-weight: bold; text-shadow: 0px 2px 4px black, 1px 1px 2px black, 0px 0px 1px black; color:#FFEFD7; border-bottom: none"">Vitality</span>]]
! colspan="2" style="background-color: #74b01c; font-weight: bold; font-size: 17px; font-family: 'Retail Demo', 'PT Serif','Palatino','Georgia',serif; font-weight: bold; text-shadow: 0px 2px 4px black, 1px 1px 2px black, 0px 0px 1px black; color:#FFEFD7; border-bottom: none"  | [[Stats#Vitality|<span style="font-weight: bold; text-shadow: 0px 2px 4px black, 1px 1px 2px black, 0px 0px 1px black; color:#FFEFD7; border-bottom: none"">Vitality</span>]]
|-
|-
! style="color: #999999; background-color: #2F2F2F" | Health
! style="color: #999999; background-color: #2F2F2F" | Health
| {{Icon/Grey|[[File:Extra Health.png|20px|link=Health]]|{{{max_health}}}}}
| {{Icon/Grey|[[File:Extra Health.png|20px|link=Health]]|{{{max_health|{{#invoke:HeroData|get_hero_var|{{#var:hero_key_or_en}}|MaxHealth|3}}}}}}}
|-
|-
! style="color: #999999; background-color: #2F2F2F" | Health Regen
! style="color: #999999; background-color: #2F2F2F" | Health Regen
| {{Icon/Grey|[[File:Health regen.png|20px|link=Health Regen]]|{{{health_regen}}}}}
| {{Icon/Grey|[[File:Health regen.png|20px|link=Health Regen]]|{{{health_regen|{{#invoke:HeroData|get_hero_var|{{#var:hero_key_or_en}}|BaseHealthRegen|2}}}}}}}
|-
|-
! style="color: #999999; background-color: #2F2F2F" | Bullet Resist
! style="color: #999999; background-color: #2F2F2F" | Bullet Resist
| {{Icon/Grey|[[File:Bullet Armor.png|20px|link=Bullet Resist]]|{{{bullet_resist}}}%}}
| {{Icon/Grey|[[File:Bullet Armor.png|20px|link=Bullet Resist]]|{{{bullet_resist|{{#invoke:HeroData|get_hero_var|{{#var:hero_key_or_en}}|BulletResist|3}}}}}%}}
|-
|-
! style="color: #999999; background-color: #2F2F2F" | Spirit Resist
! style="color: #999999; background-color: #2F2F2F" | Spirit Resist
| {{Icon/Grey|[[File:Spirit Armor.png|20px|link=Spirit Resist]]|{{{spirit_resist}}}%}}
| {{Icon/Grey|[[File:Spirit Armor.png|20px|link=Spirit Resist]]|{{{spirit_resist|{{#invoke:HeroData|get_hero_var|{{#var:hero_key_or_en}}|TechResist|3}}}}}%}}
|-
|-
! style="color: #999999; background-color: #2F2F2F" | Move Speed
! style="color: #999999; background-color: #2F2F2F" | Move Speed
| {{Icon/Grey|[[File:Move speed.png|20px|link=Move Speed]]|{{{move_speed}}} m/s}}
| {{Icon/Grey|[[File:Move speed.png|20px|link=Move Speed]]|{{{move_speed|{{#invoke:HeroData|get_hero_var|{{#var:hero_key_or_en}}|MaxMoveSpeed|2}}}}}&ThinSpace;m/s}}
|-
|-
! style="color: #999999; background-color: #2F2F2F" | Sprint Speed
! style="color: #999999; background-color: #2F2F2F" | Sprint Speed
| {{Icon/Grey|[[File:Move speed.png|20px|link=Move Speed]]|{{{sprint_speed}}} m/s}}
| {{Icon/Grey|[[File:Move speed.png|20px|link=Move Speed]]|{{{sprint_speed|{{#invoke:HeroData|get_hero_var|{{#var:hero_key_or_en}}|SprintSpeed|2}}}}}&ThinSpace;m/s}}
|-
|-
! style="color: #999999; background-color: #2F2F2F" | Stamina
! style="color: #999999; background-color: #2F2F2F" | Stamina
| {{Icon/Grey|[[File:Springy_boots_icon.png|20px|link=Stamina]]|{{{stamina}}}}}
| {{Icon/Grey|[[File:Springy_boots_icon.png|20px|link=Stamina]]|{{{stamina|{{#invoke:HeroData|get_hero_var|{{#var:hero_key_or_en}}|Stamina|2}}}}}}}
|-
|-
! colspan="2" style="background-color: #c288f0; font-weight: bold; font-size: 17px; font-family: 'Retail Demo', 'PT Serif','Palatino','Georgia',serif; font-weight: bold; " | [[Level#Boons from Patron|<span style="font-weight: bold; text-shadow: 0px 2px 4px black, 1px 1px 2px black, 0px 0px 1px black; color:#FFEFD7; border-bottom: none"">Power Increases</span>]]
! colspan="2" style="background-color: #c288f0; font-weight: bold; font-size: 17px; font-family: 'Retail Demo', 'PT Serif','Palatino','Georgia',serif; font-weight: bold; " | [[Level#Boons from Patron|<span style="font-weight: bold; text-shadow: 0px 2px 4px black, 1px 1px 2px black, 0px 0px 1px black; color:#FFEFD7; border-bottom: none"">Power Increases</span>]]

Revision as of 03:18, 19 October 2024

Abrams
[[File:{{{card}}}|200px|alt={{{BASEPAGENAME}}}]]
Initial Stats
Weapon
""
DPS Hero Not Found
Bullet Damage Hero Not Found
Ammo

Hero Not Found

Bullets per sec

Hero Not Found

Reload Time

Hero Not Found s

Bullet Velocity

Hero Not Found m/s

Light Melee Hero Not Found
Heavy Melee Hero Not Found
Falloff Range Hero Not Found m → Hero Not Found m
Vitality
Health

Hero Not Found

Health Regen

Hero Not Found

Bullet Resist

Hero Not Found%

Spirit Resist

Hero Not Found%

Move Speed

Hero Not Found m/s

Sprint Speed

Hero Not Found m/s

Stamina

Hero Not Found

Power Increases
+{{{increase1_value}}} {{{increase1_stat}}}
+{{{increase2_value}}} {{{increase2_stat}}}
+{{{increase3_value}}} {{{increase3_stat}}}
Template documentation [view] [edit] [history] [purge]
Abrams
{{{BASEPAGENAME}}}
Initial Stats
Weapon
"Case Closed"
DPS 70
Bullet Damage 4.68+0.25
Ammo

9

Bullets per sec

1.67

Reload Time

0.353 s

Bullet Velocity

610 m/s

Light Melee 63+2.67
Heavy Melee 116+4.91
Falloff Range 20 m → 46 m
Vitality
Health

570+34

Health Regen

1

Bullet Resist

0%

Spirit Resist

0%

Move Speed

6.8 m/s

Sprint Speed

0 m/s

Stamina

3

Power Increases
+{{{increase1_value}}} {{{increase1_stat}}}
+{{{increase2_value}}} {{{increase2_stat}}}
+{{{increase3_value}}} {{{increase3_stat}}}

Template fills in most parameters in infobox automatically with data from Data:HeroData.json. You need to put hero's code name or their capitalized name in English in "key" parameter first.

For example this "key" fills infobox with data for Ivy

|key = hero_tengu

or

|key = Ivy

Infobox for heroes.

Template parameters[Edit template data]

This template prefers block formatting of parameters.

ParameterDescriptionTypeStatus
keykey

Autofills table contents

Suggested values
hero_atlas hero_bebop hero_dynamo hero_orion hero_haze hero_inferno hero_tengu hero_kelvin hero_ghost hero_lash hero_forge hero_mirage hero_krill hero_chrono hero_synth hero_gigawatt hero_shiv hero_hornet hero_viscous hero_warden hero_wraith hero_yamato hero_astro hero_nano hero_wrecker hero_kali hero_cadence
Stringrequired
cardcard

Adds hero's portrait

Example
Abrams card.png
Unknownrequired
iconicon

no description

Unknownoptional
namename

no description

Unknownoptional
weapon_nameweapon_name

no description

Unknownoptional
dpsdps

no description

Unknownoptional
bullet_damagebullet_damage

no description

Unknownoptional
ammoammo

no description

Unknownoptional
bullets_per_secbullets_per_sec

no description

Unknownoptional
reload_timereload_time

no description

Unknownoptional
bullet_velocitybullet_velocity

no description

Unknownoptional
light_meleelight_melee

no description

Unknownoptional
heavy_meleeheavy_melee

no description

Unknownoptional
rangerange

no description

Unknownoptional
max_rangemax_range

For Bebop

Unknownoptional
max_healthmax_health

no description

Unknownoptional
health_regenhealth_regen

no description

Unknownoptional
bullet_resistbullet_resist

no description

Unknownoptional
spirit_resistspirit_resist

no description

Unknownoptional
move_speedmove_speed

no description

Unknownoptional
sprint_speedsprint_speed

no description

Unknownoptional
staminastamina

no description

Unknownoptional
no_spirit_resistno_spirit_resist

Removes spirit resist from the table

Suggested values
true
Unknownsuggested
no_bullet_resistno_bullet_resist

Removes bullet resist from the table

Suggested values
true
Unknownsuggested
no_sprintno_sprint

Removes sprint speed from the table

Suggested values
true
Unknownsuggested
has_max_rangehas_max_range

Adds max range parameter (for Bebop)

Suggested values
true
Unknownoptional
no_summaryno_summary

Disables summary

Suggested values
true
Unknownoptional