Improper output

I just purchased the Pro version from this website, and was working through the step-by-step tutorial, and am getting strange outputs, or at least not what I expect (the only difference between the tutorial, and mine is the layout).

1st) I give the agent a location even a good hundred units away, but the algorithm only returns “1 node” it still shows the correct line, but only 1 node when told to travel in a straight line which at least in my mind states that it could potentially make the entire distance in 1 time slice step (at least from my understanding of A*) it does deliver more nodes, but only when i give it something that it must turn, but it doesn’t always want to turn (see 2nd) I have to give it something on a different elevation that it must turn to go up a ramp.

2nd) the agent is completely ignoring the Collision testing->Mask I have tried using both layers(according to the tutorial), and tags (according to the other documentation sections) (the documentation seems to almost talk about these interchangeable as far as I am understanding, but I know they are very different)

3rd) the console does not always display the end result log output “the first time” it will give me the search time (low number in ms, and shows no errors), but I have to stop, and run the game a second time to have it output the log() call.

Interesting.

  1. Have you per chance attached the Funnel Modifier to your GameObject? The funnel modifier would give the output you describe. However 1 node (or more correctly one edge in the path) does not equal one unit of distance. The segments can have varying length, however on grid graphs, they are usually (without using any modifiers and not taking into account slope) the same length.

  2. That is also quite interesting. Make sure the obstacles you are want to be avoided are present at scan time, have colliders which are not triggers, and are in a layer included by the collision mask. Also make sure the height testing is set up correctly.

  3. Hm, I have heard this from another user. He said that sometimes the pathfinder would fail to return any paths (which is what has happened when you do not get the log message without having turned it off). Do you have a small example scene where this is happening which you could send to me?

have sent example to your email address along with pictures.

  1. have not applied any modifier besides smooth, and only shows 1 line, and the node count is 1. even without the smooth modifier.
  2. they are assigned to the layer, have colliders. Height testing?
  3. seems to only really apply when changes are made to the A* object (with or without scan), or the scene in general, but now only seems to happen when major changes are made (even to the camera?)

Hi

  1. In the example scene you sent me, almost all nodes are unwalkable so it will rely on the Seeker -> Start End Modifier to assign the nodes. What it will actually do is to find the closest node to the player, and path from that node to the closest node to the target (which happens to be the same node), then the Start End Modifier modifies the start and end points of the path to the exact points you requested which yields this weird looking path. You can edit the StartEndModifier settings and you can also lower the Max Nearest Node distance in A* Inspector -> Settings.

  2. Your graph had a center at Y=1 which was above the ground, therefore it would never find the ground and set it as unwalkable since “Unwalkable When No Ground” in height testing was enabled.

  3. I haven’t been able to replicate that, I will try on windows later (on osx currently).

so after moving the center to (0,-.1,0) don’t remember my reasoning for putting it above the ground (think the A* object has to be touching or interpenetrating the ground) now I am getting an almost comical path result (at least funny to me) the path seems to include zigzags, and loops. it still tries to reach the goal, but almost like it is drunk.

I am also having an issue where it is rubbing against corners of objects in the obstacles layer. kind of like it is trying to cut corners on the path generated by the algorithm.

point 3 from above still persists, but I am starting to think it is a performance/caching issue where sometimes if I make a change to the A* object, and it does not respond immediately (like with subsequent runs) it will eventually almost like it is taking a little to wake up, but works fine every time after the first run since the A* object has been modified.

The first issue has been resolved. The weird paths were due an incorrectly set up path modifier.
Point 3 has still not been resolved, the problem is that I cannot replicate it…