update(context:)
Updates entities up to once every scene update.
Declaration
@MainActor @preconcurrency mutating func update(context: SceneUpdateContext)Parameters
- context:
The scene context for the scene to update.
Mentioned in
Discussion
RealityKit calls this method on all registered systems, as often as the updatingSystemWhen parameter of entities(matching:updatingSystemWhen:) defines.
The context parameter contains a reference to the scene that the System is updating, along with the elapsed time since RealityKit last called the update method for the same scene. Use entities(matching:updatingSystemWhen:) inside this method for the most optimized way to find the matching entities for this System.