On both the AncestryChanged and Destroying event documentations, it mentions to use the other event for conditions inside of Studio. What does that mean? Why specifically studio? These lines make me think this condition will happen in-game, and it’s not clear to me if I must connect to both of these for all of my destroyed connection needs.
I am not 100% on this so take it with a grain of salt, but I believe this simply means that if you select an object in Explorer and delete it, AncestryChanged will fire, but not Destroying. During the course of normal gameplay, connecting to Destroying will be sufficient. The note about deleting objects in Studio is likely only relevant to plugins. It would be good if the documentation was more clear on this point.
I think it refers to the deletion of an object using a Plugin or the Explorer, or setting manually the Parent proerty to nil
.
To add, this is because history in studio depends on the object you deleted not being destroyed so when you undo, the object can be retrieved. They are simply unparented and held in memory. Destroying locks the parent forever.
Thank you for bringing this up! I’m going to follow up with some internal teams, then update the documentation. I will follow up on this thread when the work is complete.