Blend animation help

Hello everyone.

I made some smooth transformation between animations (walk and stand) in blend mode.
Every thing work well except ‘attack’ animation.
I want to play it at once in 1 keyboard pushed.
So I need to know when the last frame is play. And activate ‘stand’ animation instead.

I can’t find the way to get the value of animation attack.
at first I tried.

if actor.getCurrentFrame('attack') == 39 :
##  do some thing

It’s not work.
So I checked bug by ‘print getCurrentFrame(‘attack’)’ in task.
And I notice that output text is not attack’s.

How can I know the current frame value of each animation in blend mode?
Thank you. :frowning:

Hmm, looks like a bug in getCurrentFrame(). Still, you can do this instead:


This will tell you the current frame of the ‘attack’ animation. However, it might be better to use a pair of ActorIntervals in a Sequence, if you want to stitch two animations back-to-back.