Jump to content

HDT-PE plus HDT-SMP Collision Physics How-To in 5 mins Explanation/Guide. Legendary Edition.


Recommended Posts

First step in making something work better than it is now – is to understand how something works now. (c) me.

When I decided to use SMP, I found no *awesome* guides or explanations about. So here it is (I hope).

 

Whom is this explanation guide for?

  1.           For those who know about HDT physics already and uses it, but wants SMP too.
  2.           For those who does not know anything about it, but want some physics attached to female bodies.
  3.           For those who just curious.

What is HDT-PE really?

This a tool-library that can:

  1.           read physics configuration files and attach collision shapes to NiNodes/NiShapes in meshes or to skeleton nodes;
  2.           calculate collisions of HDT-PE shapes to enable interactions with other HDT-PE-shapes attached to nodes;
  3.           transform meshes.

What is HDT-SMP really?

Just like HDT-PE. But, it has more precise calculations, and it can calculate very complex collision shapes. On the other side – it eats more CPU time.

 

[HDT-PE and HDT-SMP definitions from other point of view you can read in this post]

 

Ok. Let’s see how HDT physics attaches to body.

Physics can be attached to any mesh. However, hdtphysicsextension.dll will do its work only for EQUIPPED meshes, so most common case – is attaching physics to head (you can use nifscope to look in or do simple edits – like creating HDT Havok Path NiStrings - to mesh-files):

 

mspaint_wJfULo0SVd.png.82f873fa90b1eb112e875544ac7a7cf5.png

 

Let’s look what is in the configuration files. Use JustForFun tool for it, since to understand anything in HDT config by viewing it in notepad is real pain.

Since one of config files is hdtThighs.xml, let’s choose it as example:

10686338_.png.406831dd3ba7b7b20bc27379eb68be61.png

 

Hey! But, head-mesh does not have those NiNodes! Yes. However, head is usually attached to body, so hdtPhysicsExtension.dll will do its calculations for ANY EQUIPPED mesh with listed in config nodes. As you see, body has correct NiNodes:

 

NifSkope_8EnobrGf3x.png.268a701b11a44a9fa75114ccc292c458.png

You can delete any entry in justforfun editor from hdt config file and hdtPhysicsExtension.dll will do less calculations. And, of course, you will see less physics in game. But, that is The Key to use HDT and SMP simultaneously.

Ok, now it should be clear about how HDT attaches and works, but what is about SMP?

It attaches in the same way:NifSkope_xm6vQaCGmN.png.fb0a9cfb7cde210a17552fcf23ed01f4.png

 

Oh, I forgot to tell one more way of applying of HDT-PE.

HDT-PE can be applied to equipped mesh if mesh have NiNones/NiGeometry listed in hdtPhysicsExtensionsDefaultBBP.xml, if hdtPhysicsExtensionsDefaultBBP.xml exists and is not "blank. (Thus, some grarphical glitches can be caused by HDT-PE + SMP, because they will fight for controlling same NiGeometry.)

But, installation and setting up SMP is complicated a little.

I personally use BHUNP (thanks to Baka). There is only one bad thing during installation:

 

mspaint_nnHOj4DsTN.png.64a4c35dcb7a3d68045cd762540b6f82.png

Choose wisely. It installs hdtskinnedmesh configs with different writing order of float numbers.

Another note: you can install havoc objects but its not used by mod esp (but you can create one yourself or use them as example).

Yet another note: you will have to build collision meshes(in bodyslide) that BHUNP3BBB mod attaches then you will press magic key to enable SMP for player or NPC(instead of attaching havoc objects).

Before you install any SMP body you should install XP32 skeleton with correct option: use “Physics extensions”. SMP works for it too.

 

ModOrganizer_SgRRU0Okn9.png.3b6946d4e8c5eb42b4c028936de3dab5.png

Ok. We installed correct XP32 skeletons, installed BHUNP and built collision meshes for player, built cups we want to use for NPC- if we (I not, I use HDT for female NPC and BHUNP-TBBP bodies for them).

 

But what about editing SMP configs? Well, it just like with HDT, but we don’t have JustForFun. Only notepad, only hardcore. Hovewer – SMP config structures is much better:

AkelPad_9jrTKjV0j9.png.e3b00e92e0602b9ca44c81a8d73458aa.png

