AnimationConstraint
Aligns two BaseParts with an animate-able kinematic or force-based joint.
Memory category | PhysicsParts |
---|
Member index 8
Description
An AnimationConstraint constrains its Attachments so
that they're offset by the Transform
CFrame
. The Transform can be set
manually during RunService.PreSimulation or by an Animator.
History 12
Members 8
IsKinematic
Type | Default | |
---|---|---|
bool | false |
When true, the connected parts follow the Transform perfectly without participating in physics simulation. When false, the connected parts follow the trajectory using forces and torques limited by AnimationConstraint.MaxForce and AnimationConstraint.MaxTorque.
Thread safety | ReadSafe |
---|---|
Category | Data |
Loaded/Saved | true |
History 1
- 569 Add IsKinematic
MaxForce
Type | Default | |
---|---|---|
float | 10000 |
Maximum force magnitude the constraint can apply to achieve its goal. Only used if IsKinematic is false.
Thread safety | ReadSafe |
---|---|
Category | Compliance |
Loaded/Saved | true |
MaxTorque
Type | Default | |
---|---|---|
float | 10000 |
Maximum torque the constraint can use to reach its goal. Only used if IsKinematic is false.
Thread safety | ReadSafe |
---|---|
Category | Compliance |
Loaded/Saved | true |
Transform
Type | Default | |
---|---|---|
CFrame |
The internal CFrame that is manipulated when a AnimationConstraint is being animated.
Timing
AnimationConstraint transforms are not applied immediately, but rather as a batch in a parallel job after RunService.PreSimulation, immediately before physics steps. The deferred batch update is much more efficient than many immediate updates.
If the AnimationConstraint is part of an animated model with an Animator, then AnimationConstraint.Transform is usually overwritten every frame by the Animator after RunService.PreAnimation and before RunService.PreSimulation.
Thread safety | ReadSafe |
---|---|
Category | Data |
Loaded/Saved | true |