When animation ends...

Hi guys,

I want to hide an actor, as soon as it completes playing its animation. Is there a simple to do this?

def breakCement3(self):
        self.cement.actorInterval("cementAn3", playRate = 1 ).start()
        return Task.done

Any way to check if the animation is playing or it has finished? Or if the last frame has been reached?


  self.cement.actorInterval("cementAn3", playRate = 1 )actorInterval("cementAn3", playRate = 1 ),

Excellent ynjh_jo, thanks a lot, worked like a charm.

(For anyone else who might want to use this, please note that ynjh_jo made a typing mistake, the code is actually :

Sequence(self.cement.actorInterval("cementAn3", playRate = 1 ),Func(self.cement.cleanup)).start()