For example. I like better how HDT interacts with thighs, then I delete from config file (THAT IS ATTACHED TO SPECIAL MESH USED FOR PLAYER) this wall of text:

 

Spoiler

<bone name="NPC L Thigh [LThg]">

                               <mass>0</mass>

                               <inertia x="0" y="0" z="0"/>

                               <centerOfMassTransform>

                               <basis x="0" y="0" z="0" w="1"/>

                               <origin x="0" y="0" z="0"/>

                               </centerOfMassTransform>

                               <linearDamping>0</linearDamping>

                               <angularDamping>0</angularDamping>

                               <friction>0</friction>

                               <rollingFriction>0</rollingFriction>

                               <restitution>0</restitution>

                               </bone>

 

 

                               <bone name="NPC L FrontThigh">

                               <mass>0.9</mass>

                               <inertia x="5" y="5" z="5"/>

                               <centerOfMassTransform>

                                               <basis x="2" y="0" z="0" w="1"/>

                                               <origin x="0" y="0" z="1"/>

                               </centerOfMassTransform>

                               <linearDamping>0.9</linearDamping>

                               <angularDamping>1</angularDamping>

                               <friction>0.8</friction>

                               <rollingFriction>0</rollingFriction>

                               <restitution>1</restitution>

                               </bone>

 

 

                               <bone name="NPC R Thigh [RThg]">

                               <mass>0</mass>

                               <inertia x="0" y="0" z="0"/>

                               <centerOfMassTransform>

                               <basis x="0" y="0" z="0" w="1"/>

                               <origin x="0" y="0" z="0"/>

                               </centerOfMassTransform>

                               <linearDamping>0</linearDamping>

                               <angularDamping>0</angularDamping>

                               <friction>0</friction>

                               <rollingFriction>0</rollingFriction>

                               <restitution>0</restitution>

                               </bone>

 

 

                               <bone name="NPC R FrontThigh">

                               <mass>0.9</mass>

                               <inertia x="5" y="5" z="5"/>

                               <centerOfMassTransform>

                                               <basis x="2" y="0" z="0" w="1"/>

                                               <origin x="0" y="0" z="1"/>

                               </centerOfMassTransform>

                               <linearDamping>0.9</linearDamping>

                               <angularDamping>1</angularDamping>

                               <friction>0.8</friction>

                               <rollingFriction>0</rollingFriction>

                               <restitution>1</restitution>

                               </bone>

 

 

                               <generic-constraint bodyA="NPC L FrontThigh" bodyB="NPC L Thigh [LThg]">

                               <frameInB>

                               <basis x="0" y="0" z="0" w="1"/>

                               <origin x="0" y="0" z="0"/>

                               </frameInB>

                               <useLinearReferenceFrameA>false</useLinearReferenceFrameA>

                               <linearLowerLimit x="-1" y="0" z="-0.5"/>

                               <linearUpperLimit x="1" y="0" z="0.5"/>

                               <angularLowerLimit x="-0" y="-0" z="-0.0"/>

                               <angularUpperLimit x="0" y="0" z="0.0"/>

                               <linearStiffness x="400" y="400" z="400"/>

                               <angularStiffness x="1000" y="100" z="10000"/>

                               <linearDamping x="1" y="2" z="1"/>

                               <angularDamping x="0" y="0" z="0"/>

                               <linearEquilibrium x="0" y="-1" z="-1"/>

                               <angularEquilibrium x="0" y="0" z="0"/>

                               <linearBounce x="1.2" y="1.2" z="1.2"/>

        <angularBounce x="0" y="0" z="0"/>

                </generic-constraint>

 

 

                               <generic-constraint bodyA="NPC R FrontThigh" bodyB="NPC R Thigh [RThg]">

                               <frameInB>

                               <basis x="0" y="0" z="0" w="1"/>

                               <origin x="0" y="0" z="0"/>

                               </frameInB>

                               <useLinearReferenceFrameA>false</useLinearReferenceFrameA>

                               <linearLowerLimit x="-1" y="0" z="-0.5"/>

                               <linearUpperLimit x="1" y="0" z="0.5"/>

                               <angularLowerLimit x="-0" y="-0" z="-0.0"/>

                               <angularUpperLimit x="0" y="0" z="0.0"/>

                               <linearStiffness x="400" y="400" z="400"/>

                               <angularStiffness x="1000" y="100" z="10000"/>

                               <linearDamping x="1" y="2" z="1"/>

                               <angularDamping x="0" y="0" z="0"/>

                               <linearEquilibrium x="0" y="-1" z="-1"/>

                               <angularEquilibrium x="0" y="0" z="0"/>

                               <linearBounce x="1.2" y="1.2" z="1.2"/>

        <angularBounce x="0" y="0" z="0"/>

                </generic-constraint>

               

               

               

 

 

                               <bone name="NPC L RearThigh">

                               <mass>1</mass>

                               <inertia x="4" y="4" z="4"/>

                               <centerOfMassTransform>

                                               <basis x="0" y="0" z="0" w="1"/>

                                               <origin x="0" y="0" z="4"/>

                               </centerOfMassTransform>

                               <linearDamping>0.7</linearDamping>

                               <angularDamping>1</angularDamping>

                               <friction>0.6</friction>

                               <rollingFriction>0</rollingFriction>

                               <margin-multiplier>0.2</margin-multiplier>

                               <restitution>0.5</restitution>

                               </bone>

 

 

                              

 

 

                               <bone name="NPC R RearThigh">

                               <mass>1</mass>

                               <inertia x="4" y="4" z="4"/>

                               <centerOfMassTransform>

                                               <basis x="0" y="0" z="0" w="1"/>

                                               <origin x="0" y="0" z="4"/>

                               </centerOfMassTransform>

                               <linearDamping>0.7</linearDamping>

                               <angularDamping>1</angularDamping>

                               <friction>0.6</friction>

                               <rollingFriction>0</rollingFriction>

                               <margin-multiplier>0.2</margin-multiplier>

                               <restitution>0.5</restitution>

                               </bone>

 

 

                               <generic-constraint bodyA="NPC L RearThigh" bodyB="NPC L Thigh [LThg]">

                               <frameInB>

                               <basis x="0" y="0" z="0" w="1"/>

                               <origin x="0" y="0" z="0"/>

                               </frameInB>

                               <useLinearReferenceFrameA>false</useLinearReferenceFrameA>

                               <linearLowerLimit x="-1" y="0" z="-0.5"/>

                               <linearUpperLimit x="1" y="0" z="0.5"/>

                               <angularLowerLimit x="-0" y="-0" z="-0.0"/>

                               <angularUpperLimit x="0" y="0" z="0.0"/>

                               <linearStiffness x="400" y="400" z="400"/>

                               <angularStiffness x="0" y="0" z="0"/>

                               <linearDamping x="1" y="2" z="1"/>

                               <angularDamping x="0" y="0" z="0"/>

                               <linearEquilibrium x="0.1" y="0.1" z="0.1"/>

                               <angularEquilibrium x="0" y="0" z="0"/>

                               <linearBounce x="1" y="1" z="1"/>

        <angularBounce x="0" y="0" z="0"/>

                </generic-constraint>

 

 

 

 

                               <generic-constraint bodyA="NPC R RearThigh" bodyB="NPC R Thigh [RThg]">

                               <frameInB>

                               <basis x="0" y="0" z="0" w="1"/>

                               <origin x="0" y="0" z="0"/>

                               </frameInB>

                               <useLinearReferenceFrameA>false</useLinearReferenceFrameA>

                               <linearLowerLimit x="-1" y="0" z="-0.5"/>

                               <linearUpperLimit x="1" y="0" z="0.5"/>

                               <angularLowerLimit x="-0" y="-0" z="-0.0"/>

                               <angularUpperLimit x="0" y="0" z="0.0"/>

                               <linearStiffness x="400" y="400" z="400"/>

                               <angularStiffness x="0" y="0" z="0"/>

                               <linearDamping x="1" y="2" z="1"/>

                               <angularDamping x="0" y="0" z="0"/>

                               <linearEquilibrium x="0.1" y="0.1" z="0.1"/>

                               <angularEquilibrium x="0" y="0" z="0"/>

                               <linearBounce x="1" y="1" z="1"/>

        <angularBounce x="0" y="0" z="0"/>

                </generic-constraint>

