Damage: Difference between revisions

From Heroes 3 wiki
Jump to navigation Jump to search
mNo edit summary
mNo edit summary
Line 18: Line 18:
|+ <big>'''Table 1: Damage calculation variables'''</big>
|+ <big>'''Table 1: Damage calculation variables'''</big>
|- bgcolor={{Grey 1}}  
|- bgcolor={{Grey 1}}  
! {{-}}Variable{{-}}
! {{-}}Range{{-}}
! {{-}}Description{{-}}
! {{-}}Description{{-}}
|-  
|-  
| {{-}}I<sub>1</sub>
| {{-}}I<sub>1</sub>&thinsp;&thinsp; = 0.05 &times; [[Attack]] - [[Defense]] (if A ≥ D)
| {{-}}0,00...3,00{{-}}
| {{-}}Only if AD-ratio is positive
|-
|-
| {{-}}I<sub>2</sub>
| {{-}}I<sub>2</sub>&thinsp;&thinsp; = 0.10, 0.25, 0.50 for basic, advanced, expert [[Archery]]<br>
| {{-}}0,00...0.50
&ensp;&thinsp;&thinsp;&thinsp;&thinsp;&thinsp;&thinsp;&thinsp;= 0.10, 0.20, 0.30 for basic, advanced, expert [[Offense]]{{-}}
| {{-}}Secondary skill bonus from Archery of Offense. {{-}}
|-
|-
| {{-}}I<sub>3</sub>
| {{-}}I<sub>3</sub>&thinsp;&thinsp; = 0.05 &times; I<sub>2</sub> &times; hero level for Archery/Offense [[Hero_specialty#Secondary_skill_specialties|specialty]]
| {{-}}0,00..2,475{{-}}
| {{-}}Hero specialty bonus
|-
|-
| {{-}}I<sub>4</sub>
| {{-}}I<sub>4</sub>&thinsp;&thinsp; = 1.00 for [[luck]]y strikes
| {{-}}0.00 or 1.00
| {{-}}Bonus from lucky strike
|-
|-
| {{-}}I<sub>5</sub>
| {{-}}I<sub>5</sub>&thinsp;&thinsp; = 1.00 for [[Death Blow]], [[Ballista]] double damage<br>
| {{-}}special
&emsp;&thinsp;&thinsp;&thinsp;&thinsp;= 1.00 if [[Elemental]] attacks opposite [[Elemental]] type<br>
| {{-}}Creature specialty bonus
&emsp;&thinsp;&thinsp;&thinsp;&thinsp;= 0.50 for [[hate]];<br>
&emsp;&thinsp;&thinsp;&thinsp;&thinsp;= 0.05 &times; [[hex]]es travelled for [[Cavalier]]s, [[Champion]]s
|-
|-
| {{-}}R<sub>1</sub>
| {{-}}R<sub>1</sub> = 0.025 &times; [[Defense]] - [[Attack]] (if D ≥ A)
| {{-}}0,00...0,15
| {{-}}Opponent's Armorer reduction
|-
|-
| {{-}}R<sub>2</sub>
| {{-}}R<sub>2</sub> = 0.05, 0.10, 0.15 for basic, advanced, expert [[Armorer]]
| {{-}}0,00...0,7425{{-}}
| {{-}}Opponent's Armorer specialty reduction
|-
|-
| {{-}}R<sub>3</sub>
| {{-}}R<sub>3</sub> = 0.05 &times; R<sub>2</sub> &times; hero level for Armorer [[Hero_specialty#Secondary_skill_specialties|specialty]]
| {{-}}0,00...0,50
| {{-}}[[Air Shield]] or [[Shield]] affecting the defender
|-
|-
| {{-}}R<sub>4</sub>
| {{-}}R<sub>4</sub> = 0.15 for [[Shield]], 0.30 at advanced, expert level<br>
| {{-}}0,00 or 0,50
&emsp;&ensp;&thinsp;= 0.25 for [[Air Shield]], 0.50 at advanced, expert level<br>
| {{-}}Range or melee penalty affecting the attacker.{{-}}
&emsp;&ensp;&thinsp;= 0.50 for shooter with (basic) [[Forgetfulness]]
|-
|-
| {{-}}R<sub>5</sub>
| {{-}}R<sub>5</sub> = 0.50 if attacker has [[range penalty|range]] or [[melee penalty]]{{-}}
| {{-}}0,00 or 0,50
| {{-}}Target is behind a wall.{{-}}
|-
|-
| {{-}}R<sub>6</sub>
| {{-}}R<sub>6</sub> = 0.50 if target is behind a wall ([[obstacle penalty]]){{-}}
| {{-}}0,00 or 0,50
| {{-}}Defender is [[Petrify|petrified]]
|-
|-
| {{-}}R<sub>7</sub>
| {{-}}R<sub>7</sub> = 0.50 if defender is [[Petrify|petrified]]
| {{-}}0,00...0.75
| {{-}}Target retaliates from [[Blind]]ed state
|-
|-
| {{-}}R<sub>8</sub>
| {{-}}R<sub>8</sub> = 0.50 for retaliation after being [[Blind]]ed<br>
| special
&emsp;&ensp;&thinsp;= 0.75 for retaliation after advanced [[Blind]]
| Creature specialty reduction
|-
| {{-}}R<sub>9</sub> = 0.50 for Psychic Elemental vs. [[mind spell]] immunity<br>
&emsp;&ensp;&thinsp;= 0.50 for Magic Elemental vs. full [[spell immunity]]<br>
&emsp;&ensp;&thinsp;= 0.75 for retaliation after being [[paralyze]]d
|}
|}



Revision as of 17:01, 19 July 2014

Damage is a general term for the amount of health loss a creature or a spell can cause to a single creature or to a creatures stack. If a creature suffers more damage than its current health, it is eliminated, while in a stack of creatures, the topmost dies. The remainder of the damage is dealt to the next one and so forth until all damage is dealt or the whole stack is eliminated.

Creature's ability to deal damage typically has a range, which means that it causes randomly chosen damage between the minimum and maximum value. Some creatures like Nagas do not have a damage treshold meaning they always do the same amount of damage. Creatures in a stack cause individual damages, and the combined damage of the stack is calculated by adding them together. However, the final damage can deviate from the combined damage greatly because of different additions and reductions, which are covered in the next section.

Spells can deal damage much like creatures do, except that the amount of inflicted damage does not vary within a range but is fixed. The exact amount of unmodified spell damage can always be calculated with a linear formula. For example, basic Lightning Bolt cast by a hero with 7 spell power does 7 × 25 + 10 = 185 damage. For other spells different values than 25 and 10 need to be substituted. The eventual amount of spell damage is modified as follows:

Damage calculation of creature stacks

The damage calculation formula

Table 1: Damage calculation variables
 Description 
 I1   = 0.05 × Attack - Defense (if A ≥ D)
 I2   = 0.10, 0.25, 0.50 for basic, advanced, expert Archery

        = 0.10, 0.20, 0.30 for basic, advanced, expert Offense 

 I3   = 0.05 × I2 × hero level for Archery/Offense specialty
 I4   = 1.00 for lucky strikes
 I5   = 1.00 for Death Blow, Ballista double damage

     = 1.00 if Elemental attacks opposite Elemental type
     = 0.50 for hate;
     = 0.05 × hexes travelled for Cavaliers, Champions

 R1 = 0.025 × Defense - Attack (if D ≥ A)
 R2 = 0.05, 0.10, 0.15 for basic, advanced, expert Armorer
 R3 = 0.05 × R2 × hero level for Armorer specialty
 R4 = 0.15 for Shield, 0.30 at advanced, expert level

   = 0.25 for Air Shield, 0.50 at advanced, expert level
   = 0.50 for shooter with (basic) Forgetfulness

 R5 = 0.50 if attacker has range or melee penalty 
 R6 = 0.50 if target is behind a wall (obstacle penalty
 R7 = 0.50 if defender is petrified
 R8 = 0.50 for retaliation after being Blinded

   = 0.75 for retaliation after advanced Blind

 R9 = 0.50 for Psychic Elemental vs. mind spell immunity

   = 0.50 for Magic Elemental vs. full spell immunity
   = 0.75 for retaliation after being paralyzed

Mathematical formula for calculating the final damage is:

DMGt = DMGb × (1 + I1 + I2 + I3 + I4 + I5) × (1 - R1)×(1 - R2)×(1 - R3)×(1 - R4)×(1 - R5)×(1 - R6)×(1 - R7)×(1 - R8)

Variables are denoted as I if they (I)ncrease damage and as (R) if they (R)educe it (see also Table 1). I1 and R1 are mutually exclusive, but all other variables may simultaneously affect Total damage (DMGt). Note that all variables are merely modifiers of base damage (DMGb), meaning that the number of attacking creatures and their damage range remain the primary determinants of total damage. To summarize the above formula, every damage bonus is calculated as a percentage of the base damage to which it is then added, and every damage penalty then multiplies this amount with a number between 0 and 1.

Attack to defense ratio – variables I1 and R1

Besides the actual damage range of the creature type, the most influential variables are I1 and R1. They represent so called attack to defense ratio (AD-ratio), which is calculated from the difference of the attacker's attack value and the defender's defese value. They are determined by adding up attack skills of the attacking hero and attacking creature type, and by adding up defense skill of the defending hero and defending creature type. Also spells affecting attack or defense values are taken into account in this part of the formula.

If the attacking creature's combined attack value is higher than defending creature's combined defense value, in other words if the difference is positive, then the attacking creature recieves +5% increase to its damage for every point the attack value is higher up to 60 points. If the difference is negative, then the attacking creature recieves -2.5% penalty for its damage for every point the attck value is lower up to 28 points. When the difference is positive, it increases the damage and is taken into account with the variable I1. If it is negative, then it reduces the damage and is taken into account in R1. This means that if the difference is positive, R1 is 0, and the otherway round. If the difference is 0, then both variables are 0.

In practice this means, that if the attacker's combined attack skill value is greater than the defenders combined defense skill value, the attacker may recieve up to +300% increase to its damage. Then again, if the attack value is smaller, the attacker may recieve -70% reduction to the final damage. It should be noted, that there has been some confusion wheter the bonus cap is 300% or 400%. To clarify this issue, the bonus is +300% but the damage is 400% compared to non-modified damage. To phrase the same question mathematically, bonus of +300% is "1 + 1 × 3.00" and the damage of 400% is "1 × 4.00" – in the end, they are equivalent.

Secondary skill factors – variables I2 and I3 =

Variable I2 is related to secondary skills Archery and Offense, and A3 to heroes who specialize in them: Orrin, Gundula and Crag Hack. Archery and Offense cannot affect at the same time, because they are related to range and melee attacks (respectively). For ranged attacks, Archery secondary skill may give 0, 0.10, 0.25 or 0.50 depending on whether the hero has the skill and on what level the skill is. Similarly, Offense may give 0, 0.10, 0.20 or 0.30 to melee attacks.

Three heroes specialize in Archery or Offense. Orrin has Archery as a specialty while Gundula and Crag Hack has Offense. They recieve additional bonus from Archery or Offense secondary skill, that is calculated with the formula:

I3 = 0.05 × hero level × I2

As can be seen from the formula, the specialty bonus requires that the hero has the appropriate secondary skill, otherwise A1 will become 0, which leads to that A2 will be 0 as well. In other words, Orrin does not recieve his specialty bonus if he does not have Archery secondary skill; same applies to Gundula and Crag Hack with Offense. By default these heroes start with an appropriate secondary skill, but in custom maps the map-maker may change the starting skills.

Additionally, Adela and her specialty to Bless spell is a special case of variable A2. When creature stack blessed by Adela attacks, it recieves an additional damage from her specialty, that can be calculated with the formula:

SP = 0.03 × hero level ÷ creature level

Because of the division, Adela's Bless bonus is higher to low-tier creatures. First level creatures will recieve +3% bonus to damage per Adela's level, while fifth level creatures only recieve +0.6% bonus per Adela'a level.

Luck as combat modifier – variable A3

Luck variable may be either 0 or 1.00 depending if the attacking creatures gets "a lucky strike". Luck is a combat variable, that may be 0, +1, +2 or +3, which all give a different probability for luck to occur. Verbal descriptions for variables are postivie (+1), good (+2) and excellent (+3). Respectively the probabilities are 1/24 (4.17%), 1/12 (8.33%) and 1/8 (12.5%) for the lucky strike. Players may affect the luck with artifacts, adventure map locations, spells and Luck secondary skill.

Creature abilities – variable A4

Creature variable C is the last variable capable of increasing the final damage. Cavaliers and Champions have special ability to recieve jousting bonus when they attack. This gives them bonus which is calculated with the formula:

C = 0.05 × squares travelled

Dread Knights may cause Death Blow attack, which gives variable C value 1.00. Similarly, if Ballista causes double damage, the value variable C receives value of 1.00. Additionally, there are few creatures who hate another creature, and that gives C a value of 0.50.

Defense variables

Secondary skill factors – variables D1 and D2

Similarly to attac variables, D1 and D2 are related to secondary skill and heros who specialize in them. The difference is, that secondary skill, Armorer reduces both melee and ranged damage. Three heroes specialize in Armorer: Mephala, Neela and Tazar. Armorer may give variable D1 values 0.05, 0.10 or 0.15. Heroes with Armorer specialty recieve additional bonus, which is calculated with the formula:

D2 = 0.05 × hero level × D1

Again, the specialty bonus requires that the hero has Armorer secondary skill, otherwise the bonus will be 0. By default Mephala, Neela and Tazar start with Armorer, but in custom maps the map-maker may change the starting skills.

Ohter factors – variables D3, D4, D5, D6, D7

  • Spells
    • Shield
    • Air Shield
  • Attack penalties:
    • Range or obstacle
    • Melee penalty
  • Petrified
  • Retaliate from blindness
  • Creatures
    • Attacker is Psychic Elemental, defender is immune to Mind spells
    • Attacker is Magic Elemental, defender is Magic Elemental or the Black Dragon

Examples

No heroes are assumed to be present in the battle.

  • 2 Nagas attack a stack of Pikemen.
  • The Nagas have a single unit damage value of 20 and their Attack skill is 16.
  • A Pikeman has 10 health and their Defense skill is 5.
  • The base stack damage done by the stack of Nagas is 2 * 20 = 40.
  • The Pikemen's Defense skill (5) is subtracted from the Nagas' Attack skill (16), which gives us 11, giving the nagas an att/def damage bonus.
  • The dealt damage will after the att/def consideration thusly have the bonus percentage modificator of 5%, multiplied with the damage bonus number in this case, 11, resulting in 55% bonus percentage of the Nagas damage towards the Pikemen.
  • So the damage is increased by a 55% increase and the nagas through superior attack skill have 155% damage on the Pikemen stack.
  • The total damage thus is 40 * 1.55 = 62 damage points.
  • 6 Pikemen will be killed, and the top Pikemen of the remaining stack will have 8 health left.

When the remaining (if any) Pikemen (attack points of 4) attack the nagas (sporting 13 points of defense):

  • -22.5% damage would be dealt by the Pikemen to the 5 creature level higher naga chimera stack.
  • The difference between the Pikemen attack (4) and the nagas defense (13) would mean 9 malus points with a malus point resulting in 2.5 % each malus point (the half of the bonus points).
  • ((2.5)*-9)% is -22.5% damage the Pikemen can damage the nagas with.