Mover constraints

The physics engine includes the following Constraints that apply force or torque to move one or more assemblies. In addition, various mechanical constraints are available which behave as conceptual mechanical connections, including hinges, springs, ropes, and more.

Linear Velocity

LinearVelocity applies force on an assembly to maintain a constant velocity along a 3D vector, line, or 2D plane
Angular Velocity

AngularVelocity applies torque on an assembly to maintain a constant angular velocity
Align Position

AlignPosition applies force to move two attachments together, or to move one attachment to a goal position
Align Orientation

AlignOrientation applies torque to align two attachments, or to align one attachment with a goal orientation
Vector Force

VectorForce applies constant linear force on an assembly
Torque

Torque applies constant torque on an assembly from its center of mass
Line Force

LineForce applies force along the theoretical line connecting its two attachments

Constraint visualization

To accurately visualize constraints in Studio, you can use the following options from the toolbar's Model tab:

Constraints tools indicated in Model tab

Show Welds — Show WeldConstraints, separately from the visualization of other constraints.

Constraint Details — Show complete visual details of non-weld constraints.

Scale — Relative scale of visualizations.

Create constraints

Mover constraints typically connect one or two Attachments or Bones. When connected to Bones, the constraint will use their animated position and orientation.

To create a mover constraint, you can use either the Create tool or the Explorer window.

  1. In the Model tab, access the Create button's picker menu and select the desired constraint type, for example Angular Velocity.

    Constraint picker indicated in Studio toolbar
  2. In the 3D viewport, hover over any Part or MeshPart and click to add a new Attachment to the part at the visualized point. Alternatively, hover over and click an existing Attachment or Bone to use it for the constraint.

  3. Some mover constraints utilize or support a secondary attachment in their functionality, so the tool might prompt you to repeat the previous step on another Part, MeshPart, or Attachment, or Bone.

    AngularVelocity using one attachment
    AngularVelocity using one attachment
    AlignPosition using two attachments
    AlignPosition using two attachments

Physical simulation

To simulate physics while moving or rotating parts, you can switch to Physical mode in the Studio's toolbar, effectively forcing parts to obey physical limitations. For example, if you drag one part around the scene and it collides with another part, it will physically push that part out of the way.

Legacy mover conversion

If your experience relies on legacy BodyMover‑based constraints, review the following notes when converting to modern mover constraints.

AlignPosition satisfies the majority of use cases covered by the deprecated BodyPosition mover. To sync with how the legacy mover treated each component independently and allowed a different force along each dimension, the ForceLimitMode property of AlignPosition allows the constraint to operate in Magnitude mode or PerAxis mode:

  • In Magnitude mode, the existing behavior is preserved and MaxForce is interpreted as a magnitude.

  • In PerAxis mode, the force along each axis can be specified independently. Because the maximum force is specified as a vector, the reference frame of the force can also be specified through the ForceRelativeTo property with World, Attachment0, and Attachment1 options. Additionally, the formulation for the internal controller is modified to match that of BodyPosition.

AlignOrientation satisfies the majority of use cases covered by the deprecated BodyGyro mover. The AlignType modes of AlignOrientation provide sufficient freedom for most applications and the combination of multiple constraints can replicate the vector torque limit. Additionally, the PrimaryAxisLookAt mode forces the primary axis of the constraint's first attachment (Attachment0) to always point towards the second attachment (Attachment1), making it a lot easier to add things such as motion tracking security cameras or guided missiles.

LinearVelocity satisfies the majority of use cases covered by the deprecated BodyVelocity mover. Although the legacy mover allows for a MaxForce vector, the typical application of that vector force was to zero a particular component, allowing the constraint to be disabled along that dimension. LinearVelocity achieves a similar effect by operating in distinct VelocityConstraintMode modes that corresponded to one (Line), two (Plane), and three (Vector) dimensions.

Additionally, the ForceLimitMode property with the option of PerAxis accommodates any applications of the vector force with all non‑zero components, such as an increase in the force along a single axis to counteract gravity.

Although AngularVelocity has some discrepancies with the deprecated BodyAngularVelocity mover, specific cases related to those discrepancies have not been highlighted by the community, nor internally.

As a separate improvement, AngularVelocity works with Attachments and the RelativeTo property lets you specify the CFrame in which the force is specified, for example World or Attachment1.

VectorForce satisfies all use cases offered by the deprecated BodyForce and BodyThrust movers. The modern constraint works with Attachments and its RelativeTo property lets you apply force to a relative offset from center, similar to how BodyThrust.Location worked.

A combination of LineForce and AlignOrientation satisfies the majority of use cases covered by the deprecated RocketPropulsion mover. In the example of a guided missile, LineForce can be used to control the "follow target" behavior of RocketPropulsion while AlignOrientation and its LookAtPosition property can be used to control the "face target" behavior.