And the last thing you might need is smp-pe-patch, that I grabbed I don't remember where(but I remember that I did not forgot to say "thank you!").

smp-pe-bundle.zip

And of course if you want collisions of female bodies with some other 'bodies', make sure to have correct config files attached to correct meshes.

 

Now you know all you need about HDT and HDT-SMP to make your own path in HDT-PE + HDT-SMP setup.

firefox_hC0abHmNuR.png.c87394307917eb0c66d06c684c8df3a3.png

 

As an example: I have HDT-PE+HDT-SMP for main character (belly collisions with some objects by HDT-PE is better - because they are visible:) ), HDT-PE for female NPC, HDT-SMP or HDT-PE+HDT-SMP for creatures (by mood).

 

 

 

Edited by Iroha
fixed misunderstanding in shapes, corrected topic name to better reflect its content.
Link to comment
  1. Hi, thanks for this guide, I need to learn more about HDT-SMP so I will be using it a lot!

 

I wonder if you would consider removing the confusing definitions for "HDT?"

3 hours ago, Iroha said:

What is HDT really?

This a tool-library that can:

  1.           read physics configuration files and attach collision shapes to shapes in meshes or to skeleton nods;
  2.           calculate collisions of HDT shapes to enable interactions with other HDT-shapes attached to nodes;
  3.           transform meshes.

