Talk:$root

From Valve Developer Community
Jump to: navigation, search

Rootbone

I'm trying to write a concise explanation of how the term "rootbone" is used in Source, but I need to clarify a few things before I can boil it down to the essentials! ... Have I got any of this right ? :

  • Any bone connected ("parented") to the model's Origin is a "root" or "root bone".
$origin offsets all of the model's geometry, including the root, from the Entity's WorldPosition.
$root redefines which bone_name is "parented" to the Origin, effectively changing the Skeleton's offset from the Origin ?
  • There is no flexible joint where the rootbone connects to the Origin; the rootbone has no joint.
Therefore: The top-most joint in the skeleton is where another bone connects to the rootbone.
Therefore: the end of the rootbone represents the model's "Center of Movement", whereas the Origin represents the its "Center of Gravity".
A skeleton may have multiple rootbones; represented in SMD by
nodes
0 "rootbone_1_name" -1
1 "rootbone_2_name" -1
the purpose of which is ....

Thanks in advance, --Beeswax 12:03, 4 May 2008 (PDT)