0 votes

Title says main issue. I have a minimum spanning tree stored in an AStar Pathfinder object. I want to cycle through each node in the mst and automatically check against every other node in the tree if it can add an edge to that node without intersecting the mst in order to create loops like this


If the edge between two nodes would intersect with the mst, then it is ignored.
How can I implement this intersection detection?
Thank you and if you need any other details, please don't hesitate to ask!

Godot version 3.5
in Engine by (19 points)

Had the exact same dilemma and solved it using this algorithm
Would share code and put an answer but can't seem to find that project....apologies

Please log in or register to answer this question.

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read Frequently asked questions and How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to [email protected] with your username.