Magic Resistance (DMG)

Some creatures or items strongly resist the effects of magic (or impart such resistance to others). This makes them more difficult to affect with magical energy than ordinary creatures or items.
A rare few creatures are extremely anti-magical—magic rolls off them like water off a duck's back. More common are creatures, especially from the outer planes, that live in enchanted or sorcerous lands and are filled with powerful arcane energies. These creatures eat and breathe the vapors of wizardry, and they have a high tolerance against sorcery.
Magic resistance is an innate ability. That is, the possessor does not have to do anything special to use it. The creature need not even be aware of the threat for its magic resistance to operate. Such resistance is part of the creature or item and cannot be separated from it. Creatures, however, can lower their magic resistance at will.
Magic resistance is also an individual ability. A creature with magic resistance cannot impart this power to others by holding their hands or standing in their midst. Only the rarest of creatures and magical items have the ability to bestow magic resistance upon another.
Magic resistance is given as a percentile number. For a magical effect to have any chance of success, the magic resistance must be overcome. The target (the one with the magic resistance) rolls percentile dice. If the roll is higher than the creature's magic resistance, the spell has a normal effect. If the roll is equal to or less than the creature's magic resistance, the spell has no effect on the creature.
== Effects of Magic Resistance ==
Magic resistance enables a creature to ignore the effects of spells and spell-like powers. It does not protect the creature from magical weapon attacks or from natural forces that can be a direct or accidental result of a spell. Nor does it prevent the protected creature from using his own abilities or from casting spells and using magical items. It can be effective against both individually targeted spells and, within limits, area-effect spells.
If a magic resistance roll fails, and the spell has normal effects, the target can make all saving throws normally allowed against the spell.
== When Magic Resistance Applies ==
Magic resistance applies only if the successful casting of a spell would directly affect the resistant creature or item. Thus, magic resistance is effective against a magic missile (targeted at a creature or item) or a fireball spell (damaging the area the creature or item is in).
Magic resistance is not effective against an earthquake caused by a spell. While the creature could suffer injury or death falling into a chasm the spell opens under its feet, the magical energy of the spell was directed at the ground, not the creature. Magic resistant creatures are not immune to events that occur as the consequence of spells, only to the direct energy created or released by a spell.
Player characters do not normally have magic resistance (though they still get saving throws vs. magical spells and such). This ability is reserved mainly for special monsters.
== Successful Magic Resistance Rolls ==
A successful magic resistance check can have four different results, depending on the nature of the spell being resisted.
Individually Targeted Spells: By definition, these spells affect just one creature, and only the targeted creature rolls for magic resistance, if it has any. If a spell of this type is directed at several targets, each target rolls independently of the others. An example of this would be a hold person spell aimed at four creatures, with each creature getting a magic resistance roll, if they have magic resistance.
If the magic resistance roll is successful, the spell has no effect on that creature, the spell fails and disappears. If several targets are involved, the spell could still affect others who fail their magic resistance roll.
Area-Effect Spells: These spells are not targeted on a single creature, but on a point. The spell's effect encompasses everything within a set distance of that point. A successful magic resistance check enables the creature to ignore the effect of the spell. However, the spell is not negated and still applies to all others in the area of effect.
In-Place Spells: These spells operate continuously in a particular place or on a particular creature, character, or item. Protection from evil is one example of this kind of spell.
Magic resistance comes into play only if a creature or item finds himself or itself in the place where the spell is in operation. Even then, magic resistance may not come into play. Nothing happens if the spell isn't of a type that affects the character. Thus, a part water spell would not collapse simply because a magic resistant creature walked through the area. A protection from evil spell, which could affect the creature, would be susceptible to magic resistance.
If the DM determines that a magic resistance roll is appropriate, and the roll succeeds, the in-place spell collapses, usually with a dramatic thunderclap and puff of smoke.
Permanent Spells: Magic resistance is insufficient to destroy a permanent spell. Instead, the spell is negated, within the same guidelines given for in-place spells, for as long as the magic resistant creature is in the area of effect.
Thus, a magic-resistant creature might be able to step through a permanent wall of force enchantment as if it weren't there. However, the wall would spring back into existence as soon as the creature passed through (i.e., no one else can pass through).