QuerySystemBase.Filter.md

November 22, 2024 ยท View on GitHub

Friflo.Engine.ECS

Friflo.Engine.ECS.Systems.QuerySystemBase

QuerySystemBase.Filter Property

A query filter used to restrict the entities returned by its Query property.
See remarks to add a tag filter to a custom QuerySystem.

public Friflo.Engine.ECS.QueryFilter Filter { get; }

Property Value

QueryFilter

Remarks

Additional tag filters can be added in the constructor of a class extending a QuerySystem.

class MySystem : QuerySystem<Scale3>
{
    public MySystem() => Filter.AnyTags(Tags.Get<MyTag>()); 
    protected override void OnUpdate() { ... }
}