The newest Blender Niftools Addon version has a minor bug that prevents importing Fallout 3/NV meshes with colliders, but this can be fixed by changing a single letter (see the bug report), and then it is even capable of exporting collision geometry, although only if the "Game" property is set to "Fallout 3", not "Fallout NV". And then, the collision won't work ingame, because the "Scale" in the bhkPackedNiTriStripsShape is set to 0 instead of 1, which has to be changed in NifSkope.
If a collision mesh with multiple sub shapes is imported, it gets split into separate objects, which then are exported as separate bhkCollisionObjects. As one of these is in a separate NiNode this means that bullet holes won't be visible in these areas of the mesh, as the affected NiTriShapes/Strips have to be in the same branch as the bhkCollisionObjects. One workaround is to group these together in an empty object in Blender.
If your collision mesh crashes in the geck and in-game, go to nifskope, spells, sanitize, reorder blocks. You're better off with following Bits of NifSkopery but it can be done with this guide with that fix
Epic mod, ive been trying to learn blender to make world objects for a long time but its very confusing that there is many versions people use. keep up the good work.
I'm sorry for my english, but it's not working in real game. Num Vertices value in Sub Shapes of hkPackedNiTriStripsData remains equal to 0, but must have value of Num Vertices from above. It makes all created collisions unusable for furniture etc. I saw hundreds custom models with working collisions from many mods, but no one can show me a simple way to create them. Please, someone, help me! So many modders are creating models with custom collisions, but nobody have uploaded yet an official guide. I will be very pleased for any help.
Finally resolved my problem. With the help of KiCHo666, Pixelhate and YouTube tutorials i've found the right and easy way to create static mesh collisions. The bad thing is that you need Blender 2.49b. If someone know a method to do all this work with Blender 2.80, please, give me a reply.
I got it to work with a few extra steps. I have NifSkope 2.0 Dev 8, but I don't know where I got it from, as the latest "official" version is Dev 7, but that should also be fine. There is also a fork called nifskope_updated on github which has a "Dev 10" version, but I haven't used it, yet.
18. In the Sub Shape's Num Vertices, enter the same number as "Num Vertices" above. 19. Go to Spells -> Sanitize -> Reorder Blocks (this is pretty important, the numbers have to be ordered a certain way and can't be all over the place, as the sticky post mentions) 20. With Sniff, "Update MOPP Code" for the mesh. I haven't been able to do this step in NifSkope. NifSkope 1.1.3 has this function under Spells -> Batch, but the mesh didn't work any more after saving it. (Edit: I tried it again on a different mesh and this time, it worked. But according to the NifSkope changelog, this function was bugged and created corrupt data)
After this, the collision worked for me.
I might even have found a way to define multiple sub-shapes (so you can give them different materials), but I'll have to test this first.
Yes, I was right. It's possible to create multiple sub shapes by packing several NiTriStripsDatas in a single bhkNiTriStripsShape. The vertices will be ordered according to the order they are in the array, so if you put one with 100 vertices in the first slot and one with 50 in the second, you can enter these values in the sub shapes (Make sure the NiTriStripsDatas have no UV maps, otherwise the vertex counts will be too high).
I could make an updated version of this guide, if that's alright for Nuke4Duke.
I'm quite interested in this, I'd like to see the complete process and, if possible, a before/after nif. You can contact me via DM here or on Discord (Pixelhate#7073). Thank you.
Heck, I'd be happy to find a quick guide on doing the simplified collision in NifSkope that was alluded to in this mod's description. My brain is telling me I did this a couple of times for Skyrim, almost a decade ago, but I don't recall how. And NifSkope "documentation" feels like more of a conspiracy than a reality.
You're welcome, I'd be grateful if you were to make a video on how to make collision, in addition, there is Bits of NifSkopery that covers collision in greater detail than my guide, so I'd suggest reading it's collision section before video production.
Problem coming around shortly into following the guide, as either "bnkCollisionObject" is a typo or doesn't exist on some NV meshes I've pulled to try the process with. Only "bhkCollisionObject" does, of course. Same with "bhkConvexVerticiesshape", any architecture meshes I've come across use "bhkPackedNiTriStripsShape"/ "bhkMoppByTreeShape" further into the branch, meaning I have no idea which will work for the purposes of the write-up.
To avoid these complications, perhaps it might be easier to include a "reference 2nd mesh" that everyone can use along with the guide?
Yeah, exactly! Currently I'm completely lost on how to complete the setup, which is disheartening as hell, especially when collision has been a problem for so long :P
This "reference 2nd mesh" would also give everyone a clean collision base to start from in adding their own so no one needs to go looking for a mesh with collision.
old one works fine, but friends reported that with win 11 it has bugs that are very annoying, so yeah an easy import export that is direct, and not a skyrim one would be very much apprecciated.
I'm using Blender 3.1 with the latest build of Blender nifscripts. It works fine on my end, like can you not import or export nifs at all, or do you get errors when you try exporting?
oh i never tried for FNV. i just used it for skyrim, thinking it wouldnt have worked for new vegas. Can you link the script anyway? just to check if its the same, i have a few different ones.
31 comments
If a collision mesh with multiple sub shapes is imported, it gets split into separate objects, which then are exported as separate bhkCollisionObjects. As one of these is in a separate NiNode this means that bullet holes won't be visible in these areas of the mesh, as the affected NiTriShapes/Strips have to be in the same branch as the bhkCollisionObjects. One workaround is to group these together in an empty object in Blender.
18. In the Sub Shape's Num Vertices, enter the same number as "Num Vertices" above.
19. Go to Spells -> Sanitize -> Reorder Blocks (this is pretty important, the numbers have to be ordered a certain way and can't be all over the place, as the sticky post mentions)
20. With Sniff, "Update MOPP Code" for the mesh. I haven't been able to do this step in NifSkope. NifSkope 1.1.3 has this function under Spells -> Batch, but the mesh didn't work any more after saving it. (Edit: I tried it again on a different mesh and this time, it worked. But according to the NifSkope changelog, this function was bugged and created corrupt data)
After this, the collision worked for me.
I might even have found a way to define multiple sub-shapes (so you can give them different materials), but I'll have to test this first.
I could make an updated version of this guide, if that's alright for Nuke4Duke.
You can contact me via DM here or on Discord (Pixelhate#7073).
Thank you.
Probably gonna do a video on this if that's alright, I'll praise you constantly
To avoid these complications, perhaps it might be easier to include a "reference 2nd mesh" that everyone can use along with the guide?
This "reference 2nd mesh" would also give everyone a clean collision base to start from in adding their own so no one needs to go looking for a mesh with collision.
Can you link the script anyway? just to check if its the same, i have a few different ones.