Skip to content

Posts from [Manuals] Damage Calculation

Manuals Closed Topic
No ratings yet — be the first to rate!
User Avatar
20 years ago
Auto-translated
Damage Calculation Manual

Part 1. Damage calculation for melee and ranged attacks.

When an attacking stack hits a targeted stack, a damage calculation process occurs. The formulas and rules used for this calculation are provided below.

Terms Used.
General:
Damage = damage.
Creature = creature.
Creature's stack = creature stack (stack).
HP = "hit points" (HP).

Creature parameters displayed on the stats screen:
Attack = creature's "attack" ("attack").
Defense = creature's "defense" ("defense").
Damage = creature's "damage" parameter.
MinDamage, MaxDamage = "min damage" and "max damage".

Hero parameters displayed on the stats screen:
Attack = hero's "attack".
Defense = hero's "defense".

Exact Damage Calculation Formula.
The exact formula for calculating damage is as follows:

TotalDamage = PhysicalDamage + ElementalDamage.

PhysicalDamage = NumCreatures * BaseDamage * AttackDefenseModifier * PhysicalModifiers

, where TotalDamage is the total stack damage;
PhysicalDamage is the "physical damage" of the stack (primary damage);
ElementalDamage is the additional "elemental damage" of the stack;
NumCreatures is the number of creatures in the attacking stack;
BaseDamage is the "base" damage of the creature in the attacking stack;
AttackDefenseModifier is the damage modifier based on "attack" and "defense";
PhysicalModifiers is the product of all "other" "physical damage" modifiers.

Detailed breakdown of formula components.

PhysicalDamage
The primary damage dealt by the attacking stack.

It depends on many parameters (see descriptions below).
After all calculations, "physical damage" is rounded down to the nearest integer.
Exception: if "physical damage" results in <1, it becomes =1.

NumCreatures
The number of creatures in the attacking stack.

BaseDamage
The "base" damage of the creature in the attacking stack.
Formula:
BaseDamage = "min damage" + random*("max damage"-"min damage"),

, where random is a real random number from 0 to 1;
"min damage" and "max damage" are creature characteristics: minimum and maximum base damage.

A creature's "min damage" and "max damage" characteristics can change due to various game components: hero abilities (e.g., Frenzy), artifacts (e.g., Necklace of the Bloody Claw), spells (e.g., Berserk), and others. The final characteristic values are displayed on the creature's stats screen—these are the values plugged into the BaseDamage calculation formula.

AttackDefenseModifier
A damage modifier based on the "attack" characteristic of the attacking stack and the "defense" characteristic of the targeted stack.

The formula consists of 2 parts:
If attacker's "attack" >= target's "defense", then
AttackDefenseModifier = 1+("attack"-"defense")*0.05.
If attacker's "attack" < target's "defense", then
AttackDefenseModifier = 1/(1+("defense"-"attack")*0.05).

There are no limits on the value of the difference between "attack" and "defense". (Such a limit existed in early stages of development—the modifier was limited to the range [0.1; 3.0]).

A creature's "attack" and "defense" characteristics can change due to various game components: hero "attack" and "defense" characteristics, hero specializations, creature abilities (e.g., Rider's Charge and Precise Shot), and others.

There are two types of modifiers: "additive" (e.g., hero "attack" and "defense") and "multiplicative" (e.g., Defend command, Marksman's Precise Shot ability). Order of application: additive first, then multiplicative.
After all calculations, the "attack" and "defense" characteristics are rounded down to the nearest integer.
The resulting "attack" and "defense" characteristics are plugged into the AttackDefenseModifier calculation formula.

PhysicalModifiers
The product of all "physical damage" modifiers.
Formula:
PhysicalModifiers = PhysicalModifier1 * PhysicalModifier2*...* PhysicalModifierN

, where PhysicalModifier1...PhysicalModifierN are multiplicative "physical damage" modifiers.

"Physical damage" modifiers (hereafter—"damage modifiers") include various modifiers from hero skills/abilities, creature abilities, artifacts, and other factors that affect the dealt physical damage by a percentage. Examples: hero Attack and Defense skills, Archery and Evasion abilities.

A full list of damage modifiers is provided in the corresponding section.

ElementalDamage
The "elemental damage" of the stack (additional damage).
Formula:
ElementalDamage = AdditionalElementalDamage1 + AdditionalElementalDamage2 + ... + AdditionalElementalDamageN

, where AdditionalElementalDamage1 ... AdditionalElementalDamageN are components of total elemental damage from various game mechanics.

"Elemental damage" is dealt in addition to "physical damage". It depends on various hero skills/abilities and creature capabilities.

In some cases, the damage from an "elemental damage" component may be equal to a certain percentage of "physical damage" (e.g., Cold Steel hero ability).
In other cases, it is completely independent of "physical damage" (e.g., Inferno-hero's Hellfire ability).

The damage value from an individual component (AdditionalElementalDamage) may be reduced if the targeted stack has protection/immunity to the "element" of that component (Water/Fire/Air/Earth).

A full list of "elemental damage" components is provided in the corresponding section.

Simplified General Damage Calculation Formula.
This formula omits some details but is more visual and convenient.

If attacking stack's "attack" > target's "defense", then:
"Total Damage" = "Base damage of 1 creature" * "Number of creatures in stack" * (1+("attack"-"defense")*0.05) * "Other damage modifiers"

If attacking stack's "attack" < target's "defense", then:
"Total Damage" = "Base damage of 1 creature" * "Number of creatures in stack" / (1+("defense"-"attack")*0.05) * "Other damage modifiers"

, where "Base damage of 1 creature" is a random number in the range ["min damage"; "max damage"];
"Other damage modifiers" is the product of all damage modifiers from skills, hero abilities, creature abilities, etc.

Damage Calculation Specifics for Ranged Attacks.
For stacks with ranged attacks (with the Shooter ability), there are several general damage modifiers:
1) If the targeted stack is within 6 cells, the damage modifier will be 1.0 (i.e., no damage bonuses).
2) If the targeted stack is further than 6 cells, the damage modifier will be 0.5 (-50% damage).
3) When performing a melee attack, a stack with the Shooter ability will have a damage modifier of 0.5 (-50% damage).

During sieges, castle walls do not affect dealt ranged damage.

The distance from shooter to target is calculated in exactly the same way as for moving stacks across the battlefield (1 for vertical/horizontal movement, 1.5 for diagonal).

There are a significant number of damage modifiers applied only to ranged attacks or only to melee attacks (from hero abilities, creature abilities, spells, artifacts, etc.). When describing such an ability/artifact/spell, it will be specified which type of attack (melee or ranged) the modifiers affect.
________________________________________
Influence of Various Game Components on Damage Calculation.

Core Game Mechanics.
Hero "attack" and "defense" parameters.
These parameters are additive modifiers to the creature's same-named parameters.

Defend Command.
If a stack performs the Defend command, its "defense" parameter modifier = 1.3 (+30% "defense").
There are exceptions to this general rule—the hero ability Hold Your Ground and the Ancient Treant's Take Roots ability (see below).

