Well, I read the API but I couldn’t really understand so can someone explain it to me and provide some piece of code if possible, please?
1 Like
This is odd, I found an algorithm similar to this. I also found a developer hub link
https://developer.roblox.com/en-us/recipes/dijkstra-s-algorithm
Based on the function above, Dijkstra’s Algorithm works as follows:
- It adds a starting node to the
closedset.- For every node in the
closedset, it finds all the adjacent nodes and adds the distance traveled from the parent node to the distance to the next node. If there are two nodes in theclosedset that share a neighbor, it gives the neighboring node the shorter distance.- It finds the node with the shortest distance.
- It adds the node to
closedset. If node is the goal, the process ends. Otherwise, it repeats from step 2.
The website has some sample of code which might help you understand, but also youtube videos I have found about this.
Edit:
Uh also, no clue why it’s like this but be aware of this function section part of the code
and the end at the bottom

