Home > other >  How about the unity of the Nav mesh Agent component and stop an object
How about the unity of the Nav mesh Agent component and stop an object

Time:09-20

Calls the stop method can only be suspended, the path is still there, want to let the object at the time of go completely stopped to another target, if midway SetDestination again, as if a BUG, the object did not move, I now is to use the first ResetPath SetDestination again after, always feel so upset, don't know right

CodePudding user response:

Should invoke the Resume after the Stop, and then SetDestination

CodePudding user response:

reference 1st floor shingoscar response:
should calls Resume after the Stop, and then SetDestination

Resume is to continue to walk not walk the path, wanted him to stop completely

CodePudding user response:

refer to the second floor qq_37842901 response:
Quote: refer to 1st floor shingoscar response:

Should invoke the Resume after the Stop, and then SetDestination

Went on Resume is not walk the path, to make him completely stop

Navmeshagent. Enable=false

CodePudding user response:

Step after setting the target location

CodePudding user response:

SetDestination (enclosing the transform. The position);

CodePudding user response:

NavMeshAgent. Enable=false; Then set to true, the next setdis again want to go,
  • Related