Multiple animations in single .X file...

This question seems very stupid but still I could not find an answer by my own: how can I load multiple animations from a single .X file?

I tried…

x = Actor ('model.x', {'anim1' : 'model.x', 'anim2' : 'model.x'})

…without success. Whatever animation I play a very weird animation plays, which is the same, and makes some parts of the model disapear. This might be useful, I get these messages on the command line when loading the model in Panda:

:egg2pg(warning): AnimBundle boy specifies contradictory number of frames.
:egg2pg(warning): AnimBundle boy specifies contradictory frame rates.
:egg2pg(warning): AnimBundle boy specifies contradictory number of frames.
:egg2pg(warning): AnimBundle boy specifies contradictory frame rates.
:egg2pg(warning): AnimBundle boy specifies contradictory number of frames.

Thanks a lot!

Just use:

x = Actor ('model.x')

The names of the animations are based on the animation names within the .x file. Try x.pprint() to list them if you’re unsure what they are.

The warning message about the “contradictory number of frames” indicates a self-inconsistency within your .x file. Perhaps you have generated the .x file with an entry for each keyframe only, instead of with an entry for each frame (which is the only form actually supported by Panda).

David

Ok, thanks a lot :smiley: There are a few issues with the animations that I think are “export” related. Our graphic artists are using 3DSMax 2010 I think, I hope that is not the problem :stuck_out_tongue: