Joints

Overview

Joints are a special type of attached objects that allow you to physically emulate how two connected objects would behave relative to each other. Joints are useful for creating stuff like chains, ropes, and all types of swinging objects. Joints in the uEngine use Nvidia PhysX technology. You can read more in-depth information on how joints work in PhysX here:

http://docs.nvidia.com/gameworks/content/gameworkslibrary/physx/guide/Manual/Joints.html

How to Use Joints

Attaching a joint to a parent

  • Select the child object.
  • Highlight the parent.
  • Press RMB on the parent object.
  • Select either "Create joint with bone" or "Create joint with bone (with offset)".

  • Select the bone of the parent object to attach the child to.
  • Select the bone of the child object to attach to the parent.

Note that the child object needs to have the following physics properties:

Note that if the child object has a collision group other than "no collision", it will likely collide with its parent object, which may lead to jittering and bugs. So it may be useful to set the child object's collision group to "no collision" before creating a joint.

Now the joint child is attached to the parent object.

Joint's Properties

The properties of the joint can be found in the child objects properties in the "Joint" block:

  • Edit Pose

    This lets you change the position of the pivot relative to where the child object will move. Press the edit button, move the pivot to the desired position, then press ESC to confirm the position.

  • Joint Type

    There are currently 3 different types of joints:

    • Distance: this is a legacy type of joint that keeps the child object on a certain distance from the parent. Think of a leash or a rope. Both min and max distance can be specified.

    • Fixed: the child object's position and orientation will be fixed but its child bones will behave physically. Useful for creating chains, ropes, etc.
    • D6: The D6 joint is by far the most complex of the standard PhysX joints. In its default state it behaves like a fixed joint  that is, it rigidly fixes the constraint frames of its two actors. However, individual degrees of freedom may be unlocked to permit any combination of rotation around the x-, y-, and z- axes, and translation along these axes.
  • D6 Joint Properties

The D6 joint has its own set of properties that will show up under the "Params" block when you select the D6 type of joint:

Linear Motion: lets you choose the type of a linear (translational) motion for each axis of the child object:

    •  X/Y/Z-Type: the type of the linear motion for the child object along the specified axis. There are 3 types of linear motions:
      1. Free: the child object will move freely along the specified axis without any constraints.
      2. Locked: the child object will not move along the specified axis at all.
      3. Limited: the child object will move along the specified axis according to the specified settings. It will try to stay within the limits that you set for it. This is by far the most useful and customizable option.

Rotation:

    • X/Y/Z Axis Rotation: the type of rotation for the child object along the specified axis. Just like with the linear motion, there are 3 types of rotation:
      1. Free: the child object will rotate freely around the specified axis without any constraints.
      2. Locked: the child object will not rotate around the specified axis at all.
      3. Limited: the child object will rotate around the specified axis according to the specified settings. It will try to stay within the limits that you set for it. This is by far the most useful and customizable option.
  • Limited Motion Type Properties


Limits may be either hard or soft. When a hard limit is reached, the relative motion will simply stop, if the limit is configured with zero restitution, or bounce, if the restitution is non-zero. When a soft limit is violated, the solver will pull the joint back toward the limit using a spring specified by the limit's spring and damping parameters.

You can change the physics of the joint that has limited Linear motion or Rotation type by adjusting these parameters:
  • Value: the amount of freedom the joint has to move around. In the case of Rotation, it is measured in degrees, in the case of linear motion, it is in meters.
  • Restitution: how strongly the joint is pulled back, if it reaches the limits. If set to 0, the joint isn't pulled back at all.
  • Spring: how much the joint is pushed back, if it goes outside the limit. The higher this value, the lower the chance for the joint to go outside the limits.
  • Damping: the higher this value, the faster the motion speed of the joint dampens.

Destroying a joint

To destroy a joint, select the child object, right click on it and in the context menu go to Selected → Destroy Joint on Selected.


On this page:





Exodus SDK © 2005-2023, 4A Games Limited. Developed by 4A Games®.
4A Games® is a registered trademark, and 4A Games Limited, Exodus SDK and their respective logos are trademarks of 4A Games Limited.
Published by Deep Silver. Deep Silver is a division of PLAION GmbH, Austria. Deep Silver and Plaion are registered trademarks of PLAION GmbH.
Metro Exodus is inspired by the internationally best-selling novels METRO 2033 and METRO 2034 by Dmitry Glukhovsky.
All other trademarks, logos and copyrights are property of their respective owners. All rights reserved.
By using this site, downloading or using the Exodus SDK or related content, you are agreeing to be bound by the terms of the End User License Agreement.


EULA