AI Movement Delay Problem

Hey all,

I have free roaming AI that was working fine, but after I adjusted my NavMesh to better fit the world, the AI wont start walking around until it’s run through it’s first 30 second loop. It will sit there for 30 seconds and then activate. I had no issue before I slightly changed the NavMesh, but don’t see why this would occur?

Since it’s done on begin play, you haven’t set new location yet.
By default, it’ll be set to 0,0,0. With your new nav-mesh, 0,0,0 is probably out of range.
Call set new destination before AI move to rather than after.

Also, you should have your logic run off of OnSuccess and OnFail (connect both nodes to the next node) rather than using a delay.
You may want to add a delay after anyways so they’ll wait around for a moment, but it definitely should not be a 30 second wait.

Side note- I highly recommend not making AI logic in blueprints. You should use behavior trees- they’re much easier to work with and visualize.

This did the trick, thank you!

1 Like