Skip to content
This repository has been archived by the owner on Jan 5, 2024. It is now read-only.

Commit

Permalink
Block for pathing requests only
Browse files Browse the repository at this point in the history
  • Loading branch information
Causeless committed Dec 30, 2023
1 parent c996ee7 commit 9e4b088
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Entities/Scene.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3125,7 +3125,8 @@ void Scene::Update()

if (m_NavigatableAreasUpToDate == false) {
// Need to block until all current pathfinding requests are finished. Ugh, if only we had a better way (interrupt/cancel a path request to start a new one?)
g_ThreadMan.GetBackgroundThreadPool().wait_for_tasks();
// TODO: Make the PathRequest struct more capable and maybe we can delay starting or cancel mid-request?
BlockUntilAllPathingRequestsComplete();

m_NavigatableAreasUpToDate = true;
for (int team = Activity::Teams::NoTeam; team < Activity::Teams::MaxTeamCount; ++team) {
Expand Down

0 comments on commit 9e4b088

Please sign in to comment.