Skip to content

Infinite loop when generating random points inside volume #5

@AxelHolmPigs

Description

@AxelHolmPigs

The navigation algorithm sometimes causes an infinite loop in the attached sample project, making the engine freeze. In this project there is an agent that randomly generates points inside the volume and navigates to it. Unfortunately I do not recognize a pattern in the points that cause the loop, other than that they are not inside of something would block the agent and that it is usually close to the edge of the volume.

The infinite loop itself has consistently been caused by line 56 in AeonixMediator.cpp due to node.Code being 0 while the sought morton code is 2. Since the layer only contains a single node with the code 0 it will loop indefinitely.

AenixNavigationProject.zip

This diff "fixes" the issue by just ending early if no node with the given code is found in the bottom layer.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions