MCPcopy Create free account
hub / github.com/axmolengine/axmol / isValidPolyRef

Method isValidPolyRef

3rdparty/recast/DetourNavMeshQuery.cpp:3657–3669  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3655}
3656
3657bool dtNavMeshQuery::isValidPolyRef(dtPolyRef ref, const dtQueryFilter* filter) const
3658{
3659 const dtMeshTile* tile = 0;
3660 const dtPoly* poly = 0;
3661 dtStatus status = m_nav->getTileAndPolyByRef(ref, &tile, &poly);
3662 // If cannot get polygon, assume it does not exists and boundary is invalid.
3663 if (dtStatusFailed(status))
3664 return false;
3665 // If cannot pass filter, assume flags has changed and boundary is invalid.
3666 if (!filter->passFilter(ref, tile, poly))
3667 return false;
3668 return true;
3669}
3670
3671/// @par
3672///

Callers 12

closestPointOnPolyMethod · 0.45
findPathMethod · 0.45
initSlicedFindPathMethod · 0.45
updateSlicedFindPathMethod · 0.45
moveAlongSurfaceMethod · 0.45
raycastMethod · 0.45
findPolysAroundCircleMethod · 0.45
findPolysAroundShapeMethod · 0.45
findDistanceToWallMethod · 0.45

Calls 3

dtStatusFailedFunction · 0.85
getTileAndPolyByRefMethod · 0.80
passFilterMethod · 0.80

Tested by

no test coverage detected