- Home /
NavMeshAgent & slope issue
Hi
I have a character with that newmeshagent, when the terrain is flat everything works as expected.
But if here is any slope the character is like falling a bit (falling on the slope) when it reached the destination and he is also rotating.
I have tried to set the angular velocity to 0 when the destination is reached, to increase the stop distance etc
Help please
do u got solution , I am also facing same issue , my issue
As I remember, I had forgotten to update the navmesh to the terrain and my mesh was like flat when in fact the terrain wasnt I dont exactly remember where you can update it, look on your navmesheagznt settigs maybe
@im$$anonymous$$4TT I tried everything , then its not moving perfectly on slope
@nipunIT did you tried to bake the terrain as I mentioned before ? https://docs.unity3d.com/uploads/$$anonymous$$ain/Nav$$anonymous$$eshSetupBake.svg ( part 4 on this pict ) You can also look, if it's not already done, to the max slope & others settings
Check this too
@im$$anonymous$$4TT , I tried all possibility of baking, I am not using terrain, I used road using blender. See this Question and property
Answer by tormentoarmagedoom · Jul 11, 2018 at 07:37 AM
Good day.
If your nave mesh agent is moving the object as you want, and the problem is only when it reaches the destination, the problem is not in the navmesh agent.
Once it reaches the destination, it will stay "inactive" until new destination is set.
So when is "quiet", if it goes down the hill, is due gravity. It have a rigidboy right?
You can set the rigidbody as "No use gravity" and "Kinematic" (this means only code will move it).
And i supose the problem will gone :D
Bye!
Yep, when I set the rigidbody as $$anonymous$$inematic, he don't fall, it's perfect.
I already tried to disable the gravity but that didnt worked.
$$anonymous$$any thanks =)
Your answer
Follow this Question
Related Questions
NavmeshAgent Behavior 0 Answers
No player is colliding with enemy even with capsule collider !!! Please me help me. 0 Answers
NavMeshAgent Not Working? 1 Answer
A way to check if an off mesh link is nearby? 0 Answers
Problem with AI and pathfinding. 2 Answers