rojo/.cursor/rules/roblox/en-us/physics/constraints/animation.md
Joe b47eef1173 Add live syncback functionality and optimize service encoding
- Introduced a new endpoint `/api/syncback` for one-click full sync from Roblox Studio to the filesystem, eliminating the need for an active WebSocket connection.
- Implemented `SyncbackRequest` and `ServiceChunk` structures to handle service-level properties and child instances during syncback.
- Enhanced `encodeService` to include ObjectValue carriers for accurate reference handling and prevent data loss.
- Updated the syncback process to utilize Luau-style relative paths for reference attributes, improving path management and consistency.
- Integrated session caching in the matching algorithm to optimize performance during syncback operations.

These changes significantly improve the live syncback experience, ensuring reliable data synchronization and enhanced performance during development.
2026-02-18 22:34:52 -06:00

2.1 KiB
Raw Blame History

title description
AnimationConstraint AnimationConstraint aligns two base parts with an animate-able kinematic or force-based joint.
For an overview on creating, visualizing, and simulating mover constraints, including `Class.AnimationConstraint`, see [mover constraints](../../physics/mover-constraints.md). Also see [Roblox units](../../physics/units.md) to understand how Roblox units compare to metric units.

An Class.AnimationConstraint constrains its Class.Attachment|Attachments by an offset transform. It can be either kinematic for snap‑to behavior or it can follow the target trajectory using force and torque. limited by Class.AnimationConstraint.MaxForce|MaxForce and Class.AnimationConstraint.MaxTorque|MaxTorque.

Transform

The constraint's Class.AnimationConstraint.Transform|Transform is the internal Datatype.CFrame that's manipulated when the constraint is being animated. How this transform is reached depends on the constraint's kinematic setting.

Kinematic

When the constraint's Class.AnimationConstraint.IsKinematic|IsKinematic property is true, the connected parts snap to the transform instantly and precisely without participating in physics simulation. When false, the connected parts follow the trajectory using force and torque.

Force and torque

If the constraint is not set to kinematic, the connected parts follow a trajectory toward the transform using a maximum force/torque limited by Class.AnimationConstraint.MaxForce|MaxForce and Class.AnimationConstraint.MaxTorque|MaxTorque respectively.