Key Driven Animations

Hi everyone
I was just wondering what the code would be like if I wanted to do some key driven animations. Would I have to import any modules?

Not sure what you’re asking for here. The type of animation system is determined by your animation tool of choice; and this is usually keyframe animation, though other mechanisms are possible, I suppose. Is that what you’re referring to?

But once it’s exported to Panda, it’s all just a table of joints and frames. No keys, no constraints, no anything else. It just plays back exactly as exported, using the normal Actor interface as described in the manual.


I was wondering something more along the lines of If i wanted the character to play an animation when a certian key on the key board was hit

Use accept(‘k’, func), as shown in the manual and in the Panda3D samples, and define your func to start the animation playing.


ok I’ve written the code and it is saying ‘self’ is not defined. What code should I type to define ‘self’?

Never mind I’ve got it.
thank you