# joint

> Talos 0.7 · Since 0.6

Use it in a scene entity's `components` list as `{ "type": "joint", … }`. The contract writes the fields flat and refuses unknown keys.

## Fields

| Field | Type | Required | Default | Allowed values | Description |
|---|---|---|---|---|---|
| `kind` | `JointKind` | yes |  | `fixed`, `revolute`, `prismatic` |  |
| `connectedTo` | `string` | no |  |  | The entity whose body is B. Absent, the joint is to the world: a fixed point in space. |
| `anchor` | `Vec3` | no | `[0,0,0]` |  | The joint's point on A, in A's local frame: metres along A's axes from its origin, not multiplied by its scale. Default [0, 0, 0], the entity origin. |
| `connectedAnchor` | `Vec3` | no |  |  | The joint's point on B, in B's local frame — or a world point when there is no B. Default: wherever `anchor` is when the scene loads, so the joint starts together. |
| `axis` | `Vec3` | no | `[0` |  | The free axis of a revolute or prismatic joint, in A's local frame; any length but zero. Default [0, 1, 0] (a door's hinge). A fixed joint has no free axis and ignores it. |
| `limits` | `Vec2` | no |  |  | [min, max] along the free axis: radians for a revolute joint, metres for a prismatic one, measured from the pose the joint was made in. Absent, unlimited. |
| `motor` | `JointMotor` | no |  |  |  |
| `collideConnected` | `boolean` | no |  |  | Whether A and B still collide with each other. Default false: a hinge's two leaves overlap. |

## Rules that can refuse it

- `animator-feet-invalid`
- `animator-root-motion-hips`
- `animator-root-motion-joint-missing`
- `feel/anim-pop`
- `joint-invalid`
- `joint.limits-invalid`
- `joint.motor-invalid`

## Example

From the contract's tested fixture `fixtures/contract/full20/scene.json#crate-b`.

```json
{
  "type": "joint",
  "kind": "revolute",
  "connectedTo": "crate-a",
  "anchor": [
    0,
    -0.5,
    0
  ],
  "axis": [
    1,
    0,
    0
  ],
  "limits": [
    -0.5,
    0.5
  ]
}
```
