*Make position as a class;

--HG--
branch : trunk
This commit is contained in:
megamage committed 2009-08-29 14:58:45 -05:00
1 parent 3aabef53ee
commit 2a4c9bcaf9
26 files changed
+243 -308

No files matched your search

+1 -1
View File
@@ -6636,7 +6636,7 @@ void Spell::SelectTrajTargets()
const float size = std::max((*itr)->GetObjectSize() * 0.7f, 1.0f); // 1/sqrt(3)
// TODO: all calculation should be based on src instead of m_caster
const float objDist2d = (*itr)->GetExactDistance2d(m_targets.m_srcX, m_targets.m_srcY) * cos(m_caster->GetRelativeAngle(*itr));
const float objDist2d = (*itr)->GetExactDist2d(m_targets.m_srcX, m_targets.m_srcY) * cos(m_caster->GetRelativeAngle(*itr));
const float dz = (*itr)->GetPositionZ() - m_targets.m_srcZ;
DEBUG_TRAJ(sLog.outError("Spell::SelectTrajTargets: check %u, dist between %f %f, height between %f %f.", (*itr)->GetEntry(), objDist2d - size, objDist2d + size, dz - size, dz + size);)