Jump to content

New weapon mesh floats when dropped


Crowley9

Recommended Posts

I created a new weapon model and inserted it in the game, and now I am experiencing the problem that if I drop it, it floats in mid-air, I clip right through it and cannot interact with it in any way. I did notice this section in the "Getting Started with GECK" guide just for this problem:

 

You created a custom weapon but find that if you "drop" it, it floats and you cannot pick it up. To fix:

  • Open the weapon in question in NifSkope.
  • Locate bhkCollisionObject, and <LClick> the little arrow next to it.
  • <LClick> bhkRigidBody so the dialog at the bottom of NifSkope populates with information.
  • Now change the following values;
  • Set "Layer" to "OL_WEAPON".
  • Set "Layer Copy" to "OL_WEAPON".
  • Set "Motion System" to "MO_SYS_BOX".
  • Set "Deactivator Type" to "DEACTIVATOR_SPATIAL".
  • Set "Solver Deactivation" to "SOLVER_DEACTIVATION_LOW".
  • Set "Quality Type" to "MO_QUAL_DEBRIS".
  • Set "Max Linear Velocity" to "1068".
  • Set "Max Angular Velocity" to "31.5700".
Now the weapon should drop to the ground.

For other object types, look in NIF.XML located in the Blender foundation\blender\.blender\scripts\bpymodules\pyffi\formats\nif\ folder or the NifSkope documentation files in the "Doc" folder of it's installation folder. Search for bhkRigidBody. It has a good listing and some simple explanations of the options.

 

 

I followed the instructions, though some of the provided values did not work exactly as given. Examining existing weapon .nif files, I used "FOL_WEAPON" instead of "OL_WEAPON" and "MO_SYS_BOX_INERTIA" instead of "MO_SYS_BOX". However,all this did not fix the issue. Comparing the .nif file of my weapon model to others, I noticed these entries either do not exist in those or are very different:

bdVyqY.png

Link to comment
Share on other sites

Mopp shapes are used for static collisions, like fences, walls, etc.... anything that doesn't move. They can be used for movable objects, but are far more performance intensive (depends of the collision poly count) than convex shapes or box shapes.

Edited by KiCHo666
Link to comment
Share on other sites

Mopp shapes are used for static collisions, like fences, walls, etc.... anything that doesn't move. They can be used for movable objects, but are far more performance intensive (depends of the collision poly count) than convex shapes or box shapes.

 

At least now I have that part sorted out. I followed SGTBayk47's tutorial as closely as possible, and that instructs you to set the bounds of the collision box to Triangle Mesh. Changing that to Convex Hull made it more like what it is supposed to be, I think. Now bhkRigidBody points to bhkConvexVerticesShape.

 

 

Did you create a "ground mesh" (*_gnd.nif.) for your model? That is what is used to display the item when placed into the worldspace/ground.

 

-Dubious-

 

Is that required for every single item? Looking around, I only see it mentioned with items that look significantly different when dropped than when equipped, such as armor and weapons with backpacks. I did try to point the "World Model" under the item's entry in GECK to the .nif file, but that didn't help.

 

I'll attach the .nif here. It uses a custom texture, but hopefully anyone who takes a look can tolerate that missing. I would be very thankful for any further help.

 

edit: Looking around more for possible solutions, I changed the top node to BSFadeNode and changed BSXFlags to check Animated, Havok and Dynamic, but still no dice. There is a slight bit of progress in that now clicking on the rifle while the console is open selects it as the reference object, which did not happen before.

 

more edit: SOLVED! The BSXFlags entry turns out to have been the critical part. When I originally added it, it was placed outside of the item's main branch in Nifskope. Moving that into the branch got everything working fine now.

Edited by Crowley9
Link to comment
Share on other sites

I'll add a picture that helps demonstrate what I changed to make things function properly. On the left is what the node structure is like directly after exporting the .nif from Blender. I wonder if I have the export settings wrong.

 

rGu4Dz.png

Link to comment
Share on other sites

  • 2 years later...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...