Physics Constraint Component User Guide

Overview

Physics Constraint Components operate just like Physics Constraints Actors, except they are used in Blueprints or can be created in C++. Given the flexibility of Blueprints and the power of C++, you can constrain just about any Physics Body in your project using Physics Constraint Components.

This document will cover Physics Constraint Component basic creation in a Blueprint.

This document assumes that the user has some knowledge of Blueprints and the Blueprint Editor. See: Blueprints Visual Scripting for more information.

Usage

  1. Create the Components that will be used to constrain. For this demonstration, two StaticMesh Components referencing the StaticMesh Shape_Cube will be used.

    You will need to position your Components that you want constrained. For this guide, these two cubes are used.

  2. Add Component => Physics Constraint.

  3. Position the Physics Constraint Component where you wish the joint of the constraint to be.

    PhysConBP_Loc.png
  4. You must manually type in the Components name you wish to constrain. Type in the component name you wish to constrain in the Component Name 1 => Component Name property.

  5. Type in the component name you wish to constrain in the Component Name 2 => Component Name property.

  6. Set the Physics Constraint Properties:

    • Angular Swing 1Motion and Angular Swing 2Motion to ACM_Limited.

    • Swing 1Limit Angle and Swing 2Limit Angle to 45 degrees.

    • Disable Swing Limit Soft.

    Want to know what all the properties on a Physics Constraint Component affect? See the Physics Constraint Reference for specific details.

  7. Rotate the Physics Constraint Component as necessary to account for Linear and Angular Limits.

  8. Place the Blueprint Actor in a level and position it where you need it.

    PhysConBP_IntoWorld.png
  9. Test by using Simulate in Editor or Play in Editor.

    PhysConBP_Sim.png