Presentation is loading. Please wait.

Presentation is loading. Please wait.

1 Chapter 7 Advanced Pathfinding Techniques improving performance & quality Reference: Game Development Essentials Game Artificial Intelligence.

Similar presentations


Presentation on theme: "1 Chapter 7 Advanced Pathfinding Techniques improving performance & quality Reference: Game Development Essentials Game Artificial Intelligence."— Presentation transcript:

1 1 Chapter 7 Advanced Pathfinding Techniques improving performance & quality Reference: Game Development Essentials Game Artificial Intelligence

2 2 Key Chapter Questions ■What are several causes of slow pathfinding? ■What techniques can be used to address each issue causing slow pathfinding? ■What data structure can be used to quickly determine whether an agent can reach a particular destination? ■What is the advantage of pathfinding a group of agents as a single operation? ■Is a series of short path searches more or less efficient than a single long path search? ■What are two ways to take advantage of a simplified path network hierarchy?

3 3 Pathfinding Performance Optimization Failed Pathfind Operations Dijkstra’s algorithm and A* have the same behavior when no path exists to the destination. Both will examine all of the nodes in the green area before determining that there is no path.

4 4 Pathfinding Performance Optimization Zone Mapping Using the Zone Information The zones 1 through 4 are assigned to nodes in this path network. Zones 1 and 3 will be resolved using a zone equivalency array.

5 5 Pathfinding Performance Optimization Zone Mapping Using Zone Equivalency for Movement Modes The blue area is water. The water nodes are assigned zone values in the same fashion as the white land nodes. The locations A through H are potential starting and ending points for the various vehicles.

6 6 Virtual Players & Waypoint Paths Guild Wars allows the player to click on a location and the game finds a path for the player’s character. In this case, a brief pause for pathfinding is unnoticeable.

7 7 The path search using A* from A to Z examines a large portion of the sample map. This diagram shows the nodes examined colored green and blue. Virtual Players & Waypoint Paths

8 8 Group Pathfinding Starting Point Gather Retreat Heterogeneous Groups

9 9 Group Pathfinding

10 10 Group Pathfinding

11 11 Group Pathfinding

12 12 Group Pathfinding

13 13 Hierarchical Pathfinding The hierarchical network contains a less detailed representation of the path network and requires fewer nodes. The original path network contains 56 nodes and a high level of detail.

14 14 Hierarchical Pathfinding Intermediate Destinations: Creating Shorter Paths The hierarchical data can be used to create a series of intermediate destinations. In this case, the agent can move from A to Z by following a series of short paths from A→H6, H6→H7, H7→H8, and finally H8→Z.

15 15 Hierarchical Pathfinding Pruning the Network This path search would only consider the nodes shown (24 rather than 56).


Download ppt "1 Chapter 7 Advanced Pathfinding Techniques improving performance & quality Reference: Game Development Essentials Game Artificial Intelligence."

Similar presentations


Ads by Google