Jump to content
  • Advertisement


This topic is now archived and is closed to further replies.


Pathfinding in staggered map again...

This topic is 6113 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

i''m using a priority-DFS search for pathfinding, and i still cant find the right "grade" function... (next proccessed node, will have the lowest grade) what i do, is that i give each node a grade, like A*. right now, i''ve transffered all my map coordinates to on-screen ones, cause i cant find a way to calculate the function for them. so right now, my function is : grade = sqr((destx - branchx)*(destx - branchx) + (destx - branchy)*(destx - branchy)) as if i was calculating c^2 = a^2 + b^2 which should give me the distance between the two points if i remember right from my math class. just wondering if theres a better grade/price system, cause it doesnt really give me the realistice path between the two points. and i dont mean to add heuristics for now, just how to find a "natural" path 10x, Gil

Share this post

Link to post
Share on other sites

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!