mirror of
https://github.com/mangosfour/server.git
synced 2025-12-15 19:37:02 +00:00
[12108] Add RemoveSpellsCausingAura to remove auras of type and caster
This commit is contained in:
parent
07d4c15dbb
commit
88e18898e2
3 changed files with 16 additions and 1 deletions
|
|
@ -778,6 +778,20 @@ void Unit::RemoveSpellsCausingAura(AuraType auraType, SpellAuraHolder* except)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void Unit::RemoveSpellsCausingAura(AuraType auraType, ObjectGuid casterGuid)
|
||||||
|
{
|
||||||
|
for (AuraList::const_iterator iter = m_modAuras[auraType].begin(); iter != m_modAuras[auraType].end();)
|
||||||
|
{
|
||||||
|
if ((*iter)->GetCasterGuid() == casterGuid)
|
||||||
|
{
|
||||||
|
RemoveAuraHolderFromStack((*iter)->GetId(), 1, casterGuid);
|
||||||
|
iter = m_modAuras[auraType].begin();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
++iter;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
void Unit::DealDamageMods(Unit* pVictim, uint32& damage, uint32* absorb)
|
void Unit::DealDamageMods(Unit* pVictim, uint32& damage, uint32* absorb)
|
||||||
{
|
{
|
||||||
if (!pVictim->isAlive() || pVictim->IsTaxiFlying() || (pVictim->GetTypeId() == TYPEID_UNIT && ((Creature*)pVictim)->IsInEvadeMode()))
|
if (!pVictim->isAlive() || pVictim->IsTaxiFlying() || (pVictim->GetTypeId() == TYPEID_UNIT && ((Creature*)pVictim)->IsInEvadeMode()))
|
||||||
|
|
|
||||||
|
|
@ -1575,6 +1575,7 @@ class MANGOS_DLL_SPEC Unit : public WorldObject
|
||||||
void RemoveAurasAtMechanicImmunity(uint32 mechMask, uint32 exceptSpellId, bool non_positive = false);
|
void RemoveAurasAtMechanicImmunity(uint32 mechMask, uint32 exceptSpellId, bool non_positive = false);
|
||||||
void RemoveSpellsCausingAura(AuraType auraType);
|
void RemoveSpellsCausingAura(AuraType auraType);
|
||||||
void RemoveSpellsCausingAura(AuraType auraType, SpellAuraHolder* except);
|
void RemoveSpellsCausingAura(AuraType auraType, SpellAuraHolder* except);
|
||||||
|
void RemoveSpellsCausingAura(AuraType auraType, ObjectGuid casterGuid);
|
||||||
void RemoveRankAurasDueToSpell(uint32 spellId);
|
void RemoveRankAurasDueToSpell(uint32 spellId);
|
||||||
bool RemoveNoStackAurasDueToAuraHolder(SpellAuraHolder* holder);
|
bool RemoveNoStackAurasDueToAuraHolder(SpellAuraHolder* holder);
|
||||||
void RemoveAurasWithInterruptFlags(uint32 flags);
|
void RemoveAurasWithInterruptFlags(uint32 flags);
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
#ifndef __REVISION_NR_H__
|
#ifndef __REVISION_NR_H__
|
||||||
#define __REVISION_NR_H__
|
#define __REVISION_NR_H__
|
||||||
#define REVISION_NR "0152"
|
#define REVISION_NR "12108"
|
||||||
#endif // __REVISION_NR_H__
|
#endif // __REVISION_NR_H__
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue