<!--
{
  "availability" : [
    "iOS: -",
    "iPadOS: -",
    "macCatalyst: -",
    "macOS: -",
    "tvOS: -",
    "visionOS: -",
    "watchOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "SpriteKit",
  "identifier" : "/documentation/SpriteKit/SKPhysicsJointFixed/joint(withBodyA:bodyB:anchor:)",
  "metadataVersion" : "0.1.0",
  "role" : "Type Method",
  "symbol" : {
    "kind" : "Type Method",
    "modules" : [
      "SpriteKit"
    ],
    "preciseIdentifier" : "c:objc(cs)SKPhysicsJointFixed(cm)jointWithBodyA:bodyB:anchor:"
  },
  "title" : "joint(withBodyA:bodyB:anchor:)"
}
-->

# joint(withBodyA:bodyB:anchor:)

Creates a new fixed joint.

```
class func joint(withBodyA bodyA: SKPhysicsBody, bodyB: SKPhysicsBody, anchor: CGPoint) -> SKPhysicsJointFixed
```

## Parameters

`bodyA`

The first body to connect. The body must be connected to a node that is already part of the scene’s node tree.

`bodyB`

The second body to connect. The body must be connected to a node that is already part of the scene’s node tree.

`anchor`

The anchor point for the connection in the scene’s coordinate system.

## Return Value

A new fixed joint.

## Discussion

You must add the joint to a physics world associated with the scene before it takes effect.

---

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)