![]() |
|
Help Correct way to update mesh colliders for Obi Fluids - Printable Version +- Obi Official Forum (https://obi.virtualmethodstudio.com/forum) +-- Forum: Obi Users Category (https://obi.virtualmethodstudio.com/forum/forum-1.html) +--- Forum: Obi Fluid (https://obi.virtualmethodstudio.com/forum/forum-3.html) +--- Thread: Help Correct way to update mesh colliders for Obi Fluids (/thread-4577.html) |
Correct way to update mesh colliders for Obi Fluids - Voxelboy - 06-12-2025 Hello, I'm trying to make Obi Fluids interact with Voxelica voxel engine, which generates chunk-based mesh colliders at runtime. However, as the Mesh objects are being modified on the Mesh Colliders, Obi Solver doesn't seem to pick up on the change. I tried manually forcing an update with several different methods in the Obi interfaces but had no luck so far. I also noticed that the GPU Solver and CPU Solver behaved differently, where CPU solvers was able to pick up on the changes with a specific combination of calls but GPU Solver wasn't. Sorry that I don't have the specific methods in mind at the moment, but I'm hoping that you can point me in the right direction. Thanks! RE: Correct way to update mesh colliders for Obi Fluids - josemendez - 09-12-2025 (06-12-2025, 11:39 AM)Voxelboy Wrote: Hello, Hi! Calling ObiMeshShapeTracker. UpdateMeshData() should be enough for both GPU and CPU, like this: Code: ((ObiMeshShapeTracker)yourCollider.Tracker).UpdateMeshData()Note this is a considerably expensive operation, so it shouldn't be called every frame. (As a side note, you have private messaging disabled in your forum user settings so I couldn't answer to your PM. You posted this question on friday and we're away for the weekend, so just saw both your PM and this forum post) kind regards, RE: Correct way to update mesh colliders for Obi Fluids - Voxelboy - 10-12-2025 Thanks for the response. I've made a repro project and shared it with you via PM (and also enabled receiving PMs in my user settings, thanks for the heads up). |