Pathfinding Help
BlitzMax Forums/BlitzMax Programming/Pathfinding Help
| ||
Hello, Can someone please run this code, and help me figure out where my pathfinding is broken please?? *Updated Code a bit, NOW IT WORKS!!!* Thanks, |
| ||
Read my code archive entry on Dijkstra map pathfinding. You may find it somewhat easier to conceptualize. |
| ||
Yep dijkstra pathfinding is easy to implement. ... I second that idea. |
| ||
Yeah I looked at the Dijkstra and its good, but I'm working on my Dwarf mining game, and notices performance issues with it. I came up with my own path finding that seems to work for the most part, but then things start to get stuck with they are directly to the left of the target or top of the target. I will look at the Dijkstra again because it doesn't seem to require as much. Thanks, FBEpyon |
| ||
For the love of god, don't use Djikstra's if a heuristic is available. Try checking this out: http://www.policyalmanac.org/games/aStarTutorial.htm |
| ||
Hi, there is also Astar demo in blitmax / samples folder. -Henri |
| ||
@Pineapple@ Thanks for the information I will go over it a bit more.. :P I have most of what I need in the above code, but I'm not sure were the path is getting messed up at.. :( **UPDATED** THIS IS FULLY WORKING NOW!! Thanks for all the help!! |
| ||
Pineapple you can precache Dijkstra maps :) Don't discount them if you don't know what they are, they're different from the Dijkstra algorithm. They also allow INCREDIBLY simple AI that can look extremely lifelike. Really if you use the maps it's closer to potential fields than it is to A* or the Dijkstra algorithm. |