* Algorithm, navigation grid, Path point pathfinding (A-star vs NavMesh vs Waypoint)

Source: Internet
Author: User
In Unity3d, we commonly used the pathfinding algorithm: 1.a* algorithm plug-in and greedy algorithm is not the same, greedy algorithm suitable for dynamic programming, to find local optimal solution, does not guarantee the optimal solution. A * is the most effective way to solve the shortest path in a static mesh. is also time-consuming algorithm, not to seek frequent occasions. Generally suitable for the needs of precise occasions. As with heuristic search, it is possible to adjust the accuracy according to the change of grid density and grid dissipation. Good place to use: A. Strategy search for strategy game B. Lattice pathfinding in block lattice game 2.u3d self-contained navigation grid system u3d built-in Navmesh navigation grid system, in general, most of the navigation mesh algorithm is "Corner point algorithm", specifically we can check. The efficiency is relatively high, but the optimal solution algorithm is not guaranteed. Use a better place: A. The monster pathfinding in the game Scene B. Motion avoidance obstacle 3.WayPoint pathfinding plug-in is the fastest, but the corresponding performance is also very limited, it often go "Z" type of trajectory, is not suitable for the use of complex occasions. For example, it cannot change the travel path based on width, height, path-point dissipation, etc. Good place to use: A. Tower Defense Monster Marching Path b.ai patrol Route probably a simple one said, in fact, we all have a bottom in mind, what circumstances with what. Does not say that a pathfinding can take all occasions or want to adapt to all occasions. The choices are based on demand.

* Algorithm, navigation grid, Path point pathfinding (A-star vs NavMesh vs Waypoint)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.