Magic Resistance



Magic resistance is a stat that reduces (or increases, if negative) magical damage a unit takes from spells and attacks. Every unit is capable of gaining or losing magic resistance, and most units start with a small amount of base resistance. A hero's magic resistance can be passively increased with talents, certain items, and some abilities. Magic resistance of any unit can also be temporarily increased or reduced with some abilities.

Base Magic Resistance
Base Magic Resistance is a value that never changes throughout a game. It consists of one fixed value set for each unit individually. The base magic resistance of a unit can be a negative number.

Heroes
All heroes currently have the same Base Magic Resistance value:



Base Magic Resistance Negation Abilites
Some abilities negate or ignores a unit's base magic resistance by removing a percentage of the base magic resistance on the target. This magic resistance negation only affects the base magic resistance value of units, other sources of magic resistance are not affected.

(and 's ) interact with magic resistance differently. Instead of stacking multiplicatively with other sources of magic resistance, it acts as a multiplier for the base magic resistance. These two abilities are currently the only two sources of base magic resistance negation, and it is defined as



With  being the Base Magic Resistance Value,   the Actual Base Magic Resistance and   the Base Magic Resistance Negation.

This means, for heroes with base magic resistance,  reduces magic resistance by, down to 15%/10%/5%/0%.

The following abilities negate base magic resistance:

Stacking
All sources of magic resistance stack multiplicatively. This means a unit's magic resistance value changes less the higher its magic resistance is, and more the lower it is. This prevents a unit from reaching 100% magic resistance by stacking different sources up.

There are several abilities that set a unit's magic resistance to 100%. E.g.

Magic resistance multiplier is defined as

With  being the index of base magic resistance,   being the index of magic resistance sources and   being the index magic resistance reduction sources.



To get the total magic resistance percentage

Actual magic damage dealt after magic resistance is defined as

Magic damage barrier absorbs a set amount of magic damage before it is reduced by magic resistance.


 * Example 1:


 * have Level 4 and a . What is his current magic resistance?
 * Base hero magic resistance:
 * Bonus magic resistance: :, :
 * Magic resistance reduction: 0 (None)




 * 's current magic resistance in this example is %.


 * Example 2:


 * is at max level under the effect of a Level 4 and a Level 4 . What is his current magic resistance?
 * Base hero magic resistance:
 * Bonus magic resistance: 0 (None)
 * Magic resistance reduction: :, :




 * 's current magic resistance in this example is %.

Effective HP
The extra damage a unit can take due to magic resistance is known as its extra effective HP (or EHP) for magical damage. Despite each source of magic resistance increasing the magic resistance value less the higher it is and making them seem less effective, each sources increases the unit's effective HP against magical damage by their base value.

A unit with 0% magic resistance has 100% effective HP against magical damage, means magical damage equaling 100% of its health is required to kill it. Most heroes have magic resistance by default, making their effective HP against magical damage %.

This definition of EHP assumes all damage taken is magical. EHP against physical damage (such as basic hero attacks etc.) is modified by armor.

Effective HP against magical damage is defined as



Instead of diminishing in effectiveness, multiple sources of resistance are actually more effective stacked than they are individually. Two sources of 25% resistance stacked provides 78% extra EHP whereas one source provides 33%.
 * Example 1


 * at max level has health with Level 4  and a, how much EHP against magical damage he has?


 * According to the previous example in magic resistance stacking above, with Level 4  and a  has a magic resistance of % (or ).
 * Base magic resistance:
 * Bonus magic resistance: :, :




 * has EHP against magical damage in this example.


 * Example 2


 * has health at max level. While under the effect of a Level 4  and Level 4, how much EHP against magical damage he has?


 * According to the previous example in magic resistance stacking above, who is affected by those two abilities will have a magic resistance of % (or ).
 * Base hero magic resistance:
 * Bonus magic resistance: 0 (None)
 * Magic resistance reduction: :, :




 * has EHP against magical damage in this example.

Modifying Magic Resistance
Several abilites and items have abilities that grant or reduce magic resistance.

Magic Resistance Increasing Abilities
The following abilities increase magic resistance:

Magic Resistance Reducing Abilities
The following abilities reduce magic resistance:

Talents
Assuming basic magic resistance and no other sources of magic resistance, the following heroes with bonus magic resistance talents effectively have their magic resistance increased up to:

Besides these, the following heroes have talents which increase the magic resistance of the units they summon

Items
These items grant bonus magic resistance to the hero who has them equipped.

Magical damage barrier
Magical damage barriers absorb a flat amount of magical damage, no matter whether it comes from abilities (magical spell damage) or attacks (magical attack damage). The barrier absorbs the damage before it is reduced by magic resistance.


 * Example 1


 * has a health damage barrier, and gets hit by  magical damage. How much actual magical damage will he take?
 * Base magic resistance:




 * will take magical damage.

This means the exceeding 100 magical damage is not absorbed and the damage is reduced by 25% magic resistance to 75 magical damage. In this example, takes 75 damage. This means a barrier is more effective the lower a unit's magic resistance is, similar to how damage block is more effective, the lower the armor is.

Magic damage barrier stacking
Multiple sources of magical damage barriers work independently and do not stack, when a unit is affected by multiple magical damage barriers, all of them deplete at the same time.

However, if a unit is affected by multiple barriers receive a damage instance that is greater than all barriers individually, the damage gets blocked as if the barriers were one barrier with combined capacity.

Magic damage barrier stacking is defined as



With  being the incoming magical damage value,   being the index of sources of magic barrier value.


 * Example 1


 * is affected by Level 4 and  of Pipe of Insight. He then takes  magical damage. Both magical damage barriers will lose  capacity.
 * Barrier capacity: :, :




 * Since incoming magical damage is less than all individual barriers. Both and  will now have  and  remaining magic barrier capacity respectively.


 * Example 2
 * is affected by Level 4 and  of Pipe of Insight. He then takes  magical damage.
 * Barrier capacity: :, :




 * Since incoming magical damage is greater than the sum of both barriers, both and  are depleted, and magical damage is blocked as if the barriers were one barrier with combined capacity.  takes the remaining  damage before applying magic resistance.