Difference between revisions of "Template:Hero infobox"
Kroocsiogsi (talk | contribs) m (Try to hunt down some whitespace issues) |
Kroocsiogsi (talk | contribs) (Add "released" parameter) |
||
Line 533: | Line 533: | ||
|sight range day=sight range day |
|sight range day=sight range day |
||
|sight range night=sight range night |
|sight range night=sight range night |
||
+ | }}<!-- |
||
+ | |||
+ | Set "released" to "true" by default, but allow it to be overridden. |
||
+ | |||
+ | -->{{#ifeq: {{{released}}} | false |
||
+ | |[[released::false| ]] |
||
+ | |[[released::true| ]] |
||
}}<!-- |
}}<!-- |
||
Revision as of 05:50, 15 May 2012
Template:Translation switching
The Hero infobox is used within hero pages to quickly convey core information, such as a hero's strength, agility, intelligence, or more specific information such as their movement speed or sight range.
Should use {{Hero infobox wrapper}}
for translation.
Usage
| |||||||||||||||||||||||||||
![]() | |||||||||||||||||||||||||||
| |||||||||||||||||||||||||||
| |||||||||||||||||||||||||||
| |||||||||||||||||||||||||||
|
To implement the infobox, you simply add {{Hero infobox}}
to the top of a page - however there are numerous attributes that display by default and should be set.
To set attributes, you simply add a few lines before closing the template call (before the closing squiggly brackets - }}
), and add each attribute and it's values with | attribute = value
.
Here's the code you should copy and fill in for each Hero page:
{{Hero infobox | title = | icon = | image = | primary attribute = | strength = | strength growth = | agility = | agility growth = | intelligence = | intelligence growth = | attack damage min = | attack damage max = | health regen = | armor = | magic resistance = | movement speed = | turn rate = | attack range = | range type = | attack point = | attack backswing = | base attack time = | projectile speed = | sight range day = | sight range night = | collision size = | legs = | gib type = }}
Attributes
Attribute | Description |
---|---|
Note: Health, mana, mana regeneration and attacks per second are all calculated automatically. | |
faction | The team a hero is affiliated with. Radiant, Dire, or Neutral. Defaults to Neutral. |
primary attribute | A hero's primary attribute - strength, intelligence, or agility. |
strength | A hero's base strength value. |
strength growth | The rate at which a hero's strength increases. |
agility | A hero's base agility value. |
agility growth | The rate at which a hero's agility increases. |
intelligence | A hero's base intelligence. |
intelligence growth | The rate at which a hero's intelligence increases. |
attack damage min | A hero's minimum base attack damage (level 1, 15 and 25 are calculated automatically). |
attack damage max | A hero's maximum base attack damage (level 1, 15 and 25 are calculated automatically). |
health regen | A hero's base health regeneration, defaults to 0.25 if no value is given (level 1, 15 and 25 are calculated automatically). |
mana regen | A hero's base mana regeneration, defaults to 0.01 if no value is given (level 1, 15 and 25 are calculated automatically). |
armor | A hero's base armor (level 1, 15 and 25 are calculated automatically). |
magic resistance | A hero's magic resistance. Normally 25%. |
movement speed | A hero's base movement speed. |
turn rate | The rate which determines how long a hero needs to turn 180°. |
attack range | The range in which a hero can attack. Most melee heroes have an attack range of 128. |
attack point | The length of the animation just before an attack. |
attack backswing | The length of the animation just after an attack. |
base attack time | Base Attack Time: the period at which a hero attacks. |
projectile speed | The speed at which a hero's projectile travels. Do not add this parameter to melee heroes. It defaults to "Instant". |
sight range day | The range in which a hero sees during the day. |
sight range night | The range in which a hero sees during the night. |
collision size | The amount of space that a hero takes up. Most heroes have a collision size of 24. |
There is an optional attribute that is only necessary when including this template on a page that is not a Hero page, and should not be set when this template is used on a Hero page.
Attribute | Description |
---|---|
title | The English name of the hero. (On hero pages, the name of the hero will be deduced from BASEPAGENAME if not given.) |
game | See Template:Unit infobox. |
structure | See Template:Unit infobox. |
Custom game support
Since custom games may have differently scaling stats, the template supports customizing stats like health, mana, armor, attack damage, etc gain per attribute point.
Do not use these properties on the default Dota2 hero pages. They are set automatically for them.
Attribute | Description |
---|---|
health | Customize the base health amount (default: 200) |
custom bonus health | Customize the health gain per strength point (default: 20) |
custom bonus health regen | Customize the health regen gain per strength point (default: 0.1) |
mana | Customize the base mana amount (default: 75) |
custom bonus mana | Customize the mana gain per intelligence point (default: 12) |
custom bonus mana regen | Customize the mana regen gain per intelligence point (default: 0.05) |
custom bonus spell damage | Customize the spell damage bonus per intelligence point (default: 0.07%) |
custom bonus armor | Customize the armor bonus per agility point (default: 0.17) |
attack speed | Customize the base attack speed amount (default: 100) |
custom bonus attack speed | Customize the attack speed bonus per agility point (default: 1) |
custom bonus attack damage | Customize the attack damage bonus per primary attribute (default: 1) |
TemplateData
The Hero infobox is used within hero pages to quickly convey core information, such as a hero's strength, agility, intelligence, or more specific information such as their movement speed or sight range.
Parameter | Description | Type | Status | |
---|---|---|---|---|
Title | title | The English name of the hero.
| String | required |
Minimap Icon | icon | The hero's minimap icon.
| File | required |
Image | image | The hero's image.
| File | required |
Primary Attribute | primary attribute | A hero's primary attribute - strength, intelligence, or agility.
| String | required |
Strength | strength | A hero's base strength value.
| Number | required |
Strength Growth | strength growth | The rate at which a hero's strength increases.
| Number | required |
Agility | agility | A hero's base agility value.
| Number | required |
Agility Growth | agility growth | The rate at which a hero's agility increases.
| Number | required |
Intelligence | intelligence | A hero's base intelligence.
| Number | required |
Intelligence Growth | intelligence growth | The rate at which a hero's intelligence increases.
| Number | required |
Base Health | health | Customize the base health amount.
| Number | deprecated |
Custom Bonus Health | custom bonus health | Customize the health gain per strength point.
| Number | deprecated |
Base Mana | mana | Customize the base mana amount.
| Number | deprecated |
Custom Bonus Mana | custom bonus mana | Customize the mana gain per intelligence point.
| Number | deprecated |
Armor | armor | A hero's base armor (level 1, 15 and 25 are calculated automatically).
| Number | required |
Custom Bonus Armor | custom bonus armor | Customize the armor bonus per agility point.
| Number | deprecated |
Custom Bonus Spell Damage | custom bonus spell damage | Customize the spell damage bonus per intelligence point.
| Number | deprecated |
Attack Speed | attack speed | Customize the base attack speed amount.
| Number | deprecated |
Base Attack Time | base attack time | The period at which a hero attacks.
| Number | required |
Custom Bonus Attack Speed | custom bonus attack speed | Customize the attack speed bonus per agility point.
| Number | deprecated |
Minimum Attack Damage | attack damage min | A hero's minimum base attack damage (level 1, 15 and 25 are calculated automatically).
| Number | required |
Maximum Attack Damage | attack damage max | A hero's maximum base attack damage (level 1, 15 and 25 are calculated automatically).
| Number | required |
Custom Bonus Attack Damage | custom bonus attack damage | Customize the attack damage bonus per primary attribute.
| Number | deprecated |
Magic Resistance | magic resistance | A hero's magic resistance.
| Number | required |
Health Regeneration | health regen | A hero's base health regeneration (level 1, 15 and 25 are calculated automatically).
| Number | required |
Mana Regeneration | mana regen | A hero's base mana regeneration (level 1, 15 and 25 are calculated automatically).
| Number | required |
Movement Speed | movement speed | A hero's base movement speed.
| Number | required |
Turn Rate | turn rate | The rate which determines how long a hero needs to turn 180°.
| Number | required |
Day Vision | sight range day | The range in which a hero sees during the day.
| Number | required |
Night Vision | sight range night | The range in which a hero sees during the night.
| Number | required |
Attack Range | attack range | The range in which a hero can attack. Most melee heroes have an attack range of 128.
| Number | required |
Range Type | range type | The hero's range type (Melee/Ranged).
| String | required |
Projectile Speed | projectile speed | The speed at which a hero's projectile travels. Do not add this parameter to melee heroes. It defaults to "Instant".
| Number | suggested |
Attack Point | attack point | The length of the animation just before an attack.
| Number | required |
Attack Backswing | attack backswing | The length of the animation just after an attack.
| Number | suggested |
Collision Size | collision size | The amount of space that a hero takes up. Most heroes have a collision size of 24.
| Number | required |
Legs | legs | The amount of leg's the hero has.
| Number | suggested |
Gib type | gib type | The heroes gib type. Used for some animations.
| String | suggested |
Game | game | Specify when the unit is part of a custom or seasonal game. Defaults to empty (means the standard Dota 2 game). | String | optional |
Structure | structure | Specify how the infobox is related to the page. Defaults to main (means it is the main infobox of the page and all semantic properties will be included). If the infobox is not the main part of the page, define hidden.
| String | optional |