RafaelBarbosatec / a_star

Package that uses the A * algorithm to find a way to the destination through the barriers.
MIT License
17 stars 10 forks source link

Feature/a star for tbs #2

Closed Sproute777 closed 4 months ago

Sproute777 commented 1 year ago

improve search algorithm for land with diffrents cost like water,forest added new target type

RafaelBarbosatec commented 1 year ago

Hi @Sproute777 ! You made a great work here! Congratulations! I have some questions:

Sproute777 commented 1 year ago

Hi @Sproute777 ! You made a great work here! Congratulations! I have some questions:

LandCost is used to build a map with different movement costs for the Tile. For example, movement on water or mud. The speed of movement through this territory will require much greater costs than a detour.

In the example there is a button with which you can build, for example, a river and see how the path will be built.

Sproute777 commented 1 year ago

Hi @Sproute777 ! You made a great work here! Congratulations! I have some questions:

Targets are used for enemies as Barrier, but sometimes you want to build a path to this goal. You can exclude these checks, but other way you have to add the target

Sproute777 commented 1 year ago

Hi @Sproute777 ! You made a great work here! Congratulations! I have some questions:

  • What is landCosts and targets?
  • What beheavor about that news elements?

Targets are used for enemies as Barrier, but sometimes you want to build a path to this goal. You can exclude these checks, but then you will have to add the target manually.

in Targets it has a movement cost, if for example there is a flying unit then you can calculate other types of pathfinding.

Targets and Allies for others type of path findings, for different mechanics path movement I will think how can improve this

RafaelBarbosatec commented 12 months ago

Goo job @Sproute777 ! Something else do change? I can do review this PR?

RafaelBarbosatec commented 12 months ago

When you finish, pls update README with your news functionalities

Sproute777 commented 12 months ago

When you finish, pls update README with your news functionalities Done.

Sproute777 commented 12 months ago

All done