FilterBuilder property

pull/1/head
cosmonaut 2022-03-05 22:13:44 -08:00
parent b2b32b0424
commit b19d8441b1
1 changed files with 2 additions and 5 deletions

View File

@ -4,6 +4,8 @@ public abstract class System : EntityComponentReader
{
public abstract void Update(TimeSpan delta);
public FilterBuilder FilterBuilder => new FilterBuilder(ComponentDepot);
public System(World world)
{
world.AddSystem(this);
@ -14,11 +16,6 @@ public abstract class System : EntityComponentReader
return EntityStorage.Create();
}
protected FilterBuilder CreateFilterBuilder()
{
return new FilterBuilder(ComponentDepot);
}
protected void Set<TComponent>(in Entity entity, in TComponent component) where TComponent : struct
{
ComponentDepot.Set<TComponent>(entity.ID, component);