(06-04-2010 04:56 AM)Driklyn Wrote: To this:
Code:
cskel.clear();
cskel.animate(L"obj/chr/dino/walk_forward.anim", Time.time());
Orient &head=cskel.getBone("head").orn;
head*=Matrix3().setRotateZ(Sin(Time.time()*1.5));
And it will work.
gosh......thanks a lot.
I thought, I will never be able to figure out the problem.
But, still I dont understand, you are saying that "some sort of animation already loaded on the skeleton for it to work."..but why that should be a problem?Cause, multiple animation can be there in a single skeleton..right?
Moreover, It(ckel.animate) required a key press...so, that line shouldn't exits or execute before that...so, by default the head should be moving...if we think of your's saying that "there is already another animation on the skeleton"
Again, when I use following code
Code:
cskel.clear();
Orient &head=cskel.getBone("head").orn;
head*=Matrix3().setRotateZ(Sin(Time.time()*1.5)); /
cskel.updateMatrix(MatrixIdentity);
(removed the ckel.animate line)
This should animate the head because, there is no other animation.
Put this logic aside, I dont find a reason why nothing happens?
Why all the animation's has to work together?and why the "head animation" has to be coupled with another animation(.anim file) to make it work?