What is SMP really?

Just like HDT. But, it has more precise calculations, and it can calculate very complex collision shapes. On the other side – it eats more CPU time.

You are saying that "HDT means physics" and "SMP is just like HDT." It would be great if you could revise that since both HDT-PE and HDT-SMP are "HDT." You can see this in the image of the XPMSSE download instructions even though they got the actual name of SMP wrong (it's not Soft Mesh Physics, it's Skinned Mesh Physics,):

HDT and HDT.png

 

Would you consider a more accurate summary in answer to the question of "What is HDT?"

 

What is Skyrim Physics?

There are two major categories of physics in Skyrim:

  1. Body Physics- this is breast, butt, belly, thigh, calf and genitals movement and collisions
  2. Cloth Physics- this is hairstyle physics and collisions, plus physics and collisions for any physics-enabled equippable items, e.g. wigs, earrings, amulets, bracelets, clothing, armor and, recently announced for SSE, sheathed weapons

 

What is HDT?

"HDT" is the brand name of hydrogensaysHDT, the author of all Skyrim HDT physics systems. He applied it to 3 of his physics systems:

  1. HDT Physics Extensions ("HDT-PE")- this is used only in Skyrim Legendary Edition ("Oldrim") to provide body physics and cloth physics
  2. HDT Skinned Mesh Physics ("HDT-SMP")- this is used in some Legendary Edition physics mods, and in all Special Edition physics mods to provide body physics and cloth physics. NOTE: there is also a newer system for SSE, CBPC, that provides body physics with collisions but no cloth physics
  3. HDT High Heels System ("HDT-HH")- this can be used in Oldrim and in SSE to provide High Heel height offsets. NOTE: there is another system that does not require an additional plugin: NiOverride High Heels Offset, provided by the skee64.dll from the Racemenu mod

 

Thanks!

 

 

Edited by Vyxenne
그녀는 결코 만족하지 않기 때문에
Link to comment

I had a problem with npcs vanishing (first they would stretch and fade out, then not be rendered at all and I had the correct skelly installed) in LE when I used HDT physics for too many meshes and I've read that others had the same problem as well. Also read that it was a problem with the HDT .xml or something. Was this problem ever solved for LE? Been using HDT-SMP in SE and haven't seen the same problem once. What's the difference?

 

 

Edited by KoolHndLuke
Link to comment
5 hours ago, KoolHndLuke said:

I had a problem with npcs vanishing (first they would stretch and fade out, then not be rendered at all and I had the correct skelly installed) in LE when I used HDT physics for too many meshes and I've read that others had the same problem as well. Also read that it was a problem with the HDT .xml or something. Was this problem ever solved for LE? Been using HDT-SMP in SE and haven't seen the same problem once. What's the difference?

 

 

there is hdtHavokpatch that can help with this problem(I think, never saw your problem in my setup), it "syncs" havok calculating threads with your current fps.

 

6 hours ago, Vyxenne said:
  1. Hi, thanks for this guide, I need to learn more about HDT-SMP so I will be using it a lot!

 

