I was wondering if there was a way to get a list of bones from within Purebasic.
Maybe something like ExamineBones(EntityID)...
I know that the bones for the robot.mesh are "Joint1" to "Joint18", but it would be useful to be able to get a list from within the program as well
Can you get a list of "bones" from an entity?
Re: Can you get a list of "bones" from an entity?
you can use an editor , or this tool
http://wiki.ogre3d.org/OgreXmlConverter
example : OgreXMLConverter robot.skeleton robot.xml
robot.xml :
http://wiki.ogre3d.org/OgreXmlConverter
You can convert your skeleton file to XMLOgreXMLConverter
----------------
Converts between the binary and XML formats for .mesh and .skeleton. Will also
allow you to generate LOD information if you are converting to the binary
format. This tool is necessary to convert from the XML to OGRE's native runtime
format if your exporter produces XML. You can find the XML Schema for the .mesh
and .skeleton formats in the Ogre source under Tools/XMLConverter/docs.
Usage: OgreXMLConverter [options] sourcefile [destfile]
example : OgreXMLConverter robot.skeleton robot.xml
robot.xml :
Code: Select all
<skeleton>
<bones>
<bone id="0" name="Joint1">
<position x="0" y="51.5913" z="-0.0159202" />
<rotation angle="0">
<axis x="1" y="0" z="0" />
</rotation>
</bone>
<bone id="1" name="Joint2">
<position x="1.25659" y="-6.37357" z="-3.36696" />
<rotation angle="0">
<axis x="1" y="0" z="0" />
</rotation>
</bone>
...
<bone id="16" name="Joint17">
<position x="-3.68851" y="-12.7833" z="2.24464" />
<rotation angle="0">
<axis x="1" y="0" z="0" />
</rotation>
</bone>
<bone id="17" name="Joint18">
<position x="15.6188" y="-13.5145" z="6.73391" />
<rotation angle="0">
<axis x="1" y="0" z="0" />
</rotation>
</bone>
</bones>
Please correct my english
http://purebasic.developpez.com/
http://purebasic.developpez.com/
Re: Can you get a list of "bones" from an entity?
That's the way that I got the info on the robot mesh ro begin with, but it's inconvenient for my program
Was hoping to be able to do it from within Purebasic without external program support...
I've written a decent ragdoll procedure that works with the robot, but at the moment I need to manually name each joint/bone and its relations... I would be nice to just be able to make a createragdoll funtion and point it at an entity
Was hoping to be able to do it from within Purebasic without external program support...
I've written a decent ragdoll procedure that works with the robot, but at the moment I need to manually name each joint/bone and its relations... I would be nice to just be able to make a createragdoll funtion and point it at an entity