Quote:
Originally Posted by kingcj
Before I do this I wanted to run it by someone and possibly get some feedback.
Could I set a group of variables up to check the tiles and then direct the npc to non-blocking tiles closest to its destination? It sounds possible, but it would be a lot of code and then some equations to determine which non-blocking tiles are closer to the npcs destination. Also is there a way to cycle through the variables to input them into the equation? (such as with a loop?)
|
You are on your way to describing
A*. Again, this won't work well for a maze.
If you are doing some other sort of path finding where you don't
need to get to your destination, then A* is your best bet.