Hi all^^
I’m writing a sports game with panda3d. Exactly, I’m writing a soccer game.
I have an animation for walking named “WALK”.
The actor on the animation is walking. I mean, the actor moves foward.
The animation has 19 frames.
The axis of the actor on the first frame of the animation is (0, 0, 0).
The axis of the actor on the last frame of the animation is (20, 30, 0)
That means, the actor moves 20 aim to x and moves 30 aim to y.
Please, take a look at this code
myActor.setPos( 0, 0, 0 )
myActor.pose( 'WALK', 0 )
print "-----------------------------"
print myActor.getX()
print myActor.getY()
myActor.pose( 'WALK', 18 )
print "-----------------------------"
print myActor.getX()
print myActor.getY()
The result is this…
-----------------------------
0
0
-----------------------------
0
0
But, I expect it ot be like this…
-----------------------------
0
0
-----------------------------
20
3
As I already said, I’m writing a sport game. So, I really need to know the axis of my actor on particular frame on the animation.
Already I opened and read walk.egg file. And it has axis(offset?) for every frames into <S$Anim> tag under <Xfm$Anim_S$>tag.
But, I don’t know how to get this value on my code.
Is there anybody who has any idea for this?
ANY IDEA WOULD BE FINE!!!
JUST, TELL ME PLEASE!!!
Have a good day.
.