Replies: 1 comment 2 replies
-
Hey @rob-myers! If it's just a matter of changing wrapper javascript / c++ code here, we can for sure. If you're thinking of swapping between requestMoveVelocity / requestMoveTarget, maybe this could be done using the existing recast-navigation-js APIs? Or if you're imagining new agent slowdown parameters, maybe we could modify recast-navigation-js's Crowd javascript class and add parameters there? If you think these changes are best made inside recastnavigation though, I think it'd be ideal to try contributing any changes to the upstream repo. You could fork both recast-navigation-js & recastnavigation to test/use your changes in the meantime. You can modify this build script to clone recastnavigation from a different repo / comment it out and link a local folder: https://github.com/isaac-mason/recast-navigation-js/blob/main/packages/recast-navigation-wasm/build.sh#L18 |
Beta Was this translation helpful? Give feedback.
-
When an agent approaches a
requestMoveTarget
position, it slows down a bit (arrival) due to the following line of code:It doesn't slow down particularly quickly.
Ideally we should be able to force this, relying upon e.g.
AnimationAction.fadeIn
for a smooth animated transition. I've tried two methods:
requestMoveVelocity
, then stop when really close.requestMoveTarget
again, overshooting a bit, then stop a bit early so you end up at the original target.The first seems preferable, but I'd prefer to specify a parameter somewhere.
Could we alter the underlying C++ code e.g. somehow provide a new agent parameter?
Beta Was this translation helpful? Give feedback.
All reactions