I wonder if you would consider removing the confusing definitions for "HDT?"

You are saying that "HDT means physics" and "SMP is just like HDT." It would be great if you could revise that since both HDT-PE and HDT-SMP are "HDT." You can see this in the image of the XPMSSE download instructions even though they got the actual name of SMP wrong (it's not Soft Mesh Physics, it's Skinned Mesh Physics,):

HDT and HDT.png

 

Would you consider a more accurate summary in answer to the question of "What is HDT?"

 

What is Skyrim Physics?

There are two major categories of physics in Skyrim:

  1. Body Physics- this is breast, butt, belly, thigh, calf and genitals movement and collisions
  2. Cloth Physics- this is hairstyle physics and collisions, plus physics and collisions for any physics-enabled equippable items, e.g. wigs, earrings, amulets, bracelets, clothing, armor and, recently announced for SSE, sheathed weapons

 

What is HDT?

"HDT" is the brand name of hydrogensaysHDT, the author of all Skyrim HDT physics systems. He applied it to 3 of his physics systems:

  1. HDT Physics Extensions ("HDT-PE")- this is used only in Skyrim Legendary Edition ("Oldrim") to provide body physics and cloth physics
  2. HDT Skinned Mesh Physics ("HDT-SMP")- this is used in some Legendary Edition physics mods, and in all Special Edition physics mods to provide body physics and cloth physics. NOTE: there is also a newer system for SSE, CBPC, that provides body physics with collisions but no cloth physics
  3. HDT High Heels System ("HDT-HH")- this can be used in Oldrim and in SSE to provide High Heel height offsets. NOTE: there is another system that does not require an additional plugin: NiOverride High Heels Offset, provided by the skee64.dll from the Racemenu mod

 

Thanks!

 

 

We are looking on the subject from different POV. Mine is more of "technical", yours is more "generalized". But we both correct, so I will add note about your definitions to OP.
 

Edited by Iroha
Link to comment
  • Iroha changed the title to HDT-PE plus HDT-SMP Collision Physics from Starter to Pro in 5 mins Explanation/Guide. Legendary Edition.
  • Iroha changed the title to HDT-PE plus HDT-SMP Collision Physics How-To in 5 mins Explanation/Guide. Legendary Edition.
  • 2 months later...
7 hours ago, IOnlyCameHereToFap said:

I also use BHUNP and I'm trying to make it so that HDT-PE handles the vagina physics and SMP handles the rest as usual. I deleted the vagina bones and constraints from BaseshapeP.xml and Baseshape.xml, which didn't seem to work out. I'm guessing I'm missing something here. I would really appreciate any help ?

if you have not blank hdtPhysicsExtensionsDefaultBBP.xml then HDT will still be applied to body.

Also look into SMP log file - check that smp configs processed succesfully, sometimes editing smp configs breaks its structure

Edited by Iroha
Link to comment
2 hours ago, Iroha said:

if you have not blank hdtPhysicsExtensionsDefaultBBP.xml then HDT will still be applied to body.

Also look into SMP log file - check that smp configs processed succesfully, sometimes editing smp configs breaks its structure

thanks for the reply,
I tested a bit around by making hdtPhysicsExtensionsDefaultBBP.xml blank, which caused the entire body to be controlled by PE (which is what's supposed to happen right?).

Is it possible to only remove specific lines in hdtPhysicsExtensionsDefaultBBP.xml so PE gets control of the vagina?

Or am I completely off track and need to do something else to give PE control of the vagina physics only?

Link to comment
34 minutes ago, IOnlyCameHereToFap said:

thanks for the reply,
I tested a bit around by making hdtPhysicsExtensionsDefaultBBP.xml blank, which caused the entire body to be controlled by PE (which is what's supposed to happen right?).

Is it possible to only remove specific lines in hdtPhysicsExtensionsDefaultBBP.xml so PE gets control of the vagina?

Or am I completely off track and need to do something else to give PE control of the vagina physics only?

of course, with JFF you can delete only entries that are not mention vagina, and if you don't know to which nodes collision shapes attached - you can open bodymesh in nifscope and find node(column "name" in JFF) controlled by HDT or SMP

Edited by Iroha
Link to comment
  • 1 year later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

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

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more information, see our Privacy Policy & Terms of Use