diff options
Diffstat (limited to 'io_scene_gltf2/blender')
-rwxr-xr-x | io_scene_gltf2/blender/imp/gltf2_blender_scene.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/io_scene_gltf2/blender/imp/gltf2_blender_scene.py b/io_scene_gltf2/blender/imp/gltf2_blender_scene.py index e6eadcd6..1a276960 100755 --- a/io_scene_gltf2/blender/imp/gltf2_blender_scene.py +++ b/io_scene_gltf2/blender/imp/gltf2_blender_scene.py @@ -50,7 +50,9 @@ class BlenderScene(): def create_animations(gltf): """Create animations.""" if gltf.data.animations: - for anim_idx, _anim in enumerate(gltf.data.animations): + # NLA tracks are added bottom to top, so create animations in + # reverse so the first winds up on top + for anim_idx in reversed(range(len(gltf.data.animations))): BlenderAnimation.anim(gltf, anim_idx) # Restore first animation |