<!--
{
  "availability" : [
    "iOS: 8.0.0 - 26.0.0",
    "iPadOS: 8.0.0 - 26.0.0",
    "macCatalyst: 13.1.0 - 26.0.0",
    "macOS: 10.8.0 - 26.0.0",
    "tvOS: 9.0.0 - 26.0.0",
    "visionOS: 1.0.0 - 26.0.0",
    "watchOS: 3.0.0 - 26.0.0"
  ],
  "documentType" : "symbol",
  "framework" : "SceneKit",
  "identifier" : "/documentation/SceneKit/SCNPhysicsBody/dynamic()",
  "metadataVersion" : "0.1.0",
  "role" : "Type Method",
  "symbol" : {
    "kind" : "Type Method",
    "modules" : [
      "SceneKit"
    ],
    "preciseIdentifier" : "c:objc(cs)SCNPhysicsBody(cm)dynamicBody"
  },
  "title" : "dynamic()"
}
-->

# dynamic()

Creates a physics body that can be affected by forces and collisions.

```
class func dynamic() -> Self
```

## Return Value

A new physics body object.

## Discussion

Use dynamic bodies for the elements of your scene that are moved by the physics simulation.

For the body to participate in collision detection or respond to forces, you must attach it to the [`physicsBody`](/documentation/SceneKit/SCNNode/physicsBody) property of an [`SCNNode`](/documentation/SceneKit/SCNNode) object in a scene.

SceneKit automatically creates a physics shape for the body when you attach it to a node, based on that node’s [`geometry`](/documentation/SceneKit/SCNNode/geometry) property. To create a physics shape that’s based on the geometries of a node and its hierarchy of children, or to control the level of detail in a physics shape, create the physics shape manually using an [`SCNPhysicsShape`](/documentation/SceneKit/SCNPhysicsShape) class method.

> Note:
> For nodes containing custom geometry, the physics shape SceneKit automatically creates is a rough approximation of the geometry. This approximation, or *convex hull*, provides a compromise between accuracy and performance in collision detection. For the best collision detection performance, create an ``doc://com.apple.scenekit/documentation/SceneKit/SCNPhysicsShape`` instance based on a basic geometry class (``doc://com.apple.scenekit/documentation/SceneKit/SCNBox``, ``doc://com.apple.scenekit/documentation/SceneKit/SCNSphere``, ``doc://com.apple.scenekit/documentation/SceneKit/SCNPyramid``, ``doc://com.apple.scenekit/documentation/SceneKit/SCNCone``, ``doc://com.apple.scenekit/documentation/SceneKit/SCNCylinder``, or ``doc://com.apple.scenekit/documentation/SceneKit/SCNCapsule``).

## See Also

[`type`](/documentation/SceneKit/SCNPhysicsBody/type)

A constant that determines how the physics body responds to forces and collisions.

[`physicsShape`](/documentation/SceneKit/SCNPhysicsBody/physicsShape)

An object that defines the solid volume of the physics body for use in collision detection.



---

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)