Lumberyard
User Guide (Version 1.15)

 AWS Documentation » Amazon Lumberyard » User Guide » Working with Component Entities » Component Reference » PhysX Rigid Body Physics

# PhysX Rigid Body Physics

The PhysX Rigid Body Physics component defines the entity that it's attached to as a rigid object. You choose a Motion Type of Static or Dynamic. The Static motion type means that the object is not movable and has no additional parameters. You apply the Dynamic motion type to a movable object and modify its parameters to define how it interacts with other objects.

Use the following parameters in the PhysX Rigid Body Physics component. These parameters are exposed when you set the Motion type to Dynamic.

Lumberyard's PhysX system exposes the principal axes of the moment of inertia but does not allow manipulation of the whole tensor.

PhysX Rigid Body Physics Parameters

Parameter Description
Motion type Specify how the body's motion evolves.
• Dynamic – The body is mobile and its motion is determined by the simulation. Responds to forces and collisions.

• Static – The body cannot move but can be collided with. Suitable for static geometry such as terrain.

Initial linear velocity

Applies to speed of movement in a linear direction. The rigid body begins with this initial linear velocity when it is activated in the simulation.

Default: `0`

Initial angular velocity

Applies to speed of movement in an angular, or turning motion. The rigid body begins with this initial angular velocity when it is activated in the simulation.

Default: `0`

Mass

The rigid body's mass in kilograms. This value must be non-negative. The PhysX system treats `0` as an infinite mass.

Default: `1`

Compute inertia

When set, automatically calculates the moment of inertia—how hard it is to change the rotation of the body—based on the collision geometry.

Inertia diagonal values

The principal axes of the moment of inertia tensor. The larger the value, the harder it is to change the angular momentum about the corresponding axis. Each value must be non-negative. PhysX treats `0` as an infinite inertia.

COM offset

Center of mass (COM) offset in the body's local frame. This parameter is useful if you use assets that are not centered at the origin, or to create certain effects such as top-heaviness.

Linear damping

The rate at which linear velocity decays over time even if no forces are acting on the body.

Angular damping

The rate at which angular velocity decays over time even if no torques are acting on the body.

Sleep threshold

Kinetic energy per unit mass below which the body goes to sleep. You must specify a positive value.