*(More) correct implementation of SPELL_EFFECT_PULL_TOWARDS_DEST(145)

--HG--
branch : trunk
This commit is contained in:
QAston
2010-08-09 02:31:42 +02:00
parent abd261b1a1
commit fa8a826656
4 changed files with 23 additions and 10 deletions

View File

@@ -231,7 +231,7 @@ void SpellCastTargets::Update(Unit* caster)
m_itemTargetEntry = m_itemTarget->GetEntry();
}
// update positions by transport move
if (m_srcTransGUID)
if (HasSrc() && m_srcTransGUID)
{
if (WorldObject * transport = ObjectAccessor::GetWorldObject(*caster, m_srcTransGUID))
{
@@ -239,7 +239,7 @@ void SpellCastTargets::Update(Unit* caster)
m_srcPos.RelocateOffset(m_srcTransOffset);
}
}
if (m_dstTransGUID)
if (HasDst() && m_dstTransGUID)
{
if (WorldObject * transport = ObjectAccessor::GetWorldObject(*caster, m_dstTransGUID))
{