<!--
{
  "availability" : [
    "iOS: 18.0.0 -",
    "iPadOS: 18.0.0 -",
    "macCatalyst: 18.0.0 -",
    "macOS: 15.0.0 -",
    "tvOS: 26.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "RealityKit",
  "identifier" : "/documentation/RealityKit/SceneUpdateContext/entities(matching:updatingSystemWhen:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "RealityKit"
    ],
    "preciseIdentifier" : "s:17RealityFoundation18SceneUpdateContextV8entities8matching18updatingSystemWhenAA11QueryResultVyAA6EntityCGAA0mK0V_AA0iD9ConditionVtF"
  },
  "title" : "entities(matching:updatingSystemWhen:)"
}
-->

# entities(matching:updatingSystemWhen:)

Returns all entities which pass the query predicate of the query.

```
func entities(matching query: EntityQuery, updatingSystemWhen condition: SystemUpdateCondition) -> QueryResult<Entity>
```

## Parameters

`query`

The query identifying which entities you want to fetch.

`condition`

How often the [`System`](/documentation/RealityKit/System) is updated (if the query is not empty).

## Discussion

Calling this function can increase the rate at which RealityKit calls
the [`update(context:)`](/documentation/RealityKit/System/update(context:)) method.
If `condition` is not met for the current update,
this method returns an empty result.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)