Multiple 3D model animations (SOLVED)

I am trying to make 3D model characters animate in my 2D puzzle game. But I can’t register multiple animations to Defold.

Set this to the Animation Set File that contains the animations you want to use on the model.
Creating a model component

What does Animation Set File mean? How can I set multiple animations in one .dae file?
%E3%82%AD%E3%83%A3%E3%83%97%E3%83%81%E3%83%A3

1 Like

@sven is our 3D animation expert. Let’s ask him!

1 Like

Thanks for your reply!

@sven, I think to attach more than one animation to the 3D model is impossible in terms of specification. As in the below screenshots, an animation is named after its .dae file, but in this case, model.play_anim doesn’t make sense. Is there any way to set multiple animations in a model?

%E3%82%AD%E3%83%A3%E3%83%97%E3%83%81%E3%83%A31
%E3%82%AD%E3%83%A3%E3%83%97%E3%83%81%E3%83%A32

EDIT:
I inserted animation_clips to .dae, like here:

<library_animation_clips>
<animation_clip id=“walk”>
<instance_animation url="#player_body_pose_matrix"/>
</animation_clip>
</library_animation_clips>

But these lines could not be loaded on Defold.

1 Like

Multiple animations for dae are possible. I can’t remember right now how to properly do it with Blender but it can be done.

2 Likes

Hi,

You need to create a “Animation Set” file! :slight_smile: The animation set will point to one or more DAE files that each contain one animation. So instead of specifying one DAE in your model file, you point to your new animation set instead.

This means that you currently need to export animations for 3D models in separate files, one file per animation, which isn’t a very nice solution. We have plans to support multiple animations per Collada file but can’t promise when this will be prioritised.

5 Likes

Thanks! I’ll try it lator.

1 Like

Oh… I missed “Animation Set” section on “New File” options. :sweat_smile:
I leave a screenshot for future users.
%E3%82%AD%E3%83%A3%E3%83%97%E3%83%81%E3%83%A3

6 Likes