I need my character cross NavmeshSurface A to NavmeshSurface B. I build a scene like this:
If I use navmeshAgent.SetDestination() to move. The character can move from A to B.
But, NavMeshAgent.move() cann’t move character from A to B.
Hi, NavMeshAgent.Move() confines the movement to only the NavMesh island that the agent is on. You need to make the agent move onto the link between the two surfaces more or less manually, and the only way I can think of to do that is to give it a path (by calling either .SetDestination() or .SetPath()) and let it navigate by itself until it jumps on the link. Once the link has been traversed (automatically or manually, in which case NavMeshAgent.CompleteOffMeshLink() needs to be called) the agent will be on the other surface and Move() will work.
NavMeshLinks can be created/modified at runtime to connect the current position of the agent to a position on the other surface.