Pathfinder: Test of Passage

This isn't a game, but it's somewhat fun. The applet below is a pathfinding test. The algorithm is the same as used in Island Forge. This program demonstrates the pathfinding behavior. Use at your own risk. See instructions and details below.




Instructions

Draw some Obstacles. Place a Start and Goal point. Click Pathfind. Optionally change display speed. Click Cancel if you don't think it'll ever end (which, theoretically, it must). Pathfinding will stop as soon as an optimal path is found to the goal.

Explanation

As the pathfinding proceeds, it searches for better and better paths to the goal. I'm using the A* algorithm, but my implementation is not yet fine tuned. As I improve the code, I may update this page from time to time.

Observations

Pathfinding appears to be working. Sometimes the optimal path meanders, but upon inspection appears to be the same distance as a smoother optimal path. Path smoothing can be tweaked in a few ways, which I'll experiment with later.