8-direction path finding algorithm

Posted by frinkz on Stack Overflow See other posts from Stack Overflow or by frinkz
Published on 2010-04-06T22:38:41Z Indexed on 2010/04/06 22:43 UTC
Read the original article Hit count: 360

Filed under:
|
|

I'm having trouble finding the right pathfinding algorithm for some AI I'm working on.

I have players on a pitch, moving around freely (not stuck to a grid), but they are confined to moving in 8 directions (N NE E etc.)

I was working on using A*, and a graph for this. But I realised, every node on the graph is equally far apart, and all the edges have the same weight - since the pitch is rectangular. And the number of nodes is enormous (being a large pitch, with them able to move between 1 pixel and another)

I figured there must be another algorithm, optimised for this sort of thing?

© Stack Overflow or respective owner

Related posts about path

Related posts about finding