Jump to content
  • 0

Calculate Shortest Route


Question

Posted (edited)

Good day everyone. Can someone help me with this? Calculate the shortest route between two points in a map and return all the coordinates? 

For example in prontera: (156,191) to (224,131) it will return coordinates of the shortest route to reach 224, 131

The idea is like a bot walking from x1,y1 to x2,y2. I don't know which algorithm to use and I'm new to C. Thank you in advance.

Edit: I found this repo: https://github.com/Henrybk/Openkore-Pathfinding/blob/master/Pathfinding.c

Edited by x13th

2 answers to this question

Recommended Posts

  • 0
Posted

Not related answer, just wanna let you know,

This path finding algorith will be a huge pain if the calculations are handled by the server, you need to do this on client side via modding the client or 3rd party,

 

 

  • 0
Posted
On 9/15/2017 at 7:59 PM, benching said:

Not related answer, just wanna let you know,

This path finding algorith will be a huge pain if the calculations are handled by the server, you need to do this on client side via modding the client or 3rd party,

 

 

Hmm. I already got the solution and its working, although I havent tested it with many users in the server. Thanks!

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...