AStar
AStar copied to clipboard
just question
Thank you. Your code is very useful I am interested in Different agent sizes how can i use that in your before branch 'feature/improve_string_pulling'?
Heya,
There was never an official release that supported different agent sizes, however the feature was enabled on the master branch for a while. I think its best if you check out the master branch at commit 75c18871424e8b5312959e8bba287d179b34db26 and work with that version.
However, there is a good reason why I don't officially support multiple agent sizes. Checking if a a 2x2 agent fits is more than 4x slower than checking if a 1x1 agent fits, and it gets worse the larger the agent gets. There are two better approaches:
-
Use the latest version of my library and manage a different grid/graph per agent size. This requires a bit more management from your side but retains the speed.
-
Use a different algorithm that's designed to work with different sized agents. A good algorithm to look at is the Explicit Corridor Map Model. I'm pretty sure the original researchers (one of which was my supervisor, so I might be a bit biased) made a Unity plugin. To give you an idea of how it works see this gif: https://webspace.science.uu.nl/~gerae101/images/explicitCorridor.gif
Thank you for quick response. I will try as your advice. The performance doesn't matter because I only need it to work.