Documentation

Unity Engine


Unity Engine


AddAdditionalQuery()

Add an additional query description to a single EntityQuery.
Read time 1 minuteLast updated 3 days ago

Definition

  • Type: Method
  • Namespace: Unity.Entities
  • Assembly: UnityEngine.EntitiesModule
public EntityQueryBuilder AddAdditionalQuery()

Returns

Type

Description

EntityQueryBuilderReturns the amended EntityQuery.

Remarks

The ability to construct an EntityQuery from multiple query descriptions is preserved for backwards compatibility, but the use of this feature is strongly discouraged in user projects. Queries with multiple query descriptions are not guaranteed to function correctly in all contexts.
The resulting EntityQuery will match all entities matched by any individual query description. In terms of set theory, the query matches the union of its query descriptions, not the intersection.
The EntityQuery created from this builder matches entities that have a Parent component but no Child component OR have a Child component but no Parent component.