fix invalid assert dtAssert(npath < m_maxPath) (#619)

This commit is contained in:
nicknide
2023-07-24 04:22:37 +08:00
committed by GitHub
parent 8a42fb6348
commit 9147d09553

View File

@@ -512,7 +512,7 @@ void dtPathCorridor::setCorridor(const float* target, const dtPolyRef* path, con
{
dtAssert(m_path);
dtAssert(npath > 0);
dtAssert(npath < m_maxPath);
dtAssert(npath <= m_maxPath);
dtVcopy(m_target, target);
memcpy(m_path, path, sizeof(dtPolyRef)*npath);