Ignore non-3D agents in the navigator

7098-improve-post-process-behavior-with-transparent-objects
Evil Eye 2 years ago
parent 4daac2b816
commit d40c09c18c

@ -16,7 +16,8 @@ namespace DetourNavigator
void NavigatorImpl::addAgent(const AgentBounds& agentBounds)
{
if (agentBounds.mHalfExtents.length2() <= 0)
if (agentBounds.mHalfExtents.x() == 0.f || agentBounds.mHalfExtents.y() == 0.f
|| agentBounds.mHalfExtents.z() == 0.f)
return;
++mAgents[agentBounds];
mNavMeshManager.addAgent(agentBounds);

Loading…
Cancel
Save