Can I get a name of an animation that is playing now
by genomegames · in Torque 3D Professional · 03/01/2011 (3:15 pm) · 6 replies
Hello everybody!
How to learn what animation is playing now?
Thank you
How to learn what animation is playing now?
Thank you
About the author
#2
03/02/2011 (3:58 am)
Thank you, Ivan, very much!
#3
I write:
if ((mShapeInstance->getSequence(mActionAnimation.thread) == playerWomanData::SideRunLeftAnim)
and always get difference in 20 between two values. Where am I wrong?
03/02/2011 (9:49 am)
I thought all my troubles go away but I was wrong.I write:
if ((mShapeInstance->getSequence(mActionAnimation.thread) == playerWomanData::SideRunLeftAnim)
and always get difference in 20 between two values. Where am I wrong?
#4
03/02/2011 (10:15 am)
getSequence(mActionAnimation.thread) always returns a maximum value
#5
I must to write:
playerWomanData::ActionAnimation &anim = mDataBlock->actionList[playerWomanData::SideRunLeftAnim];
if (mShapeInstance->getSequence(mActionAnimation.thread) == anim.sequence) {
//do something...
}
Now it's working cod
03/02/2011 (10:36 am)
I've solved:I must to write:
playerWomanData::ActionAnimation &anim = mDataBlock->actionList[playerWomanData::SideRunLeftAnim];
if (mShapeInstance->getSequence(mActionAnimation.thread) == anim.sequence) {
//do something...
}
Now it's working cod
#6
How can I get a name or an index of an animation that is playing now if this animation was called from script?
03/18/2011 (8:19 pm)
I can get the movement animation by this method. IOW, I can get a name of an animation that was defined in an engine.How can I get a name or an index of an animation that is playing now if this animation was called from script?
Torque Owner Ivan Mandzhukov
Liman3D