Path finder was not clearing closed flag properly.

This commit is contained in:
Mikko Mononen 2009-10-01 20:37:08 +00:00
parent ed73b46308
commit 587dfb80f8

View File

@ -757,7 +757,7 @@ int dtTiledNavMesh::findPath(dtTilePolyRef startRef, dtTilePolyRef endRef,
if (!((actualNode->flags & DT_NODE_OPEN) && newNode.total > actualNode->total) &&
!((actualNode->flags & DT_NODE_CLOSED) && newNode.total > actualNode->total))
{
actualNode->flags &= DT_NODE_CLOSED;
actualNode->flags &= ~DT_NODE_CLOSED;
actualNode->pidx = newNode.pidx;
actualNode->cost = newNode.cost;
actualNode->total = newNode.total;