Replies: 3 comments
-
Yay, a bit of progress: Got pathfinding on a very simple 10x10 quad working :) This pathfinding demo does only the necessary parts as far as I can tell: Next on my list then is to add another quad "after the fact", connect them, and pathfind between them. (Simulating walking around on an open world and streaming in new terrain areas) Any tips here of where to look at would be appreciated @grahamboree :) |
Beta Was this translation helpful? Give feedback.
-
Progress! I finally got all the parameters right in order to add multiple tiles to a navmesh. I won't say that I really understand them yet, but one step at a time :) https://github.com/Srekel/zig-recastnavigation/blob/main/zigsrc/demo_detour_multitile.zig Would be great if someone could check it out and see if I'm doing anything obviously wrong or misleading. It's creating two 64x64 square tiles next to each other and then pathfinding between them. |
Beta Was this translation helpful? Give feedback.
-
The detour demo now includes an example of using dtPathCorridor. I couldn't find any examples of using this anywhere else so may be useful for someone interested in it. https://github.com/Srekel/zig-recastnavigation/blob/main/zigsrc/demo_detour.zig |
Beta Was this translation helpful? Give feedback.
-
Hi there! As I mentioned in #659 to @grahamboree I'm working on Zig bindings for Recast and Detour. I thought I'd start up this discussion as a thread for this work.
Zig is pretty close to C but has some features that allow for some C++ features to be mapped. But there are places where the API could be C-ified to make things a bit simpler, and this would of course go towards making a C API which is on your long-term goal list :)
One of the things I'm setting up are some minimal demos that do as little work as possible. Currently I have a demo for making a navmesh out of a trivial flat quad. I'm now working on a demo to pathfind on it. After that I'd like to jump on making a demo for a streaming world, as that's what I'm actually going to use Recast for :) It would be great if I could get some help with that since I'm not sure yet what I need to do.
Here is the repo: https://github.com/Srekel/zig-recastnavigation
The demos can be found in the
zigsrc
directory.I'm not sure if the way you want to expose a C API is to have one parallel to the current C++ API, or if you want to make the C++ API gradually be more C (until it fully is).
Two things I've found so far that would make it easier to integrate are:
Beta Was this translation helpful? Give feedback.
All reactions