Skip to content

SceneLoader.ImportAnimations doesn't work in all cases #7931

@phenry20

Description

@phenry20

In the following PG: https://www.babylonjs-playground.com/#KM2N07#15
You will see that the imported animation only moves part of the arm when it should be moving the entire body. This is due to the fact that the default targetConverter targets the wrong Nodes when multiple types of nodes have the same name.

I've written some code to get it working on my side (https://www.babylonjs-playground.com/#KM2N07#17)

Essentially the targetConverter needs a way to know what type the target is so that it can make the correct mapping instead of guessing by name. I've made an attempt to do that, but I don't know if this is the correct way to fix this issue that's why I haven't created a MR PR for it yet.

Please let me know if I'm on the right track and whether I should create a MR PR or not. If I'm not on the right track can you please steer me in the right direction so that a proper fix can be implemented?

Thanks.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions