c++ - Algorithm for finding path to point -
I'm not sure if I describe it properly, but basically I have an object on point X, And I want the algorithm which can get this point on x ', y' but as it is to show its path, I can revive it. I am creating a tile game and when the game starts, I want to magically place the tiles in a good 2D array. That's why I will generate a random coordination and then say it to go to my goal within 50 frames. Thank you
It seems that you just want a linear transformation. Like
Xt = ((X'-X) / t) * t, + yt = ((y'-y) / t) * t) + y
Or coordinate for a tile on time in English with its path T / Total_frame length is A * redundancy if you are not trying to avoid obstacles.
Comments
Post a Comment