This commit is contained in:
hondacrx
2020-08-25 10:08:55 -04:00
parent aecb21d94b
commit 83bb7aaf28
2 changed files with 6 additions and 4 deletions
+6 -3
View File
@@ -4043,9 +4043,12 @@ namespace Game.Spells
if (effectHandleMode == SpellEffectHandleMode.Launch)
{
Position pos = destTarget.GetPosition();
float angle = m_caster.GetRelativeAngle(pos.posX, pos.posY);
float dist = m_caster.GetDistance(pos);
pos = m_caster.GetFirstCollisionPosition(dist, angle);
if (!m_caster.IsWithinLOS(pos.GetPositionX(), pos.GetPositionY(), pos.GetPositionZ()))
{
float angle = m_caster.GetRelativeAngle(pos.posX, pos.posY);
float dist = m_caster.GetDistance(pos);
pos = m_caster.GetFirstCollisionPosition(dist, angle);
}
m_caster.GetMotionMaster().MoveCharge(pos.posX, pos.posY, pos.posZ);
}