Collisions for certain meshes are incorrectly ignored
Some non-vanilla meshes with collision that work fine in the original engine do not properly collide in OpenMW.
Fix: Don't check NiTriShape "collision" flags, that's not what they are for. (source: Greatness7)
What I tried to do was commenting out
if (!collide && !bbcollide && hidden)
// This mesh apparently isn't being used for anything, so don't
// bother setting it up.
from components\nifbullet\bulletnifloader.cpp, and it fixed the issue both for the attached testing mesh and some problematic meshed from Tamriel Data
To test the mesh type "coc Mournhold" in console, it works in vanilla and modified (as mentioned above) OpenMW, but not in the current build
#1 Updated by scrawl . about 1 month ago
- Category set to NIF format
Are you sure the check for 'hidden' must also be removed? Particularly with collisions auto-generated from the rendering meshes, it wouldn't make much sense to have collision for something that's not visible. To that effect, can you check if there are differences in behavior when the node is under a RootCollisionNode vs. when it isn't?
If you're sure, please go ahead and make a PR.
#3 Updated by Alexei Dobrohotov about 1 month ago
- Subject changed from Collision meshes are ignored when they shouldn't be to Collisions for hidden meshes are incorrectly ignored
- Status changed from New to Closed
- Assignee set to Anton Uramer
- Target version set to openmw-0.44
- % Done changed from 0 to 100
- Operating system changed from Windows to Other