Root Node not shown in Inspector but TransformNodes are?

I’m unsure if this is a bug or intended, but if I create a Node in the scenegraph root that’s intended to be a static parent of various child TransformNodes or Meshes, then the node and its children aren’t displayed in the inspector scenegraph. However if I use a TransformNode it all displays and also if I create a Node that’s not in the root, then that node and its children will display in the inspector.

Everything is rendered correctly in 3D. It’s just not represented correctly in the Inspector.

And here’s what it looks like in Inspector:

But I’d expect it to look like this:

  • parentNode
    • childNodeOfNode
  • parentTransformNode
    • childNodeOfTransformNode
1 Like

Seems like a bug… also if you set the parent of a Node and then set the parent back to null, then that node is added to the Scene’s rootNodes shows up in the inspector (because if parent is ever set back to null, then it gets added to rootNodes).

I sent out a draft PR with a couple options to fix this: Add directly constructed Nodes to rootNodes by ryantrem · Pull Request #15089 · BabylonJS/Babylon.js (github.com)

5 Likes

Thanks @ryantrem !

1 Like

Yup! Sounds fair enough to me. Would be a nice adding. Thx for that and have a great day :sunglasses:

This PR has been merged.

2 Likes

Thanks @ryantrem!

1 Like