Core/Spells: Rename SpellAttr0 to use official attribute names
Port From (https://github.com/TrinityCore/TrinityCore/commit/a31e6819447626cd7b6967665001ea89bf6a0298)
This commit is contained in:
@@ -79,7 +79,7 @@ namespace Game
|
||||
SpellInfo spell = (flag == ActiveStates.Enabled || flag == ActiveStates.Passive) ? Global.SpellMgr.GetSpellInfo(spellid, pet.GetMap().GetDifficultyID()) : null;
|
||||
if (spell == null)
|
||||
return;
|
||||
if (!spell.HasAttribute(SpellAttr0.CastableWhileDead))
|
||||
if (!spell.HasAttribute(SpellAttr0.AllowCastWhileDead))
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@@ -384,7 +384,7 @@ namespace Game
|
||||
return;
|
||||
|
||||
// not allow remove spells with attr SPELL_ATTR0_CANT_CANCEL
|
||||
if (spellInfo.HasAttribute(SpellAttr0.CantCancel))
|
||||
if (spellInfo.HasAttribute(SpellAttr0.NoAuraCancel))
|
||||
return;
|
||||
|
||||
// channeled spell case (it currently casted then)
|
||||
@@ -412,7 +412,7 @@ namespace Game
|
||||
GetPlayer().RemoveAurasByType(AuraType.ModScale, aurApp =>
|
||||
{
|
||||
SpellInfo spellInfo = aurApp.GetBase().GetSpellInfo();
|
||||
return !spellInfo.HasAttribute(SpellAttr0.CantCancel) && spellInfo.IsPositive() && !spellInfo.IsPassive();
|
||||
return !spellInfo.HasAttribute(SpellAttr0.NoAuraCancel) && spellInfo.IsPositive() && !spellInfo.IsPassive();
|
||||
});
|
||||
}
|
||||
|
||||
@@ -422,7 +422,7 @@ namespace Game
|
||||
GetPlayer().RemoveAurasByType(AuraType.Mounted, aurApp =>
|
||||
{
|
||||
SpellInfo spellInfo = aurApp.GetBase().GetSpellInfo();
|
||||
return !spellInfo.HasAttribute(SpellAttr0.CantCancel) && spellInfo.IsPositive() && !spellInfo.IsPassive();
|
||||
return !spellInfo.HasAttribute(SpellAttr0.NoAuraCancel) && spellInfo.IsPositive() && !spellInfo.IsPassive();
|
||||
});
|
||||
}
|
||||
|
||||
@@ -478,7 +478,7 @@ namespace Game
|
||||
return;
|
||||
|
||||
// not allow remove spells with attr SPELL_ATTR0_CANT_CANCEL
|
||||
if (spellInfo.HasAttribute(SpellAttr0.CantCancel))
|
||||
if (spellInfo.HasAttribute(SpellAttr0.NoAuraCancel))
|
||||
return;
|
||||
|
||||
var spell = mover.GetCurrentSpell(CurrentSpellTypes.Channeled);
|
||||
|
||||
Reference in New Issue
Block a user