Skip to main content

Pin Constraint

Pro Feature

Pro features are only available with a Professional licence. To upgrade, visit cavalry.scenegroup.co.

Intro

Pin Shapes to their original position in a Forge Dynamics simulation while allowing them to rotate. Shapes can also be driven by a motor meaning

UI

Horizontal Alignment - Align the position of the Constraint to the left (-1) or right (1) edge of the Body.

Vertical Alignment - Align the position of the Constraint to the top (1) or bottom (-1) edge of the Body.

Motor - When checked, a pinned Shape is given a rotational force.

Motor Speed - Set the speed in which the pinned Shape rotates.

Maximum Torque - Set the torque or force for the Motor. A higher value will mean the pinned Shape is capable of acting against Shapes with a greater density.

Limit Rotation - When checked, the Constraint's rotation will be never go above or below the Rotational Limits.

Rotational Limits - Set an upper (U) and lower (L) angle to clamp the Constraint's rotation.

Breakable - When enabled, the Constraint can be broken by other forces.

Breaking Force - Set the amount of force required to break the Constraint.

Example
  1. Create a Rectangle.
  2. Set Width to 600 and Height to 30.
  3. Create an Ellipse.
  4. Set the Ellipse's Position to 100,400.
  5. Select both Shapes and click the Forge icon in the Shelf.
  6. Under the Forge Dynamics Bodies tab, click the gear icon for the Rectangle.
  7. Click the + next to the Constraints attribute towards the bottom of the window and choose Pin Constraint.
  8. Hit Play

The Ellipse will fall and hit the Rectangle causing it to rotate in place.