Trigger Animations Groups

Hey everyone!

Quick question:

I exported a GLB file from blender (it´s a slot machine), there are 4 animation groups in 4 different meshes!

The problem is, when i uploaded the file to the sandbox, only the first group plays automatically.

If i get in the sandbox details of the other groups is possible to play them, so HOW CAN I PLAY ALL THE GROUPS AT THE SAME TIME ?

If you use SceneLoader.ImportAnimationsAsync.then(e=>{})
You can find e.animationGroups in the return value.

Otherwise you can find other animations in scene after loading.

// Play all imported animations
SceneLoader.ImportMeshAsync("url","filename").then(e=>{
    let animationGroups = e.animationGroups 
    animationGroups.forEach(e=>{
        e.play(true)
    )
})

// If you use Append
SceneLoader.AppendAsync("url","filename").then(()=>{
    let animationGroups = scene.animationGroups 
    animationGroups.forEach(e=>{
        e.play(true)
    )
})
5 Likes

Thank a lot!