ServersYour serverFor creatorsForumFAQDocumentationSecurity
Download the launcher
  1. Documentation
  2. Client functions
  3. getPedBoneTransform

Function

getPedBoneTransform

ClientPedsTrilogy Hub only

Returns both the position and rotation of a ped's bone at once (x, y, z, rx, ry, rz), which is faster than calling getPedBonePosition and getPedBoneRotation separately every frame. Values come from the current animation frame in this game.

Syntax

float, float, float, float, float, float getPedBoneTransform(ped ped, int bone)

Arguments

pedped
A player or an NPC.
boneint
Bone number (as in getBoneIDs) or a game bone index.

Returns

x, y, z and rx, ry, rz in degrees, or false.

Example

local x, y, z, rx, ry, rz = getPedBoneTransform(localPlayer, 25)

See also