Search Unity

Bug Nav Mesh Agent keeps twitching and going backwards

Discussion in 'Navigation' started by mega_zinji, Feb 17, 2024.

  1. mega_zinji

    mega_zinji

    Joined:
    Oct 14, 2021
    Posts:
    2
    I have a gameObject set as a destination for the character.
    The character movement and navigation works fine in set place, but in different place it behaves wrong.
    While navigating to set destination, the character keeps jittering/twitching while also going backwards instead of looking forward.
    The character has no ragdoll attached.

    What I tried:
    -rotating the character
    -messing with NavMesh Agent settings
    -re-baking the environment with different settings

     
  2. kader1081

    kader1081

    Joined:
    Oct 16, 2021
    Posts:
    379
    did you set rigidbody to static.
     
  3. mega_zinji

    mega_zinji

    Joined:
    Oct 14, 2021
    Posts:
    2
    The characters don't have a rigidbody.
     
  4. bgebitekin

    bgebitekin

    Joined:
    Dec 22, 2020
    Posts:
    11
    I've seen this before where a higher level parent object (or another component on your object) also had something affecting the transform. They just get in a fight where one tells it to face direction A while the other sets the direction to B every frame.
     
  5. OscarCurto

    OscarCurto

    Joined:
    Jun 7, 2020
    Posts:
    2
    Hello, did you find a solution for this issue? It's happening the same on my project :(