Core/Spells: Implemented SPELL_ATTR5_NOT_AVAILABLE_WHILE_CHARMED
Port From (https://github.com/TrinityCore/TrinityCore/commit/076c63c766d10697cea17da8bd5194862a682cbe)
This commit is contained in:
@@ -110,6 +110,9 @@ namespace Game.Entities
|
||||
SpellInfo spellInfo = Global.SpellMgr.GetSpellInfo(spellId, _unit.GetMap().GetDifficultyID());
|
||||
if (spellInfo != null)
|
||||
{
|
||||
if (spellInfo.HasAttribute(SpellAttr5.NotAvailableWhileCharmed))
|
||||
continue;
|
||||
|
||||
if (spellInfo.IsPassive())
|
||||
_unit.CastSpell(_unit, spellInfo.Id, new CastSpellExtraArgs(true));
|
||||
else
|
||||
@@ -142,6 +145,9 @@ namespace Game.Entities
|
||||
continue;
|
||||
}
|
||||
|
||||
if (spellInfo.HasAttribute(SpellAttr5.NotAvailableWhileCharmed))
|
||||
continue;
|
||||
|
||||
if (spellInfo.IsPassive())
|
||||
{
|
||||
_unit.CastSpell(_unit, spellInfo.Id, new CastSpellExtraArgs(true));
|
||||
|
||||
Reference in New Issue
Block a user