Re: A* and multi-goals
- From: Bjorn Reese <breese@xxxxxxxxxxxxx>
- Date: Wed, 01 Mar 2006 22:28:03 +0100
eric.boissard@xxxxxxxxx wrote:
Now I would like to modify it in order to set intermediate goals/nodes
in the path. I want to make sure that the character pass through some
'mandatory' nodes before reaching the final destination. I can have
maybe 3 or 4 intermediate destinations. The order to visit them is not
important. Is there a simple way to do that ? One solution would be to
calculate the cost of each 'intermediate' paths and combine them in
order to get the shortest path to the 'final' goal. Is there a way to
simply 'tweak' the A* algorithm ? Thanks for your help
Create a goal-set, containing all the intermediate goals and the final
goal. Change A* to stop when it has found a path to any one of these
goals. Let the character move to this goal. When the goal is reached,
remove it from the goal-set, and repeat the process until the final
goal has been reached.
--
mail1dotstofanetdotdk
.
- Follow-Ups:
- Re: A* and multi-goals
- From: Rémi
- Re: A* and multi-goals
- References:
- A* and multi-goals
- From: eric . boissard
- A* and multi-goals
- Prev by Date: A* and multi-goals
- Next by Date: Re: A* and multi-goals
- Previous by thread: A* and multi-goals
- Next by thread: Re: A* and multi-goals
- Index(es):
Relevant Pages
|
|