namespace Theater_ECS_Example.Archetypes; using Theater_ECS_Example.Components; using Theater_ECS; struct MovingBall : IArchetypeable { public void Instantiate(ECS ecs, Entity e) { ecs.Components.AddToEntity(e, ecs.Components.GetId(typeof(Position).GetFullName(.. scope .())), &Position()); ecs.Components.AddToEntity(e, ecs.Components.GetId(typeof(Velocity).GetFullName(.. scope .())), &Velocity()); ecs.Components.AddToEntity(e, ecs.Components.GetId(typeof(Sprite).GetFullName(.. scope .())), &Sprite(1)); } }