Move Navmesh code away from dPhysics (#701)

This commit is contained in:
Jett
2022-08-02 06:30:19 +01:00
committed by GitHub
parent a0aa8b2854
commit 9ee219ea42
13 changed files with 349 additions and 323 deletions

View File

@@ -654,7 +654,7 @@ void BaseCombatAIComponent::Wander() {
auto destination = m_StartPosition + delta;
if (dpWorld::Instance().IsLoaded()) {
destination.y = dpWorld::Instance().GetHeightAtPoint(destination);
destination.y = dpWorld::Instance().GetNavMesh()->GetHeightAtPoint(destination);
}
if (Vector3::DistanceSquared(destination, m_MovementAI->GetCurrentPosition()) < 2 * 2) {