A Boolean value that specifies whether SceneKit can automatically mark the physics body at rest.
- iOS 8.0+
- macOS 10.10+
- Mac Catalyst 13.0+
- tvOS 9.0+
- watchOS 3.0+
true (the default), SceneKit keeps track of whether the body is moving or affected by forces, automatically setting its
is property to
true when it is “at rest.” The physics simulation runs faster when simulating fewer bodies, so treating a body as resting temporarily removes it from the simulation to improve performance.
SceneKit automatically returns a resting body to the simulation if another body collides with it, if you change its position or velocity, or if you apply a force to it. However, SceneKit uses a faster, less accurate simulation when deciding whether to change a body’s
is property back to
false. If testing your app reveals unexpected physics behaviors involving resting bodies, changing those bodies’ allowsResting property to
false may improve simulation accuracy.