What am I doing wrong? I am trying to add a parent component to an entity but just does not work.
https://docs.unity3d.com/Packages/com.unity.entities@1.0/api/Unity.Transforms.Parent.html
public void OnUpdate(ref SystemState state)
{
state.Enabled = false;
EntityCommandBuffer ecb = new EntityCommandBuffer(Allocator.Temp);
var theParent = ecb.CreateEntity();
ecb.SetName(theParent, "The Parent");
var theChild = ecb.CreateEntity();
ecb.SetName(theChild, "The Child");
ecb.AddComponent(theChild, new Parent { Value = theParent }); // Doesnt get added
ecb.AddComponent(theParent, new SomeComponent { thingy = 4 }); // Added
ecb.AddComponent(theChild, new SomeComponent { thingy = 2 }); // Added
ecb.Playback(state.EntityManager);
ecb.Dispose();
}