From 1d95ae7555ca7042aac76bc4e4d61159bfb210a8 Mon Sep 17 00:00:00 2001 From: Sarjuuk Date: Sun, 22 Mar 2009 06:33:33 +0300 Subject: [PATCH] [7516] Add form/mounting/self control loss limitations to 48505 and ranks. Signed-off-by: VladimirMangos --- src/game/SpellEffects.cpp | 12 ++++++++++++ src/shared/revision_nr.h | 2 +- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/src/game/SpellEffects.cpp b/src/game/SpellEffects.cpp index ace5eade1..51bd8e48e 100644 --- a/src/game/SpellEffects.cpp +++ b/src/game/SpellEffects.cpp @@ -1367,6 +1367,18 @@ void Spell::EffectDummy(uint32 i) // Starfall if (m_spellInfo->SpellFamilyFlags2 & 0x00000100LL) { + //Shapeshifting into an animal form or mounting cancels the effect. + if(m_caster->GetCreatureType() == CREATURE_TYPE_BEAST || m_caster->IsMounted()) + { + if(m_triggeredByAuraSpell) + m_caster->RemoveAurasDueToSpell(m_triggeredByAuraSpell->Id); + return; + } + + //Any effect which causes you to lose control of your character will supress the starfall effect. + if(m_caster->hasUnitState(UNIT_STAT_STUNNED | UNIT_STAT_FLEEING | UNIT_STAT_ROOT | UNIT_STAT_CONFUSED)) + return; + switch(m_spellInfo->Id) { case 50286: m_caster->CastSpell(unitTarget, 50288, true); return; diff --git a/src/shared/revision_nr.h b/src/shared/revision_nr.h index 37325603e..9a60cb66f 100644 --- a/src/shared/revision_nr.h +++ b/src/shared/revision_nr.h @@ -1,4 +1,4 @@ #ifndef __REVISION_NR_H__ #define __REVISION_NR_H__ - #define REVISION_NR "7515" + #define REVISION_NR "7516" #endif // __REVISION_NR_H__