Luck.
When "positive" luck triggers, the damage modifier = 2.0 (+100% damage).
When "negative" luck triggers, the damage modifier = 0.5 (-50% damage).
With the Absolute Luck ability, "positive" luck always triggers (regardless of the creature's "luck" characteristic sign).

Hero Skills.
Attack.
Basic/Advanced/Expert levels provide a damage modifier = 1.05 / 1.1 / 1.15 (+5%/10%/15% damage) for melee attacks of all stacks in the hero's army.

Defense.
Basic/Advanced/Expert levels provide a damage modifier = 0.9 / 0.8 / 0.7 (-10%/20%/30% damage) when taking damage from melee attacks by all stacks in the hero's army.

Hero Abilities.
Archery (Attack skill).
Damage modifier = 1.2 (+20% damage) for ranged attacks of all stacks in the hero's army.

Evasion (Defense skill).
Damage modifier = 0.8 (-20% damage) when taking damage from ranged attacks by all stacks in the hero's army.

Stand Your Ground (Defense skill).
"Defense" parameter modifier = 1.6 (+60% "defense") when a stack from the hero's army performs the Defend command.
Special case—Ancient Treants with Take Roots ability. With Stand Your Ground, their "defense" parameter modifier = 2.0 (+100% "defense") when performing Defend.

Retribution (Attack skill).
If a stack's morale > 0, the damage modifier = (1+0.05*morale) (+5% damage per unit of morale) for melee and ranged attacks of all stacks in the hero's army.
If morale <= 0, the damage modifier = 1.0 (i.e., damage is unchanged).

Cold Steel (Attack skill).
Additional elemental damage = 0.1 * "physical damage" (+10% cold damage).
"Element" - Water (cold).
Works for both melee and ranged attacks.

Chilling Bones (Defense skill).
Any stack performing a melee attack against a stack with Chilling Bones receives elemental damage in return = 0.05 * "dealt physical damage" (5% retaliatory cold damage).
"Element" - Water (cold).
Damage from Chilling Bones is dealt every time the stack is hit and does not depend on the stack's retaliation attack.

Fiery Wrath (Destructive Magic skill).
Additional elemental damage = 0.1 * "physical damage" (+10% fire damage).
"Element" - Fire.
Works for both melee and ranged attacks.

Wall of Fog (Summoning Magic skill).
"Min damage" and "max damage" parameters are reduced by 10% for enemy army stacks with the Shooter ability.

Battle Frenzy (Attack skill).
Increases "min damage" and "max damage" parameters by +1 for all stacks in the hero's army.
Essentially, this increases a creature's "base damage" by 1.

Nature's Wrath (Attack skill).
Increases "max damage" parameter by +1 for all Sylvan faction creatures.

Elven Luck (Luck skill).
Damage modifier when "positive" luck triggers = 2.25 (+125% damage) for melee and ranged attacks.
When "negative" luck triggers, the damage modifier = 0.5 (-50% damage).

Creature Abilities.
Battle Dive (Imperial Griffin).
Damage modifier = 2.0 (+100% damage) when "diving" onto a targeted stack.

Fire Shield (Fire Elemental, Phoenix).
Any stack performing a melee attack against a stack with Fire Shield receives elemental damage in return = 0.2 * "dealt physical damage" (20% retaliatory fire damage).
"Element" - Fire.
Damage from Fire Shield is dealt every time the stack is hit and does not depend on the stack's retaliation attack.

Jousting (Cavalier, Paladin).
Damage modifier = 1+0.1*"number of cells moved before attack". (+10% damage per cell moved).

Large Shield (Footman, Squire).
Damage modifier = 0.5 (-50% damage) when taking damage from ranged attacks.

Lizard Bite (Grim Raider).
If a friendly stack attacks an enemy stack that is adjacent to a friendly Grim Raider stack, the Grim Raiders stack "supports" the attack and deals an additional hit with a damage modifier = 0.5 (-50% damage).

No Range Penalty (Mage, Archmage).
No damage penalty for ranged attacks at distances > 6 cells.

No Melee Penalty (Priest, Inquisitor, Titan, Scout, Assassin).
No standard shooter damage penalty during melee attacks.

Precise Shot (Marksman).
During a ranged attack, the target stack's final "defense" parameter is considered equal to 0 if the distance to it <= 3 cells.
Essentially, the target stack's "defense" parameter is completely ignored when firing at point-blank range.

Range Penalty (Scout, Assassin).
Damage modifier = 0.5 (-50% damage) when performing a ranged attack.

Rider Charge (Dark Raider, Grim Raider).
For every cell moved by the stack before hitting, 20% is subtracted from the target stack's "defense" parameter. However, the "defense" parameter cannot become <0.
Example: after moving 3 cells before hitting, the "defense" parameter decreases by 60%. After moving 5 or more cells, the "defense" parameter will be = 0.

Scatter Shot (Archer).
Fires in a 3x3 square, but the damage modifier will be = 0.5 (-50% damage).

Shield Allies (Squire).
All stacks on adjacent cells have a damage modifier = 0.5 (-50% damage) when taking damage from ranged attacks.

Take Roots (Ancient Treant).
Performing the Defend command gives a "defense" parameter modifier = 1.5 (+50% "defense"). (Instead of the usual modifier = 1.3).
Additionally grants the Unlimited Retaliation ability.
If the hero has the Stand Your Ground ability, performing the Defend command gives a "defense" parameter modifier = 2.0 (+100% "defense").

Vorpal Sword (Pit Lord).
Damage dealt by a stack with the Vorpal Sword ability will be increased by a constant value = to the "HP" parameter of the targeted stack's creature.
Essentially, 1 is first "subtracted" from the number of creatures in the target stack, and then normal damage is dealt.

Enraged (Footman, Squire, Horned Demon, Horned Overseer, Zombie, Plague Zombies, Treant, Ancient Treant, Stone Gargoyle, Obsidian Gargoyle, Hydra, Deep Hydra).
The stack's "attack" parameter increases by +1 with each death of a friendly stack.

Artifacts.
Unicorn Horn Bow ("Negates range penalties for all shooting units in hero's army").
Grants the "No Range Penalty" ability to all Shooter stacks in the hero's army.

Necklace of the Bloody Claw ("Adds +1 damage to all creatures in hero's army").
Increases "min damage" and "max damage" characteristics by 1 for all stacks in the hero's army.

Spells.
Weakness (Dark Magic).
Reduces a stack's "max damage" characteristic.
"max damage" = "min damage" + "spell effect"*("max damage"-"min damage").
"Spell effect" at None/Basic/Advanced/Expert levels of the Dark Magic school is 0.5 / 0.35 / 0.2 / 0.0.

Vulnerability (Dark Magic).
At None/Basic/Advanced/Expert levels of the Dark Magic school, it reduces a stack's "defense" characteristic by 3/4/5/6 points.

Suffering (Dark Magic).
At the None/Basic/Advanced/Expert level of the Dark Magic school, it reduces the stack's "attack" characteristic by 3/6/9/12 points.

Confusion (Dark Magic).
At the None/Basic/Advanced/Expert level of the Dark Magic school, it provides a damage modifier = 0.5 / 0.3 / 0.1 / 0.0 (-50%/70%/90%/100% damage) for ranged attacks and retaliation attacks of the stack.

Frenzy (Dark Magic).
Increases the stack's "min damage" and "max damage" characteristics.
"min damage" = "min damage"* (1+SpellPower*0.03).
"max damage" = "max damage"* (1+SpellPower*0.03).

Divine Strength (Light Magic).
Increases the stack's "min damage" characteristic.
"min damage" = "min damage" + "spell effect"*("max damage" - "min damage").
The "spell effect" at the None/Basic/Advanced/Expert level of the Light Magic school is 0.5 / 0.65 / 0.8 / 1.0.

Endurance (Light Magic).
At the None/Basic/Advanced/Expert level of the Light Magic school, it increases the stack's "defense" characteristic by 3/6/9/12 points.

Righteous Might (Light Magic).
At the None/Basic/Advanced/Expert level of the Light Magic school, it increases the stack's "attack" characteristic by 3/6/9/12 points.

Deflect Missile (Light Magic).
At the None/Basic/Advanced/Expert level of the Light Magic school, it provides a damage modifier = 0.75 / 0.6 / 0.45 / 0.3 (-25%/40%/55%/70% damage) when the stack receives damage from ranged attacks.

Arcane Armor (Summoning Magic).
At the None/Basic/Advanced/Expert level of the Summoning Magic school, it provides a damage modifier = 0.75 / 0.75 / 0.75 / 0.5 (-25%/25%/25%/50% damage) when the stack receives damage from any attacks.

Unique racial skills and abilities of heroes.

Skill Avenger (Ranger hero).
Upon successful triggering of this skill, the favored enemy will receive damage with a modifier of 2.0 (+100% damage).

Skill Counterstrike (Knight hero).
The Basic/Advanced/Expert/Ultimate skill level provides a damage modifier = 1.05 / 1.1 / 1.2 / 1.25 (+5%/10%/20%/25% damage) for "retaliation" melee attacks of all stacks in the hero's army.

Ability Benediction (Skill Counterstrike, Knight hero).
Upon activation, it grants +1 to "attack" and "defense" characteristics for all stacks in the hero's army.
Additionally, it grants +10% to "initiative" and +1 morale.
Duration = (2 + 0.25*hero_level) turns.

Elemental chains (Warlock hero).
Briefly and only regarding damage dealing.

Using "elemental chains," Warlock's army stacks can deal additional elemental damage.
Required conditions: the hero must have the Elemental Vision ability; the Altar of Elements building must be constructed in the town.
Additional damage is dealt when a stack from the Warlock's army attacks an enemy stack with the opposite "element" (Fire is opposite to Water, Air to Earth).

Additional elemental damage = (0.05* irresistible_magic_level + 0.1*num_altars_of_ primal_elements)* "physical damage".
, where irresistible_magic_level is the level of the Irresistible Magic skill of the hero (from Basic = 1 to Ultimate = 4);
num_altars_of_primal_elements is the number of towns with a constructed Altar of Primal Elements building.

That is, elemental damage = 5% of "physical" for each level of the Irresistible Magic skill plus 10% for each Altar of Primal Elements building.

With the Rage of Elements ability, additional elemental damage from "chains" is doubled.
That is, additional elemental damage = 2 * (0.05* irresistible_magic_level + 0.1*num_altars_of_ primal_elements) * "physical damage".

For elemental damage from "chains" dealt by stacks, there is an exception — it is not reduced by the attacked stack's defense/immunity against certain "elements" (i.e., practically, it is physical damage calculated according to elemental rules).

Ability Hellfire (Skill Gating, Demon Lord hero).
Chance=30% upon attack to deal additional elemental damage = (50+Hero_SpellPower*5).
"Element" - Fire.
Works for both melee and ranged attacks.
Each triggering of the ability spends 5 units of the hero's mana.

Ability Searing Fires (Skill Destructive Magic, Demon Lord hero).
Increases by 50% the additional elemental damage dealt using the Hellfire ability.
That is, elemental damage will be = 1.5 *(50+Hero_SpellPower*5).

Ability Hellwrath (Skill Defense, Demon Lord hero).
Elemental damage from the Hellfire ability will be dealt not only upon attack, but also during retaliation.

Hero Specializations.

Hero specialization in specific creatures (Gremlin Master, Golem Crafter, Mentor, Slave Driver, Black Hand, Blood Mistress, Infantry Commander, Beloved of the People, Archer Commander, Griffin Trainer, Hound Master, Temptress, Zombie Lord, Vampire Princess, Blade Master, Unicorn Maiden, Master of the Hunt).
The "added" modifier for "attack" and "defense" parameters = (1+ hero_level/2) for "specialized" creatures in the hero's army. Rounded down.

Lizard Breeder (Sorgal)
Grim Raiders increase damage from the Lizard Bite ability.
Damage modifier for Lizard Bite = (0.6 + 0.005*hero_level). (60% plus 0.5% per level of normal damage).
For example, at hero level 30, the Lizard Bite ability deals 75% of normal damage.
The specialization does not provide bonuses to "attack" and "defense" for Dark Riders/Grim Raiders.

Shadow Dancer (Shadya)
Provides a damage modifier = (1-hero_level*0.02) (-2% damage per hero level) when receiving damage from ranged attacks for all stacks in the hero's army.
For example, at level 20, the damage modifier will be = 0.6.

Cavalry Commander (Klaus)
Paladins increase damage from the Jousting ability.
Damage modifier for Jousting = (1 + bonus*"number of cells moved before attack"), where bonus = 0.12+0.02*hero_level.
For example, at level 20, the Jousting bonus will be = 0.52.
That is, the specialization provides a Jousting bonus = (12+2*hero_level)% damage per cell moved.
The specialization does not provide bonuses to "attack" and "defense" for Cavaliers/Paladins.

Paragon Knight (Godric)
Doubles the effect of the Benediction ability.
That is, it increases by +2 the "attack" and "defense" characteristics for all stacks in the hero's army; grants +20% to "initiative" and +2 to "morale".

Souldrinker (Raven)
Weakness and Mass Weakness spells additionally reduce the "defense" parameter of the "cursed" stack by a value = (hero_level/3). Rounded up.
For example, at level 20, the "defense" parameter will be reduced by 7.
The hero's specialization extends to the Weakness spell of Archliches and the Cursing Attack ability of Spectral Dragons.
The effect is not cumulative.

Sword of Sylanna (Anwen)
Provides a damage modifier = (1+hero_level*0.02) (+2% per hero level) when attacking favored enemies.
The modifier applies to any attack against favored enemies and does not depend on the "roll" of a double strike.

Weekly Bonuses.

Week of Feebleness.
"defense" characteristic modifier = 0.8 (-20% "defense") for all creatures of Haven, Sylvan, and Academy Factions.

Week of Infirmity.
"defense" characteristic modifier = 0.8 (-20% "defense") for all creatures of Necropolis, Inferno, and Dungeon Factions.

Week of Might.
"min damage" and "max damage" characteristics modifier = 1.5 (+50% base damage) for all creatures.

Week of Might'n'Magic.
"min damage" and "max damage" characteristics modifier = 1.5 (+50% base damage) for all creatures.
Additional weekly effect — the cost of combat spells is reduced by 2 times.

Example

Conditions.
A stack of Paladins strikes a stack of Archangels.
Paladin stack characteristics: count = 10, "attack" = 34, "damage" = 20-30, "morale" = 5; the hero has Expert Attack skill and Retribution ability. Before the strike, the paladin stack moved 3 cells. A "positive" luck trigger occurred during the strike.
Archangel stack characteristics: "defense" = 41; the hero has Expert Defense skill.

Calculation.
Number of paladins NumCreatures = 10.
Paladin "base damage" BaseDamage = [20-30].
Attack and defense damage modifier AttackDefenseModifier = 1/(1+(41-34)*0.05) = 0.74.

List of PhysicalModifiers:
From the paladin hero's Expert Attack skill = 1.15.
From the archangel hero's Expert Defense skill = 0.7.
From the paladin hero's Retribution ability = (1+5*0.05) = 1.25.
From the paladins' Jousting ability (for 3 cells moved) = 1+3*0.1 = 1.3.
From the triggered "positive" luck of the paladins = 2.0.
Total PhysicalModifiers = 1.15 * 0.7 * 1.25 * 1.3 * 2.0 = 2.62.

Physical damage PhysicalDamage = 10* [20-30] * 0.74 * 2.62 = [378.76-581.64] = [378-581].
No additional elemental damage.
Total damage TotalDamage = [378-581].
________________________________________

Calculation of damage for a hero's direct attack on a stack.
Damage from a hero's direct attack on an enemy stack is calculated according to its own principles and has nothing in common with the calculation of damage when one stack strikes another.

The following affect the hero's damage to a stack:
1) hero level: from 1 to 40;
2) level of creatures that make up the stack: from 1 to 8. (Creatures of levels 1-7 are ordinary creatures from towns or neutrals; a level 8 creature is only a Phoenix, summoned by the Conjure Phoenix spell);
3) HP parameter of the creature from the stack.

