Skip to main content

Camera::attachToPedBone

Attaches a camera to the bone specified.

Syntax

``` camera.attachToPedBone(ped, boneIndex, x, y, z, heading); ```

Parameters

  • ped: Ped handle or object
  • boneIndex: ([Bone IDs](/bones))
  • x:
  • y:
  • z:
  • heading:

Example

This creates a camera and then sets it active and attaches it to the player's hand so it stays focused. The camera will not move with the character.

See also