- Unity 2018 Artificial Intelligence Cookbook(Second Edition)
- Jorge Palacios
- 45字
- 2021-07-16 18:11:38
How it works...
Dijkstra's algorithm works in a similar way to BFS, but considers non-negative edge costs in order to build the best route from the source vertex to every other vertex. That's why we have an array for storing what the previous vertex is.