Check if units are in the world in UnitRenderer::PickAllEntitiesAtPoint. Probably fixes #3587, though I'm not sure as it proved unreproducible.

This was SVN commit r17228.
This commit is contained in:
wraitii 2015-11-11 13:27:13 +00:00
parent 1b00bfc98d
commit 607955489d

View File

@ -274,7 +274,7 @@ public:
for (size_t i = 0; i < m_Units.size(); ++i)
{
SUnit& unit = m_Units[i];
if (!unit.actor)
if (!unit.actor || !unit.inWorld)
continue;
if (unit.sweptBounds.RayIntersect(origin, dir))
candidates.push_back(&unit);