Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice

Bug NavMeshAgent on player causes player to get stuck when moving

Discussion in 'Navigation' started by QueenRosa, Oct 16, 2023.

  1. QueenRosa

    QueenRosa

    Joined:
    May 10, 2023
    Posts:
    16
    After adding a navmeshagent to my player (so it collides with other agents), it randomly gets stuck when you move it around. Stopping then going forward again seems to solve it, or pressing any other movement key seems to fix it. But why does it get stuck? Confirmed it's a result of having the navmeshagent component. why? I don't know.

    The player uses Unity's input system for movement, nothing code-related is the source, it also has a boxcollider2D, and a rigidbody.

    Video of problem: https://files.fm/u/v242e4z8tf




    The navmeshagent settings are just default, but even playing around with it a bit doesn't seem to solve anything.




    Aside from this issue, everything works fine. Just not sure why this is occuring if anyone can help figure out why.

    Also, the issue mainly seems to be when moving in an upward or downward motion, pressing two motion keys at once seems to avoid the issue, but i dont know why its happening in the first place.