No other parameters affect the hero's damage ("attack", "defense", whether the creature is "upgraded" or not, remaining HP of the top creature in the stack, etc.).

The hero's direct damage is calculated as follows.

In the game resources, there is a table containing information on how many creatures of level N the hero will destroy depending on their own level. The table is stored in the following form:
Creature_level---Killed1---Killed30
1----------------2.0------12.0
2----------------1.0-------9.0
3----------------0.8-------6.5
4----------------0.5-------4.5
5----------------0.3-------3.0
6----------------0.2-------2.0
7----------------0.1-------1.5
8----------------0.01-----0.15

Table columns:
Creature_level - "Creature Level".
Killed1 - "Number of creatures killed" at hero level 1.
Killed30 - "Number of creatures killed" at hero level 30.

The simplified algorithm for calculating the hero's damage is as follows.
First, using the table, the "number of creatures killed" is calculated depending on the hero's level and the creature's level. The dependence of the hero's damage on their level is linear, and the "number of creatures killed" for "intermediate" hero levels is calculated using linear interpolation.

Then, "Hero Damage" = "Number of creatures killed" * "Creature HP".

Exact formula for calculating hero damage.
"Hero Damage" = HP * (Killed1 + (Hero_level-1)*(Killed30-Killed1)/30),

where HP is the "creature's HP";
Killed1 and Killed30 are values from the "Number of creatures killed" table columns;
Hero_level is the "hero level": from 1 to 40 (more accurately up to 43 — considering specifics for Ranger — see section below).

