Grabbing a Joint

Blitz3D Forums/Blitz3D Beginners Area/Grabbing a Joint

Nathaniel(Posted 2007) [#1]
How do I "grab" a joint and turn it on an animated mesh?


Danny(Posted 2007) [#2]
Name the joints in your skeleton. Then you can:

knee = findChild("KneeJoint",animMesh)
rotateEntity knee, rnd(360),rnd(360),rnd(36)

p.s. I don't believe this works on md2 animated meshes, since the vertex animation is saved, and not sure if the joints/bones still influence the vertices...

hope that helps,
d.


Nathaniel(Posted 2007) [#3]
Thanks Danny. So the handle is the joint's name in the modelling/animations program?


Rob Farley(Posted 2007) [#4]
Yep, and it's case sensitive too!


Nathaniel(Posted 2007) [#5]
Okay, thanks guys...
This will make character animation MUCH easier.


Ricky Smith(Posted 2007) [#6]
http://www.blitzbasic.com/codearcs/codearcs.php?code=660