diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp index 4f2aaa8601..0a2d588f58 100644 --- a/src/server/game/Entities/Unit/Unit.cpp +++ b/src/server/game/Entities/Unit/Unit.cpp @@ -4143,12 +4143,12 @@ void Unit::RemoveAurasByType(AuraType auraType, ObjectGuid casterGUID, Aura* exc } } -void Unit::RemoveAurasWithAttribute(uint32 flags) +void Unit::RemoveAurasWithAttribute(SpellAttr0 flags) { for (AuraApplicationMap::iterator iter = m_appliedAuras.begin(); iter != m_appliedAuras.end();) { SpellInfo const* spell = iter->second->GetBase()->GetSpellInfo(); - if (spell->Attributes & flags) + if (spell->HasAttribute(flags)) RemoveAura(iter); else ++iter; diff --git a/src/server/game/Entities/Unit/Unit.h b/src/server/game/Entities/Unit/Unit.h index 2d341e7c71..b8901dae28 100644 --- a/src/server/game/Entities/Unit/Unit.h +++ b/src/server/game/Entities/Unit/Unit.h @@ -1318,7 +1318,7 @@ class TC_GAME_API Unit : public WorldObject void RemoveNotOwnSingleTargetAuras(bool onPhaseChange = false); template void RemoveAurasWithInterruptFlags(InterruptFlags flag, SpellInfo const* source = nullptr); - void RemoveAurasWithAttribute(uint32 flags); + void RemoveAurasWithAttribute(SpellAttr0 flags); void RemoveAurasWithFamily(SpellFamilyNames family, flag128 const& familyFlag, ObjectGuid casterGUID); void RemoveAurasWithMechanic(uint64 mechanicMaskToRemove, AuraRemoveMode removeMode = AURA_REMOVE_BY_DEFAULT, uint32 exceptSpellId = 0, bool withEffectMechanics = false); void RemoveMovementImpairingAuras(bool withRoot); diff --git a/src/server/game/Spells/SpellInfo.cpp b/src/server/game/Spells/SpellInfo.cpp index 5cb53bd811..eb70102626 100644 --- a/src/server/game/Spells/SpellInfo.cpp +++ b/src/server/game/Spells/SpellInfo.cpp @@ -1905,7 +1905,7 @@ bool SpellInfo::IsRangedWeaponSpell() const { return (SpellFamilyName == SPELLFAMILY_HUNTER && !(SpellFamilyFlags[1] & 0x10000000)) // for 53352, cannot find better way || (EquippedItemSubClassMask & ITEM_SUBCLASS_MASK_WEAPON_RANGED) - || (Attributes & SPELL_ATTR0_USES_RANGED_SLOT); + || (HasAttribute(SPELL_ATTR0_USES_RANGED_SLOT)); } bool SpellInfo::IsAutoRepeatRangedSpell() const