Example.
Condition.
A level 15 hero attacks a stack of Obsidian Gargoyles (level 2, 20 HP).

Calculation.
"Hero Damage" = 20 * (1.0 + (15-1)*(9.0-1.0)/30) = 20 * 4.73 = 94.6 = 94 HP.

Specifics of direct attack damage calculation for the Ranger class hero (Sylvan castle).
Due to their unique racial abilities, the Ranger hero has a modified formula for calculating direct damage.

Ability Deadeye Shot (skill Avenger).
According to the description: "Grants Ranger an ability to attack any enemy creatures on battlefield. The inflicted damage is 3 times his or her level. If that creature is present in Ranger's favorite enemy list then the critical strike is fulfilled, the damage is doubled and it always kills at least one creature".

In game version 1.0, there are two errors in this description.
First — when calculating damage to a normal (non-favored) enemy, it is assumed that the "hero level" is higher by 3 (rather than "the hero's direct strike damage is multiplied by 3").
Second — when calculating damage to a favored enemy, the damage is always multiplied by 2 (whereas it says "critical damage" is doubled with a certain probability).

The ability changes the direct damage calculation as follows.
If the attacked creature is NOT on the hero's favored enemy list, then when calculating "hero damage," the "hero level" parameter is increased by 3.
Formula:
"Hero Damage" = HP * (Killed1 + (3+Hero_level-1)*(Killed30-Killed1)/30).

If the attacked creature is on the favored enemy list, then, first, the "hero level" parameter is increased by 3 and, second, the "hero damage" is doubled.
Formula:
"Hero Damage" = 2 * HP * (Killed1 + (3+Hero_level-1)*(Killed30-Killed1)/30).

Ability Rain of Arrows (skill Avenger).
Errors in the description are similar to the Deadeye Shot ability.

Upon activation of the ability, the hero deals direct damage to all stacks that are favored enemies. When calculating "hero damage," the "hero level" parameter is increased by 3.
Formula:
"Hero Damage" = HP * (Killed1 + (3+Hero_level-1)*(Killed30-Killed1)/30).

Example for a Ranger hero.
Conditions.
A level 39 Ranger hero attacks a stack of Obsidian Gargoyles (level 2, 20 HP). The hero has the Deadeye Shot ability. Obsidian Gargoyle is on the hero's favored enemy list.

Calculation.
"Hero Damage" = 2 * 20 * (1.0 + (3+39-1)*(9.0-1.0)/30) = 2 * 20 * 11.93 = 477.3 = 477 HP.

All materials were taken from, as Rean noted, the Google search; the author of this article is alexrom66
User Avatar
20 years ago
Auto-translated
1) If you're plagiarizing from HugoLka, at least credit the author. Otherwise, it's illegal.
2) You created the topic in the wrong section. It should have been here: /forum/section/74/
3) I wrote part of this manual a long time ago here: /topic/735/
User Avatar
19 years ago
Auto-translated
Damage Calculation Guide (edition 1.3)
Part 1. Damage calculation for melee and ranged attacks.

When an attacking stack hits a targeted stack, a damage calculation process occurs. The formulas and rules used for this calculation are provided below.

Terms Used.
General:
Damage = damage.
Creature = creature.
Creature's stack = creature stack (stack).
HP = "health points" (HP).

