• Children are separated from their parents.
    13 replies, posted
Sorry for the title, but it was a perfect opportunity, I have a problem with a model I am working on, here's how it looks: https://i.gyazo.com/5a7229e82ad9103fc954340dfc3ed2b5.jpg it is currently set in T-Pose, but normally when I spawn it, it spawns with it's legs detatched like this: https://i.gyazo.com/5636494d298da0f7dc2b68f097c1edde.png This is the QC: $ModelName "despacito\despacito.mdl" $Model "despacito" "despacito.smd" $surfaceprop antlion $cdmaterials "despacito\" $Ambientboost $sequence "ragdoll" "anims\ragdoll.smd" { fps 30 "ACT_DIERAGDOLL" 1 } $CollisionJoints "physics.smd" { $automass $concave $rootbone "root" $noselfcollisions } I tried adding $jointconstrait for every bone, but the problem is that it says "error, leg1 has no parent bone" when compiling, which is BS, it's parent is called root, I even defined it with $rootbone and as you can see, the model itself is parented correctly: https://i.gyazo.com/19f6cd4611dbba96d7a86c95694a14c0.png I also tried defining bones, and as expected, it does show that these leg1 (from 1 to 8) are all parented to root, but in game the legs are still detatched, this is a big problem because every time I spawn the ragdoll its legs go through the ground and fall off of the map, once it reaches the map limit the whole ragdoll gets deleted, is there anything I forgot? BONUS QUESTION! (10 coins): This is the VMT for the legs' texture: "VertexlitGeneric" { $basetexture despacito/legs $bumpmap despacito/legs_bump $ambientocclusion 1 $detail detail\noise_detail_01 $detailblendfactor .7 $nocull 1 $halflambert 1 $surfaceprop antlion } When giving the legs $surfaceprop antlion, and giving the head $surfaceprop plastic, the model loses all surface properties and instead uses the normal phx property, am I forgetting something or is it not possible to give a single model different properties?
Very good model. I love the attention to detail.
For the surface properties, probably $jointsurfaceprop is what you are looking for. Can you post a screenshot/smd of the physics file?
Check your idle animation and your physics model to see that they have the same bones. Also run the -definebones paramater with studiomdl, and put those $definebone lines into the QC (also check if they are correct) $jointsurfaceprop is what are you looking for to give multiple $surfaceprops.
https://i.gyazo.com/4815b5d1b081fe3cdd3bc93a1030e24c.png They are supposedly fine, this is the physics with the animations loaded in. $ModelName "despacito\despacito.mdl" $Model "despacito" "despacito.smd" $surfaceprop antlion $cdmaterials "despacito\" $Ambientboost $definebone "root" "" 3.722301 5.253126 6.352317 -0.000000 0.000000 89.999985 0.000000 0.000000 0.000000 -0.000000 0.000000 0.000000 $definebone "thigh1" "root" -8.271781 -0.000008 11.673614 73.338997 3.126860 2.159879 0.000000 0.000000 0.000000 -0.000000 0.000000 0.000000 $definebone "leg1" "thigh1" -57.736538 22.878716 -26.539944 -0.000000 0.000057 0.000057 0.000000 0.000000 0.000000 0.000002 0.000000 0.000000 $definebone "claw1" "leg1" -29.593369 -9.025660 -13.755894 -0.000055 -0.000057 0.000057 0.000000 0.000002 -0.000004 0.000002 0.000000 0.000000 $definebone "thigh5" "root" 8.271778 -0.000008 11.673614 73.361862 1.014708 2.162744 0.000000 0.000000 0.000000 -0.000000 -0.000000 -0.000000 $definebone "leg5" "thigh5" -33.707470 22.878696 53.867271 -0.000002 0.000057 -0.000057 0.000000 0.000000 -0.000008 -0.000002 -0.000000 0.000000 $definebone "claw5" "leg5" -17.193291 -9.025673 27.737747 0.000058 0.000057 -0.000057 -0.000004 0.000000 0.000000 -0.000000 -0.000000 0.000000 $definebone "thigh4" "root" -8.271779 -0.000006 -11.673616 73.339058 -1.011729 -2.159879 0.000000 0.000000 -0.000001 -0.000000 -0.000000 0.000000 $definebone "leg4" "thigh4" 33.685989 22.878704 -53.880714 -0.000002 -0.000057 0.000057 0.000000 0.000000 0.000000 -0.000002 -0.000000 -0.000000 $definebone "claw4" "leg4" 17.182236 -9.025669 -27.744583 -0.000056 -0.000115 0.000000 0.000000 0.000002 0.000000 -0.000000 0.000000 0.000000 $definebone "thigh8" "root" 8.271780 -0.000006 -11.673616 73.361862 -3.129839 -2.162744 0.000000 0.000000 0.000000 -0.000000 0.000000 0.000000 $definebone "leg8" "thigh8" 57.725925 22.878691 26.562996 -0.000000 -0.000057 -0.000057 0.000000 0.000000 0.000000 0.000002 0.000000 0.000000 $definebone "claw8" "leg8" 29.587875 -9.025646 13.767731 -0.000000 0.000057 0.000000 0.000008 0.000000 -0.000004 -0.000000 0.000000 0.000000 $definebone "thigh2" "root" -11.541159 -0.000007 4.602695 73.339058 3.126860 2.159879 0.000000 0.000000 0.000000 -0.000000 0.000000 0.000000 $definebone "leg2" "thigh2" -31.812250 22.888496 -55.003704 0.000002 0.000057 -0.000057 0.000004 0.000000 0.000000 -0.000000 0.000000 0.000000 $definebone "claw2" "leg2" -16.450504 -9.020681 -28.186211 -0.000000 0.000000 0.000000 0.000000 -0.000002 -0.000008 -0.000000 0.000000 0.000000 $definebone "thigh6" "root" 11.541159 -0.000007 4.602695 73.361862 1.014708 2.162744 0.000000 0.000000 0.000000 -0.000000 -0.000000 -0.000000 $definebone "leg6" "thigh6" 3.583583 22.888493 63.439617 0.000058 -0.000000 0.000057 0.000000 0.000000 0.000008 -0.000000 0.000000 -0.000000 $definebone "claw6" "leg6" 1.712141 -9.020685 32.590652 -0.000000 0.000000 -0.000057 0.000000 0.000000 0.000000 -0.000000 -0.000000 0.000000 $definebone "thigh3" "root" -11.541159 -0.000007 -4.602695 73.339058 -1.011672 -2.159822 0.000000 0.000000 0.000000 -0.000002 0.000000 -0.000000 $definebone "leg3" "thigh3" -3.608900 22.888493 -63.438202 -0.000003 -0.000057 -0.000057 -0.000000 0.000000 0.000000 -0.000003 0.000000 0.000000 $definebone "claw3" "leg3" -1.725136 -9.020689 -32.589973 -0.000002 0.000057 0.000000 -0.000000 0.000000 0.000000 -0.000002 0.000000 0.000000 $definebone "thigh7" "root" 11.541159 -0.000007 -4.602695 73.361862 -3.129839 -2.162744 0.000000 0.000000 0.000001 -0.000000 0.000000 0.000000 $definebone "leg7" "thigh7" 31.790312 22.888493 55.016422 -0.000000 0.000000 -0.000057 0.000000 -0.000002 0.000000 -0.000000 0.000000 0.000000 $definebone "claw7" "leg7" 16.439255 -9.020716 28.192772 -0.000000 0.000057 0.000000 0.000004 -0.000002 0.000000 -0.000000 0.000000 0.000000 $definebone "body" "root" 0.000000 4.290813 0.000000 -0.000000 0.000000 0.000000 0.000000 0.000000 0.000000 -0.000000 0.000000 0.000000 $definebone "head" "body" 0.037509 43.745708 -0.589853 -0.000000 0.000000 0.000000 0.000000 0.000000 0.000000 -0.000000 0.000000 0.000000 $sequence "ragdoll" "anims\ragdoll.smd" { fps 30 "ACT_DIERAGDOLL" 1 } $CollisionJoints "physics.smd" { $automass $concave $inertia 10 $damping 0 $rotdamping 4 $noselfcollisions $rootbone "root" $jointconstrain "thigh1" x limit 0 0 0 $jointconstrain "thigh1" y limit 0 0 0 $jointconstrain "thigh1" z limit 0 0 0 $jointconstrain "leg1" x limit 0 0 0 $jointconstrain "leg1" y limit 0 0 0 $jointconstrain "leg1" z limit 0 0  $jointconstrain "claw1" x limit 0 0 0 $jointconstrain "claw1" y limit 0 0 0 $jointconstrain "claw1" z limit 0 0 0 } This is the new QC, it is not finished as I still need to add $jointsurfaceprop and the rest of the jointconstrain, but is still gives off this problem:       ERROR: Rotation constraint on bone "thigh1" which has no parent!!! It clearly has a parent, it's even defined in $definebone and $rootbone! Oh and yes, it was $jointsurfaceprop so both get the bonus.
Hey, I already fixed everything and found the exact issue(s). I will write it up tomorrow on what the problems are, and send you the files.
I saw the thread title at a glance and thought it was another news thread
The myth, the legend, the mad man. There is no way I could've passed the opportunity, sorry.
Adding $jointmerge "root" "body" after the rootbone seems to fix the physics, although if you want the legs moveable you are going to need to define some joint constraints.
You're right it did! The children are now with their parents! I don't think I'll bother adding many jointconstraints tho since it would be a lot of work, that is unless there is a way to make them using HLMV or a similar software.
Add this to the $collisionjoints     $jointconstrain "head" x limit -180 180 0     $jointconstrain "head" y limit -180 180 0     $jointconstrain "head" z limit -180 180 0     $jointconstrain "thigh1" x limit -180 180 0     $jointconstrain "thigh1" y limit -180 180 0     $jointconstrain "thigh1" z limit -180 180 0          $jointconstrain "leg1" x limit -180 180 0     $jointconstrain "leg1" y limit -180 180 0     $jointconstrain "leg1" z limit -180 180 0               $jointconstrain "thigh2" x limit -180 180 0     $jointconstrain "thigh2" y limit -180 180 0     $jointconstrain "thigh2" z limit -180 180 0          $jointconstrain "leg2" x limit -180 180 0     $jointconstrain "leg2" y limit -180 180 0     $jointconstrain "leg2" z limit -180 180 0          $jointconstrain "thigh3" x limit -180 180 0     $jointconstrain "thigh3" y limit -180 180 0     $jointconstrain "thigh3" z limit -180 180 0          $jointconstrain "leg3" x limit -180 180 0     $jointconstrain "leg3" y limit -180 180 0     $jointconstrain "leg3" z limit -180 180 0          $jointconstrain "thigh4" x limit -180 180 0     $jointconstrain "thigh4" y limit -180 180 0     $jointconstrain "thigh4" z limit -180 180 0          $jointconstrain "leg4" x limit -180 180 0     $jointconstrain "leg4" y limit -180 180 0     $jointconstrain "leg4" z limit -180 180 0          $jointconstrain "thigh5" x limit -180 180 0     $jointconstrain "thigh5" y limit -180 180 0     $jointconstrain "thigh5" z limit -180 180 0          $jointconstrain "leg5" x limit -180 180 0     $jointconstrain "leg5" y limit -180 180 0     $jointconstrain "leg5" z limit -180 180 0          $jointconstrain "thigh6" x limit -180 180 0     $jointconstrain "thigh6" y limit -180 180 0     $jointconstrain "thigh6" z limit -180 180 0          $jointconstrain "leg6" x limit -180 180 0     $jointconstrain "leg6" y limit -180 180 0     $jointconstrain "leg6" z limit -180 180 0          $jointconstrain "thigh7" x limit -180 180 0     $jointconstrain "thigh7" y limit -180 180 0     $jointconstrain "thigh7" z limit -180 180 0          $jointconstrain "leg7" x limit -180 180 0     $jointconstrain "leg7" y limit -180 180 0     $jointconstrain "leg7" z limit -180 180 0          $jointconstrain "thigh8" x limit -180 180 0     $jointconstrain "thigh8" y limit -180 180 0     $jointconstrain "thigh8" z limit -180 180 0          $jointconstrain "leg8" x limit -180 180 0     $jointconstrain "leg8" y limit -180 180 0     $jointconstrain "leg8" z limit -180 180 0 Also $jointmerge is a hacky workaround, I'll explain why this happens specifically. Collision joints recognize their own skeleton. They determine this skeleton by the physics meshes. In your case, you had no physics mesh created for the "root" bone, therefore the physics mesh didn't recognise the bone. The way I properly fixed it was to delete the body bone, and instead use the root bone. The physics mesh now properly recognized the root bone, as it had a physics mesh assigned to it.
Shit, I chose the answer too soon, this is perfect, sorry but the best I can do is a diamond, I am now poor.
No U aren't
Between the title, the screenshots and the subject of matter itself, this entire thread has been a rollercoaster. Bravo.
Sorry, you need to Log In to post a reply to this thread.