Search Unity

  1. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice
  2. Ever participated in one our Game Jams? Want pointers on your project? Our Evangelists will be available on Friday to give feedback. Come share your games with us!
    Dismiss Notice

Agent remaining and some issues. LateUpdate?

Discussion in 'Navigation' started by IndieFist, Jun 30, 2019.

  1. IndieFist


    Jul 18, 2013
    Hello, i have some issues with my agent navigator.
    Sometimes my agent still stuck in same point, like he isn´t getting right values from agent.remainingdistance.
    I have read in this forum, that is recommended to check this in LateUpdate when you send a new target.position.
    I would like to find some recommendations on how to properly use the agent, because in some examples I see that everyone does calculations in the update. Others recommend using Vector2Distance(player.transform, agent.transform) others tell me to use this.transform instead of agent.transform... I'm a little lost.
    Best regards.