|
-
If you look into implementing A* pathfinding you'll find it's easier to first implement breadth-first pathfinding (an equivalent system which is a bit slower). The only difference between the two is that instead of keeping an array of 'to-do' paths, you keep them in a 'priority queue' which is basically a data structure where they are kept sorted by distance.
When you get to that stage you'll find this AS3 data structure library extremely useful as it includes priority queues in AS3.
The good thing is that you get the same results with breadth-first vs A*, it's just more efficient with A*. So for my game at least, moving to A* is a job for later, when optimising
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|