AddSkeletonAnimationKeyFrame()

Syntax

AddSkeletonAnimationKeyFrame(#Mesh, AnimationName$, Bone$, Time, RotationX, RotationY, RotationZ, RotationW, Mode [, TranslateX, TranslateY, TranslateZ [, ScaleX, ScaleY, ScaleZ]])
Description
Creates a new step for the specified animation. A skeleton animation can be created with CreateSkeletonAnimation().

Parameters

#Mesh The mesh to use.
AnimationName$ The name of the animation to add the step.
Bone$ The bone name to use.
Time The time in the animation to set the keyframe (in milliseconds). This value has to be between zero and the 'Length' defined in CreateSkeletonAnimation().
RotationX, RotationY, RotationZ, RotationW The bone rotation for this step.
Mode The mode to use for the bone rotation. It can be one of the following value:
  #PB_Orientation_PitchYawRoll  : 'RotationX' (pitch), 'RotationY' (yaw), 'RotationZ' (roll), applied in this order (default).
  #PB_Orientation_Quaternion    : 'RotationX', 'RotationY', 'RotationZ', 'RotationW' for quaternion values
  #PB_Orientation_AngleAxis     : 'RotationX', 'RotationY', 'RotationZ' for rotation axis, and 'RotationW' for the angle (in degree).
  #PB_Orientation_Direction     : alias for #PB_Orientation_DirectionLDVZN
  #PB_Orientation_DirectionLDVX : 'RotationX', 'RotationY', 'RotationZ' for direction vector (local direction vector X), and 'RotationW' for angle (in degree).
  #PB_Orientation_DirectionLDVY : 'RotationX', 'RotationY', 'RotationZ' for direction vector (local direction vector Y), and 'RotationW' for angle (in degree).
  #PB_Orientation_DirectionLDVZ : 'RotationX', 'RotationY', 'RotationZ' for direction vector (local direction vector Z), and 'RotationW' for angle (in degree).
  #PB_Orientation_DirectionLDVXN: 'RotationX', 'RotationY', 'RotationZ' for direction vector (local direction vector -X), and 'RotationW' for angle (in degree).
  #PB_Orientation_DirectionLDVYN: 'RotationX', 'RotationY', 'RotationZ' for direction vector (local direction vector -Y), and 'RotationW' for angle (in degree).
  #PB_Orientation_DirectionLDVZN: 'RotationX', 'RotationY', 'RotationZ' for direction vector (local direction vector -Z), and 'RotationW' for angle (in degree).
TranslateX, TranslateY, TranslateZ (optional) The bone translation for this step.
ScaleX, ScaleY, ScaleZ (optional) The bone scale for this step.

Return value

None.

See Also

CreateSkeletonAnimation()

Supported OS

All

Skeleton Index - CreateBone() ->