Creature parameters displayed on the stats screen:
Attack = creature's "attack" ("атака").
Defense = creature's "defense" ("защита").
Damage = creature's "damage" parameter.
MinDamage, MaxDamage = "min damage" and "max damage".

Hero parameters displayed on the stats screen:
Attack = hero's "attack".
Defense = hero's "defense".

Exact Damage Calculation Formula.
The exact formula for calculating damage is as follows:

TotalDamage = PhysicalDamage + ElementalDamage.

PhysicalDamage = NumCreatures * BaseDamage * AttackDefenseModifier * PhysicalModifiers

, where TotalDamage is the total stack damage;
PhysicalDamage is the "physical damage" of the stack (main damage);
ElementalDamage is the additional "elemental damage" of the stack;
NumCreatures is the number of creatures in the attacking stack;
BaseDamage is the "base" damage of a creature in the attacking stack;
AttackDefenseModifier is the damage modifier based on "attack" and "defense";
PhysicalModifiers is the product of all "other" physical damage modifiers.

Detailed Formula Components.

PhysicalDamage
The main damage dealt by the attacking stack.

It depends on many parameters (see descriptions below).
After all calculations, "physical damage" is rounded down to the nearest integer.
Exception: if "physical damage" results in <1, it becomes =1.

NumCreatures
The number of creatures in the attacking stack.

BaseDamage
The "base" damage of a creature in the attacking stack.
Formula:
BaseDamage = "min damage" + random*("max damage"-"min damage"),

, where random is a real random number from 0 to 1;
"min damage" and "max damage" are creature characteristics: minimum and maximum base damage.

The "min damage" and "max damage" characteristics of a creature can change due to various game components: hero abilities (e.g., Frenzy), artifacts (e.g., Necklace of the Bloody Claw), spells (e.g., Berserk), and others. The final characteristic values are displayed on the creature's stats screen—these are the values plugged into the BaseDamage calculation formula.

AttackDefenseModifier
A damage modifier based on the "attack" characteristic of the attacking stack and the "defense" characteristic of the targeted stack.

The formula consists of 2 parts:
If attacker's "attack" >= target's "defense", then
AttackDefenseModifier = 1+("attack"-"defense")*0.05.
If attacker's "attack" < target's "defense", then
AttackDefenseModifier = 1/(1+("defense"-"attack")*0.05).

There are no limits on the value of the difference between "attack" and "defense". (Such a limit existed in early stages of development—the modifier was limited to the range [0.1; 3.0]).

The "attack" and "defense" characteristics of a creature can change due to various game components: hero's "attack" and "defense" characteristics, hero specializations, creature abilities (e.g., Rider's Charge and Precise Shot), and others.

There are two types of modifiers: "additive" (e.g., hero's "attack" and "defense") and "multiplicative" (e.g., Defend command, Marksman's Precise Shot ability). Order of application: additive first, then multiplicative.
After all calculations, the "attack" and "defense" characteristics are rounded down to the nearest integer.
The resulting "attack" and "defense" characteristics are plugged into the AttackDefenseModifier calculation formula.

PhysicalModifiers
The product of all physical damage modifiers.
Formula:
PhysicalModifiers = PhysicalModifier1 * PhysicalModifier2*...* PhysicalModifierN

, where PhysicalModifier1...PhysicalModifierN are multiplicative physical damage modifiers.

Physical damage modifiers (hereafter "damage modifiers") include various modifiers from hero skills/abilities, creature abilities, artifacts, and other factors that affect the dealt physical damage by a percentage. Examples: hero's Attack and Defense skills, Archery and Evasion abilities.

A full list of damage modifiers is provided in the corresponding section.

ElementalDamage
The "elemental damage" of the stack (additional damage).
Formula:
ElementalDamage = AdditionalElementalDamage1 + AdditionalElementalDamage2 + ... + AdditionalElementalDamageN

, where AdditionalElementalDamage1 ... AdditionalElementalDamageN are components of total elemental damage from various game mechanics.

"Elemental damage" is dealt in addition to "physical damage". It depends on various hero skills/abilities and creature capabilities.

In some cases, the damage from an "elemental damage" component may be equal to a certain percentage of "physical damage" (e.g., hero's Cold Steel ability).
In other cases, it is completely independent of "physical damage" (e.g., Inferno-hero's Hellfire ability).

The damage value from an individual component (AdditionalElementalDamage) may be reduced if the targeted stack has protection/immunity against the "element" of that component (Water/Fire/Air/Earth).

A full list of "elemental damage" components is provided in the corresponding section.

Simplified General Damage Calculation Formula.
Some details are omitted from this formula, but it is more visual and convenient.

If attacking stack's "attack" > target's "defense", then:
"Total Damage" = "Base damage of 1 creature" * "Number of creatures in stack" * (1+("attack"-"defense")*0.05) * "Other damage modifiers"

If attacking stack's "attack" < target's "defense", then:
"Total Damage" = "Base damage of 1 creature" * "Number of creatures in stack" / (1+("defense"-"attack")*0.05) * "Other damage modifiers"

, where "Base damage of 1 creature" is a random number in the range ["min damage"; "max damage"];
"Other damage modifiers" is the product of all damage modifiers from skills, hero abilities, creature abilities, etc.

Damage Calculation Specifics for Ranged Attacks.
For stacks with ranged attacks (with the Shooter ability), there are several general damage modifiers:
1) If the targeted stack is within 6 cells, the damage modifier will be 1.0 (i.e., no damage bonuses).
2) If the targeted stack is further than 6 cells, the damage modifier will be 0.5 (-50% damage).
3) When performing a melee attack, a stack with the Shooter ability will have a damage modifier of 0.5 (-50% damage).

Stacks from the defending hero's army located inside the castle have a damage modifier = 0.5 (-50%) for damage dealt by enemy ranged attacks (provided that walls or gates on the line of fire are not destroyed and the enemy stack is outside the castle).

The distance from the shooter to the target is calculated exactly as movement of stacks across the battlefield (1 for vertical/horizontal movement, 1.5 for diagonal).

There is a significant number of damage modifiers applied only to ranged attacks or only to melee attacks (from hero abilities, creature abilities, spells, artifacts, etc.). When describing such an ability/artifact/spell, it will be specified which type of attack (melee or ranged) the modifiers affect.

Version History:
In 1.0-1.2: Castle walls did not affect ranged damage

Influence of Various Game Components on Damage Calculation.

Core Game Mechanics.
Hero "attack" and "defense" parameters.
These parameters are additive modifiers to the same parameters of the creature.

Defend Command.
If a stack performs the Defend command, its "defense" parameter modifier = 1.3 (+30% "defense").
There are exceptions to this general rule—the hero's Hold Your Ground ability and the Ancient Treant's Take Roots ability (see below).

