How to code the 'reverse action' of making one object child of another?


#1

I’ve understood how to make one object child of another


but how to - let’s say - dechild it from its parent?

thanks

.mario


#2

Hi mariochiesa,

you can remove an item from its parent by calling the following method:

item.removeFromParent()

Please note that this method is currently internal (it will not be recognised by your code editor, but it will still work). We plan to make this public along with other methods soon. Stay tuned!