A* Grid Graph Wander and Character Mesh distortion

longshotsg

New member
Hi,

I'm encountering 2 problems.
Using Third Person CC, Behavior designer, behavior movement, a* path finding and all integrations downloaded.

1) Wander stuck at edge. I understand there is a post on this but it's for Recast Graph it seems. I need to use Grid Graph and it doesn't seem to have PointOnNavmesh. So any solutions yet? This looks like a very basic feature.

2) While wandering, my character mesh got distorted(stretched weirdly) while walking around sometimes. Is there some settings that I should change accordingly based on the grid graph?

Thanks.
 
After posting this, I found something that may help some people. Mainly the non programmers I think.
If you look at the demo scene for the Behavior Movement-A* integration,
Assets/Behavior Designer Movement/Integrations/Astar Pathfinding Project/scene.unity

The triangle is confined within 4 walls(Half transparent square red nodes. Unwalkable Nodes).
That's why it never gets stuck at the edges.


My scanned play area has some edges without these square red nodes.
So what I did is:

1) Expand the grid graph a little wider as necessary.
2) Place some objects/mesh at those "open edges" with layer similar to the "Obstacle Layer Mask" in the Pathfinder component in A* game object

Scan again and check if your entire play area is confined within red square nodes.
So far so good.

For those requiring unobstructed edges, you might need additional work but this hack..is better than no solution at least for me.
Hope it helps someone.
 
Unfortunately there really isn't a good way to detect the valid location for non grid graphs. When the destination is set the agent will try to move towards the closest location that it can. This just gave me an idea to select a new destination if the character doesn't move for more than x amount of time.
 
Top