I was investigating megacity-metro DOTS project.
And I have stumbled upon RootEntity component.
public struct RootEntity : IComponentData
{
public Entity Entity;
}
I’m not sure what is exact purpose of this, I’m guessing it might be topmost element in some object hierarchy.
Let’s say we got ship made of some smaller parts each smaller part entity has RootEntity pointing to topmost Entity. Am I guessing correctly ?
It’s just used to track which entity to attach generated vehicle pieces / effects onto because the visuals authoring is on a separate GameObject / entity from the main one, nothing deeper than that judging by there being no other references to the component.