How to display proper model hierarchy

Hi all, I would like to display the imported model hierarchy correctly like in the inspector with nodes and children, I tried mesh.getDescendants() and mesh.getChildTransformNodes() but i only get a total list back instead of hierarchy that is correct. I can make a playground if needed.

I think you need to create your own recursive function that return the model hierarchy.

2 Likes

Yes i got it thank you.

1 Like