aboutsummaryrefslogtreecommitdiff
path: root/src/game/SpellAuras.cpp
diff options
context:
space:
mode:
authormegamage <none@none>2009-07-31 10:51:02 +0800
committermegamage <none@none>2009-07-31 10:51:02 +0800
commit62e31f41e4fdaf09f731959916191abb2b543039 (patch)
treef263e564322bd72db7fe26fbff683f224e8a47c6 /src/game/SpellAuras.cpp
parent0a2af88cb455bad8166140e544c829c405055628 (diff)
*Skip [8257] Avoid remove daze and croud control spells except polymorph at druid form change. Author: Astellar
--HG-- branch : trunk
Diffstat (limited to 'src/game/SpellAuras.cpp')
-rw-r--r--src/game/SpellAuras.cpp24
1 files changed, 24 insertions, 0 deletions
diff --git a/src/game/SpellAuras.cpp b/src/game/SpellAuras.cpp
index 6ac842128b7..eef918ae5e8 100644
--- a/src/game/SpellAuras.cpp
+++ b/src/game/SpellAuras.cpp
@@ -3235,13 +3235,37 @@ void AuraEffect::HandleAuraModShapeshift(bool apply, bool Real, bool changeAmoun
case FORM_FLIGHT_EPIC:
case FORM_FLIGHT:
case FORM_MOONKIN:
+ {
// remove movement affects
m_target->RemoveMovementImpairingAuras();
+/*
+ m_target->RemoveSpellsCausingAura(SPELL_AURA_MOD_ROOT);
+ Unit::AuraList const& slowingAuras = m_target->GetAurasByType(SPELL_AURA_MOD_DECREASE_SPEED);
+ for (Unit::AuraList::const_iterator iter = slowingAuras.begin(); iter != slowingAuras.end();)
+ {
+ SpellEntry const* aurSpellInfo = (*iter)->GetSpellProto();
+
+ // If spell that caused this aura has Croud Control or Daze effect
+ if((GetAllSpellMechanicMask(aurSpellInfo) & MECHANIC_NOT_REMOVED_BY_SHAPESHIFT) ||
+ // some Daze spells have these parameters instead of MECHANIC_DAZE
+ (aurSpellInfo->SpellIconID == 15 && aurSpellInfo->Dispel == 0))
+ {
+ ++iter;
+ continue;
+ }
+
+ // All OK, remove aura now
+ m_target->RemoveAurasDueToSpellByCancel(aurSpellInfo->Id);
+ iter = slowingAuras.begin();
+ }
+*/
// and polymorphic affects
if(m_target->IsPolymorphed())
m_target->RemoveAurasDueToSpell(m_target->getTransForm());
+
break;
+ }
default:
break;
}