Recast & Detour XZY left overs to XYZ

Height should be set on the z axis.
This commit is contained in:
Kawe Mazidjatari 2022-10-22 21:46:59 +02:00
parent 73866c860b
commit 56dd3802f8
3 changed files with 3 additions and 3 deletions

View File

@ -553,7 +553,7 @@ void NavMeshTesterTool::handleToggle()
float h = 0;
m_navQuery->getPolyHeight(m_pathIterPolys[0], result, &h);
result[1] = h;
result[2] = h;
dtVcopy(m_iterPos, result);
// Handle end of path and off-mesh links when close enough.

View File

@ -288,7 +288,7 @@ void TestCase::doTests(dtNavMesh* navmesh, dtNavMeshQuery* navquery)
{
float h = 0;
navquery->getPolyHeight(polys[iter->npolys-1], hitPos, &h);
hitPos[1] = h;
hitPos[2] = h;
}
dtVcopy(&iter->straight[3], hitPos);

View File

@ -492,7 +492,7 @@ dtStatus dtNavMeshQuery::findRandomPointAroundCircle(dtPolyRef startRef, const f
dtStatus stat = getPolyHeight(randomPolyRef, pt, &h);
if (dtStatusFailed(status))
return stat;
pt[1] = h;
pt[2] = h;
dtVcopy(randomPt, pt);
*randomRef = randomPolyRef;