Luck.
When "positive" luck triggers, damage modifier = 2.0 (+100% damage).
When "negative" luck triggers, damage modifier = 0.5 (-50% damage).
With the Absolute Luck ability, "positive" luck always triggers (regardless of the creature's "luck" characteristic sign).

Hero Skills.
Attack.
Basic/Advanced/Expert level provides a damage modifier = 1.05 / 1.1 / 1.15 (+5%/10%/15% damage) for melee attacks of all stacks in the hero's army.

Defense.
Basic/Advanced/Expert level provides a damage modifier = 0.9 / 0.8 / 0.7 (-10%/20%/30% damage) when receiving damage from melee attacks by all stacks in the hero's army.

Hero Abilities.
Archery (Attack skill).
Damage modifier = 1.2 (+20% damage) for ranged attacks of all stacks in the hero's army.

Evasion (Defense skill).
Damage modifier = 0.8 (-20% damage) when receiving damage from ranged attacks by all stacks in the hero's army.

Stand Your Ground (Defense skill).
"defense" parameter modifier = 1.6 (+60% "defense") when a stack from the hero's army performs the Defend command.
Special case—Ancient Treants with Take Roots ability. With Stand Your Ground, their "defense" parameter modifier = 2.0 (+100% "defense") when performing Defend.

Retribution (Attack skill).
If a stack's "morale" > 0, damage modifier = (1+0.05*"morale") (+5% damage per unit of morale) for melee and ranged attacks of all stacks in the hero's army.
If morale <= 0, damage modifier = 1.0 (i.e., damage is unchanged).

Cold Steel (Attack skill).
Additional elemental damage = 0.1 * "physical damage" (+10% cold damage).
"Element" - Water (cold).
Works for both melee and ranged attacks.

Chilling Bones (Defense skill).
Any stack performing a melee attack against a stack with Chilling Bones receives elemental damage in return = 0.05 * "physical damage dealt" (5% cold retaliation damage).
"Element" - Water (cold).
Damage from Chilling Bones is dealt every time the stack is hit and does not depend on the stack's retaliation attack.

Fiery Wrath (Destructive Magic skill).
Additional elemental damage = 0.1 * "physical damage" (+10% fire damage).
"Element" - Fire.
Works for both melee and ranged attacks.

Wall of Fog (Summoning Magic skill).
"min damage" and "max damage" parameters are reduced by 10% for enemy army stacks with the Shooter ability.

Battle Frenzy (Attack skill).
Increases "min damage" and "max damage" parameters by +1 for all stacks in the hero's army.
Essentially, this increases a creature's "base damage" by 1.

Nature's Wrath (Attack skill).
Increases "max damage" parameter by +1 for all creatures of the Sylvan faction.

Elven Luck (Luck skill).
Damage modifier when "positive" luck triggers = 2.25 (+125% damage) for melee and ranged attacks.
When "negative" luck triggers, damage modifier = 0.5 (-50% damage).

Creature Abilities.
Battle Dive (Imperial Griffin).
Damage modifier = 2.0 (+100% damage) when "diving" onto the targeted stack.

Fire Shield (Fire Elemental, Phoenix).
Any stack performing a melee attack against a stack with Fire Shield receives elemental damage in return = 0.2 * "physical damage dealt" (20% fire retaliation damage).
"Element" - Fire.
Damage from Fire Shield is dealt every time the stack is hit and does not depend on the stack's retaliation attack.

Jousting (Cavalier, Paladin).
Damage modifier = 1+0.05*"number of cells traveled before attack". (+5% damage per cell traveled).

Version History:
In 1.0-1.1: The bonus was 0.1 (+10% damage) per cell traveled.

Large Shield (Footman, Squire).
Damage modifier = 0.5 (-50% damage) when receiving damage from ranged attacks.

Lizard Bite (Grim Raider).
If a friendly stack attacks an enemy stack that is adjacent to a friendly Grim Raider stack, the Grim Raiders stack "supports" the attack and deals an additional hit with a damage modifier = 0.5 (-50% damage).

No Range Penalty (Mage, Archmage).
No damage penalty for ranged attacks at a distance > 6 cells.

No Melee Penalty (Priest, Inquisitor, Titan, Scout, Assassin).
No standard shooter damage penalty during melee attacks.

Precise Shot (Marksman).
During a ranged attack, the target stack's final "defense" parameter is considered equal to 0 if the distance to it <= 3 cells.
Essentially, the target stack's "defense" parameter is completely ignored when firing at point-blank range.

Range Penalty (Scout, Assassin).
Damage modifier = 0.5 (-50% damage) when performing a ranged attack.

Rider Charge (Dark Raider, Grim Raider).
For every cell traveled by the stack before hitting, 20% is subtracted from the target stack's "defense" parameter. However, the "defense" parameter cannot become <0.
Example: after traveling 3 cells before hitting, the "defense" parameter decreases by 60%. After traveling 5 or more cells, the "defense" parameter will be = 0.

Scatter Shot (Archer).
Fires in a 3x3 square, but the damage modifier will be = 0.5 (-50% damage).

Shield Allies (Squire).
All stacks on adjacent cells have a damage modifier = 0.5 (-50% damage) when receiving damage from ranged attacks.

Take Roots (Ancient Treant).
Performing the Defend command gives a "defense" parameter modifier = 1.5 (+50% "defense"). (Instead of the usual modifier = 1.3).
Additionally grants the Unlimited Retaliation ability.
If the hero has the Stand Your Ground ability, performing the Defend command gives a "defense" parameter modifier = 2.0 (+100% "defense").

Vorpal Sword (Pit Lord).
Damage dealt by a stack with the Vorpal Sword ability will be increased by a constant value = to the "HP" parameter of the targeted stack's creature.
Essentially, 1 is first "subtracted" from the number of creatures in the target stack, and then normal damage is dealt.

Enraged (Footman, Squire, Horned Demon, Horned Overseer, Zombie, Plague Zombies, Treant, Ancient Treant, Stone Gargoyle, Obsidian Gargoyle, Hydra, Deep Hydra).
The stack's "attack" parameter increases by +X every time a friendly stack dies. The value of X is higher the greater the strength (sum of Power characteristics) of the killed stack. Additionally, X depends on the strength of the stack with the Enraged ability—the larger the stack, the smaller X. Minimum value of X = +1.

Artifacts.
Unicorn Horn Bow ("Negates range penalties for all shooting units in hero's army").
Grants the "No Range Penalty" ability to all Shooter stacks in the hero's army.

Necklace of the Bloody Claw ("Adds +1 damage to all creatures in hero's army").
Increases "min damage" and "max damage" characteristics by 1 for all stacks in the hero's army.

Spells.
Weakness (Dark Magic).
Reduces a stack's "max damage" characteristic.
"max damage" = "min damage" + "spell effect"*("max damage"-"min damage").
"Spell effect" at None/Basic/Advanced/Expert levels of the Dark Magic school is 0.5 / 0.35 / 0.2 / 0.0.

Vulnerability (Dark Magic).
At None/Basic/Advanced/Expert levels of the Dark Magic school, it reduces a stack's "defense" characteristic by 3/4/5/6 points.

Suffering (Dark Magic).
At None/Basic/Advanced/Expert levels of the Dark Magic school, it reduces a stack's "attack" characteristic by 3/6/9/12 points.

Confusion (Dark Magic).
At None/Basic/Advanced/Expert levels of the Dark Magic school, it provides a damage modifier = 0.5 / 0.3 / 0.1 / 0.0 (-50%/70%/90%/100% damage) for ranged and retaliation attacks of the stack.

Frenzy (Dark Magic).
Increases a stack's "min damage" and "max damage" characteristics.
"min damage" = "min damage"* (1+SpellPower*0.03).
"max damage" = "max damage"* (1+SpellPower*0.03).

Divine Strength (Light Magic).
Increases a stack's "min damage" characteristic.
"min damage" = "min damage" + "spell effect"*("max damage" - "min damage").
"Spell effect" at None/Basic/Advanced/Expert levels of the Light Magic school is 0.5 / 0.65 / 0.8 / 1.0.

Endurance (Light Magic).
At None/Basic/Advanced/Expert levels of the Light Magic school, it increases a stack's "defense" characteristic by 3/6/9/12 points.

Righteous Might (Light Magic).
At None/Basic/Advanced/Expert levels of the Light Magic school, it increases a stack's "attack" characteristic by 3/6/9/12 points.

Deflect Missile (Light Magic).
At None/Basic/Advanced/Expert levels of the Light Magic school, it provides a damage modifier = 0.75 / 0.6 / 0.45 / 0.3 (-25%/40%/55%/70% damage) when a stack receives damage from ranged attacks.

Arcane Armor (Summoning Magic).
At None/Basic/Advanced/Expert levels of the Summoning Magic school, it provides a damage modifier = 0.75 / 0.75 / 0.75 / 0.5 (-25%/25%/25%/50% damage) when a stack receives damage from any attacks.

Unique Racial Hero Skills and Abilities.

Avenger Skill (Ranger hero).
Upon successful trigger of this skill, the favored enemy takes damage with a modifier of 2.0 (+100% damage).

There is an exception to the general damage calculation rule—the case where both "positive luck" and "attack on favored enemy" trigger simultaneously (battle log message: "lucky attack on favored enemy"). In this case, damage bonuses are added rather than multiplied—total damage modifier = 3.0 (+200% damage), or if the hero has the Elven Luck ability, it is = 3.25 (+225% damage).

However, this exception does not apply to "negative luck" + "attack on favored enemy" (log: "unlucky attack on favored enemy"). In this case, damage modifiers are multiplied normally: damage bonus = 0.5*2.0 = 1.0 (i.e., dealt damage is unchanged).

Counterstrike Skill (Knight hero).
Basic/Advanced/Expert/Ultimate skill level provides a damage modifier = 1.05 / 1.1 / 1.2 / 1.25 (+5%/10%/20%/25% damage) for "retaliation" melee attacks of all stacks in the hero's army.

Benediction Ability (Counterstrike Skill, Knight hero).
Upon activation, it provides +1 to "attack" and "defense" characteristics for all stacks in the hero's army.
Additionally grants +10% "initiative" and +1 "morale".
Duration = (2 + 0.25*hero_level) turns.

Elemental chains (Warlock hero).
Briefly, only regarding damage dealing.

Using "elemental chains", Warlock army stacks can deal additional elemental damage.
Required conditions: the hero must have the Elemental Vision ability; an Altar of Elements must be built in the city.
Additional damage is dealt when a Warlock army stack attacks an enemy stack with the opposite "element" (Fire is opposite to Water, Air to Earth).

Additional elemental damage = (0.05* irresistible_magic_level + 0.1*num_altars_of_ primal_elements)* "physical damage".
, where irresistible_magic_level is the hero's Irresistible Magic skill level (from Basic = 1 to Ultimate = 4);
num_altars_of_primal_elements is the number of cities with an Altar of Primal Elements built.

Essentially, elemental damage = 5% of "physical" for each Irresistible Magic skill level plus 10% for each Altar of Primal Elements building.

With the Rage of Elements ability, additional elemental damage from "chains" is doubled.
i.e., additional elemental damage = 2 * (0.05* irresistible_magic_level + 0.1*num_altars_of_ primal_elements) * "physical damage".

There is an exception for elemental damage from "chains" dealt by stacks—it is not reduced by the targeted stack's protection/immunity against certain "elements" (i.e., it is practically physical damage calculated by elemental rules).

Hellfire Ability (Gating Skill, Demon Lord hero).
Chance=30% upon attack to deal additional elemental damage = (50+Hero_SpellPower*5).
"Element" - Fire.
Works for both melee and ranged attacks.
Each trigger of the ability spends 5 units of hero mana.

Searing Fires Ability (Destructive Magic Skill, Demon Lord hero).
Increases additional elemental damage dealt via the Hellfire ability by 50%.
i.e., elemental damage will be = 1.5 *(50+Hero_SpellPower*5).

Hellwrath Ability (Defense Skill, Demon Lord hero).
Elemental damage from the Hellfire ability will be dealt not only upon attack but also during retaliation.

Fire mastery.
Stacks (both friendly and enemy) hit by Fireball or Armageddon receive a "defense" parameter modifier = 0.5 (-50% "defense") for 1 turn (effect initiative = 10).

Hero Specializations.

Hero specialization in specific creatures (Gremlin Master, Golem Crafter, Mentor, Slave Driver, Black Hand, Blood Mistress, Infantry Commander, Beloved of the People, Archer Commander, Griffin Trainer, Hound Master, Temptress, Zombie Lord, Vampire Princess, Blade Master, Unicorn Maiden, Master of the Hunt).
Additive modifier for "attack" and "defense" parameters = (1+ hero_level/2) for "specialized" creatures in the hero's army. Rounded down.

Lizard Breeder (Sorgal)
Grim Raiders receive increased damage from the Lizard Bite ability.
Damage modifier for Lizard Bite = (0.6 + 0.005*hero_level). (60% plus 0.5% per level of normal damage).
For example, at hero level 30, the Lizard Bite ability deals 75% of normal damage.
The specialization does not provide "attack" and "defense" bonuses for Dark Riders/Grim Raiders.

Shadow Dancer (Shadya)
Provides a damage modifier = (1-hero_level*0.02) (-2% damage per hero level) when receiving damage from ranged attacks for all stacks in the hero's army.
For example, at level 20, the damage modifier will be = 0.6.

Cavalry Commander (Klaus)
Damage dealt by Cavaliers/Paladins is increased.
Damage modifier = (1+ 0.02 + 0.02*hero_level).
For example, at level 20, the damage modifier will be = 1.52 (+52% damage).
Taking into account the Jousting ability, the Cavaliers/Paladins stack damage modifier will be = (1 + 0.05*"number of cells traveled before attack")*(1+ 0.02 + 0.02*hero_level).

The specialization does not provide "attack" and "defense" bonuses for Cavaliers/Paladins.

Version History:
In 1.0 - 1.1: The specialization bonus was added to the bonus per cell traveled before attack. The Jousting ability bonus was = 0.1 per cell traveled.
In 1.2: The Jousting ability bonus became = 0.05 per cell traveled.
In 1.3: The specialization bonus began applying to the stack's final damage.

Paragon Knight (Godric)
Doubles the effect of the Benediction ability.
i.e., increases "attack" and "defense" characteristics by +2 for all stacks in the hero's army; grants +20% "initiative" and +2 "morale".

Souldrinker (Raven)
Weakness and Mass Weakness spells additionally reduce the "defense" parameter of the "cursed" stack by a value = (hero_level/3). Rounded up.
For example, at level 20, the "defense" parameter will be reduced by 7.
The hero specialization extends to the same effect for Archliches' Weakness spell and Spectral Dragons' Cursing Attack ability.
Effect is not cumulative.

Sword of Sylanna (Anwen)
Provides a damage modifier = (1+hero_level*0.02) (+2% per hero level) when attacking favored enemies.
The modifier applies to any attack against favored enemies and does not depend on whether a double strike occurs.

Weekly Bonuses.

Week of Feebleness.
"defense" characteristic modifier = 0.8 (-20% "defense") for all creatures of the Haven, Sylvan, and Academy factions.

Week of Infirmity.
"defense" characteristic modifier = 0.8 (-20% "defense") for all creatures of the Necropolis, Inferno, and Dungeon factions.

Week of Might.
"min damage" and "max damage" characteristics modifier = 1.5 (+50% base damage) for all creatures.

Week of Might'n'Magic.
"min damage" and "max damage" characteristics modifier = 1.5 (+50% base damage) for all creatures.
Additional weekly effect—the cost of combat spells is reduced by half.

Example
Conditions.
A Paladins stack attacks an Archangels stack.
Paladins stack stats: number = 10, "attack" = 34, "damage" = 20-30, "morale" = 5; hero has Expert Attack skill and Retribution ability. Before hitting, the paladin stack traveled 3 cells. "Positive" luck triggered upon hit.
Archangels stack stats: "defense" = 41; hero has Expert Defense skill.

Calculation.
Number of paladins NumCreatures = 10.
Paladin "base damage" BaseDamage = [20-30].
Attack and defense damage modifier AttackDefenseModifier = 1/(1+(41-34)*0.05) = 0.74.

PhysicalModifiers list:
From paladins' hero Expert Attack skill = 1.15.
From archangels' hero Expert Defense skill = 0.7.
From paladins' hero Retribution ability = (1+5*0.05) = 1.25.
From paladins' Jousting ability (for 3 cells traveled) = 1+3*0.05 = 1.15.
From triggered "positive" luck for paladins = 2.0.
Total PhysicalModifiers = 1.15 * 0.7 * 1.25 * 1.15 * 2.0 = 2.31.

Physical damage PhysicalDamage = 10* [20-30] * 0.74 * 2.31 = [341.88-512.82] = [341-512].
No additional elemental damage.
Total Damage TotalDamage = [341-512].
Hero Direct Attack on Stack Damage Calculation.
Damage from a hero's direct attack on an enemy stack is calculated by its own principles and has nothing to do with the calculation of stack-on-stack damage.

The following affect hero damage to a stack:
1) Hero level: from 1 to 40;
2) Level of creatures in the stack: from 1 to 8. (Levels 1-7 are ordinary town or neutral creatures; level 8 is only Phoenix, summoned by Conjure Phoenix);
3) HP parameter of a creature from the stack.

