Hello,
I’m using the new navmesh components from github. I have an agent and use this code:
agent.updateRotation = false;
agent.updatePosition = false;
I then use it’s desiredVelocity to work out what direction to move my AI unit in and update it with:
agent.speed = runSpeed;
agent.velocity = rb.velocity;
agent.nextPosition = transform.position;
But my problem is that the agent cylinder (in wireframe debug) is getting stuck on higher ground and does not follow even though I am clearly setting agent.nextPosition each frame.
This is game-breaking because other AI avoid the stuck capsule on higher ground and not where I am on the lower ground after I jump down. AI and player units will often get knocked down to lower ground and there is still navmesh there. We cannot use links everywhere and should not have to.
Walking back up and down frees the otherwise constrained agent representation (cylinder).
Any advice is welcome since I do need the avoidance and so on but need to handle movement.
Which version of Unity are you using ?
We do have an issue in 5.6 and below - where agents can get stuck at creases when moved “manually” - but fixed in 2017.1. Maybe this is a different issue, feel free to submit a (preferably minimal) repro and ping me w. case #
@Jakob_Unity Hi, I seem to be having a similar issue, and I am currently using 5.6. I am trying to use nextposition to move my nav agent to an island in the navmesh that is only connected by offmesh links, but the nav agent never gets placed onto that position, but rather the closest position to it while still on the current connected part of the navmesh it is in( meaning the closest point to the island but not on the island ) Is this the issue that is in 5.6? Should I update unity or is there a work around?
@Jakob_Unity to clarify, I should never have to use Warp if I am using nextPosition / manual movement? It seems the only hack I can do is to warp the agent when it lands after a jump.
As I am doing 100% manual movement and positioning, it seems odd that the agent nextPosition doesn’t move it outside of a navmesh edge.
I thought warp was only for agents controlled by Unity and not under manual control?
I am currently using 2017.1 b10.
Ok - i think i misunderstood the problem then.
Are you trying to move over a link ? That is not supported by ‘nextPosition’ - It only traverses polygons.
Basically you’ll have to call “CompleteOffMeshLink” to logically snap the agent to the landing side of the link.
And in order for that to work - a path containing the link is required - i.e. an offmeshlink/navmeshlink is not visible to an agent unless the agent has a path containing that link.
Hello Jakob,
Unfortunately that’s not what I want, links aren’t relevant as I want to update the internal position when my characters move around - they may jump via special moves or the player’s one might need to be updated when the player chooses to fall off.
I see a few threads like this but no solution (where the developer wants full authoritative control over the object, while using navmesh velocities etc for data - ie querying where the navmesh agent would’ve moved if it could’ve moved).
Is that what warp is for?. I tried it but it rooted my player on the spot 
(I might have a map with no links, but bounce pads or even an explosion force may have knocked npcs or players down where there is no link).
I think I am running into something similar. Have you come up with a solution hippocoder?
I think I ended up just calling warp when the character landed or something - don’t recall. Wish things were all a bit clearer in this area of Unity.
Yeah, I agree. I did the same, seems to work.
This is fixed in the patch release from today 
eh?! so I have no idea what is fixed as I’d already worked around everything I could…