Implemented binary resistances and some more

Port From (https://github.com/TrinityCore/TrinityCore/commit/ca26c33145cb40ae7fd2c84fc7577fc6f11bdbbf)
This commit is contained in:
hondacrx
2019-08-16 23:15:19 -04:00
parent d3bce6a75c
commit bdfea4ecad
8 changed files with 322 additions and 105 deletions
+7 -1
View File
@@ -2433,7 +2433,13 @@ namespace Game.Spells
target.ApplySpellImmune(Id, SpellImmunity.Mechanic, i, apply);
if (apply && HasAttribute(SpellAttr1.DispelAurasOnImmunity))
target.RemoveAurasWithMechanic(mechanicImmunity, AuraRemoveMode.Default, Id);
{
// exception for purely snare mechanic (eg. hands of freedom)!
if (mechanicImmunity == (1 << (int)Mechanics.Snare))
target.RemoveMovementImpairingAuras(false);
else
target.RemoveAurasWithMechanic(mechanicImmunity, AuraRemoveMode.Default, Id);
}
}
uint dispelImmunity = immuneInfo.DispelImmune;