No other parameters affect hero damage ("attack", "defense", whether the creature is upgraded or not, remaining HP of the top creature in the stack, etc.).

Direct hero damage is calculated as follows.

The game resources contain a table with information on how many creatures of level N a hero will destroy depending on their own level. The table is stored as follows:
Creature_level Killed1 Killed30
1 2.0 12.0
2 1.0 9.0
3 0.8 6.5
4 0.5 4.5
5 0.3 3.0
6 0.2 2.0
7 0.1 1.5
8 0.01 0.15

Table columns:
Creature_level - "Creature Level".
Killed1 - "Number of creatures killed" at hero level 1.
Killed30 - "Number of creatures killed" at hero level 30.

The simplified hero damage calculation algorithm is as follows.
First, the "Number of creatures killed" is calculated using the table based on the hero's level and creature's level. The dependence of hero damage on their level is linear, and the "Number of creatures killed" for "intermediate" hero levels is calculated via linear interpolation.

Then "Hero Damage" = "Number of creatures killed" * "Creature HP".

Exact Hero Damage Calculation Formula.
"Hero Damage" = HP * (Killed1 + (Hero_level-1)*(Killed30-Killed1)/30),

where HP is the "Creature HP";
Killed1 and Killed30 are values from the "Number of creatures killed" table columns;
Hero_level is the "hero level": from 1 to 40 (more accurately up to 43—considering specifics for Ranger, see section below).

