Free node automatically together with freeing another node not in the same subtree

Hi,

I have the following tree:

  • Main
    • Node 1
    • Node 2
      • Subnode 2.1
        • SubSubnode 2.1.1

If I free 2.1 it will automatically free 2.1.1
But I also want to remove 1 when I remove 2.1 automatically (without handling free signals of 2.1)

Is it possible to do this without breaking the tree?
(Maybe using Owner field or there might be any other field for that?)

The ‘owner’ property is really only used to save scenes. Otherwise it’s just a normal property. I think you should either connect the signal to free Node 1, or also free Node 1 with a function call when you do the same function call on Node 2.1

Easiest way to do this would probably be a signal that calls a method in Main and deletes the nodes from there.