From 9d501da1b8ddb4207ad1d983dcaff2a09b390057 Mon Sep 17 00:00:00 2001 From: QAston Date: Wed, 22 Jul 2009 22:52:05 +0200 Subject: *Fix Piercing Shots - by freeganja. *Clear movement generators for unit when removing from world. --HG-- branch : trunk --- src/game/SpellEffects.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/game/SpellEffects.cpp') diff --git a/src/game/SpellEffects.cpp b/src/game/SpellEffects.cpp index 72d59694632..1b13a6673db 100644 --- a/src/game/SpellEffects.cpp +++ b/src/game/SpellEffects.cpp @@ -3368,6 +3368,8 @@ void Spell::EffectSummonType(uint32 i) TempSummonType summonType = (duration == 0) ? TEMPSUMMON_DEAD_DESPAWN : TEMPSUMMON_TIMED_DESPAWN; TempSummon * summon = m_originalCaster->SummonCreature(entry,px,py,pz,m_caster->GetOrientation(),summonType,duration); + if (!summon) + continue; summon->SetUInt64Value(UNIT_FIELD_SUMMONEDBY, m_originalCaster->GetGUID()); if (properties->Category == SUMMON_CATEGORY_ALLY) summon->setFaction(m_originalCaster->getFaction()); -- cgit v1.2.3