performQuery(_:)
Returns all entities of the scene which pass the query.
Declaration
@MainActor @preconcurrency func performQuery(_ query: EntityQuery) -> QueryResult<Entity>Discussion
When in update(context:), call entities(matching:updatingSystemWhen:) instead of performQuery. This allows the System to sleep on some platforms when there is no matching component, reducing unnecessary work.