Example.
Condition.
A level 15 hero attacks an Obsidian Gargoyle stack (level 2, 20 HP).

Calculation.
"Hero Damage" = 20 * (1.0 + (15-1)*(9.0-1.0)/30) = 20 * 4.73 = 94.6 = 94 HP.

Damage Modifiers for Hero Direct Attack on Stack.

Deadeye Shot Ability (Avenger skill).
Errors in the official ability description ("Hero deals creatures +3 units of damage from their level.").

The ability changes direct damage calculation as follows.
If the targeted creature is NOT on the hero's favored enemy list, then when calculating "hero damage", the "hero level" parameter increases by 3.
Formula:
"Hero Damage" = HP * (Killed1 + (3+Hero_level-1)*(Killed30-Killed1)/30).

If the targeted creature is on the favored enemy list, then first, the "hero level" parameter increases by 3 and second, "hero damage" is doubled.
Formula:
"Hero Damage" = 2 * HP * (Killed1 + (3+Hero_level-1)*(Killed30-Killed1)/30).

Additionally, if the targeted creature is on the favored enemy list, at least 1 creature in the stack dies: if the attack does not kill any creatures in the stack, the attack deals damage = to the remaining HP of the top unit in the stack.

Rain of Arrows Ability (Avenger skill).
Description errors similar to Deadeye Shot ability.

Upon activation of the ability, the hero deals direct damage to all stacks that are favored enemies. When calculating "hero damage", the "hero level" parameter increases by 3.
Formula:
"Hero Damage" = HP * (Killed1 + (3+Hero_level-1)*(Killed30-Killed1)/30).

Mark of the Damned Ability (Gating skill)
Upon trigger of the ability, hero level increases by 3 for damage calculation (similar to Deadeye Shot ability).}

Retaliation Strike Ability (Counterstrike skill)
Upon trigger of the ability, hero level increases by 3 for damage calculation (similar to Deadeye Shot ability).

Example for Ranger hero.
Conditions.
A level 39 Ranger hero attacks an Obsidian Gargoyle stack (level 2, 20 HP). The hero has the Deadeye Shot ability. Obsidian Gargoyle is a favored enemy of the hero.

Calculation.
"Hero Damage" = 2 * 20 * (1.0 + (3+39-1)*(9.0-1.0)/30) = 2 * 20 * 11.93 = 477.3 = 477 HP.

Added after 1 minute

Statistics

Welcome our newest member: recijeb

Users Online 1 users 1267 guests