Skip to content

Commit

Permalink
Fix transient areas not getting unblocked (#330)
Browse files Browse the repository at this point in the history
  • Loading branch information
TotallyMehis committed Oct 15, 2021
1 parent 5c23538 commit 28a7fc9
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions mp/src/game/server/zmr/nav/zmr_nav_mesh.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -108,10 +108,9 @@ void CZMRNavMesh::UpdateTransientAreas()
{
auto* area = static_cast<CZMRNavArea*>( areas[i] );

// No floor areas are updated separately.
if ( area->GetAttributes() & NAV_MESH_ZMR_NOFLOOR )
continue;
if ( area->IsBlocked( TEAM_ANY ) )
continue;


area->GetWorldBounds( mins, maxs );
Expand Down Expand Up @@ -147,6 +146,10 @@ void CZMRNavMesh::UpdateTransientAreas()
{
area->MarkAsBlocked( TEAM_ANY, nullptr );
}
else if ( area->IsBlocked( TEAM_ANY ) )
{
area->UnblockArea( TEAM_ANY );
}
}
}

Expand Down

0 comments on commit 28a7fc9

Please sign in to comment.