PhysicsBody.MassOverride
Selects which of the mass, rotational inertia and center of mass are overridden with authored values instead of being computed from the attached shapes.
Read time 1 minuteLast updated 14 days ago
Definition
- Type: Enum
- Namespace: Unity.U2D.Physics
- Assembly: UnityEngine.PhysicsCore2DModule
[Flags]public enum PhysicsBody.MassOverride
Fields
Value | Description |
|---|---|
| All | Override the mass, rotational inertia and center of mass. |
| CenterOfMass | Override the center of mass. A rotational inertia that is not itself overridden is shifted to the overridden center. |
| Mass | Override the mass. A rotational inertia that is not itself overridden is scaled to the overridden mass, as if the same shapes had a different uniform density. |
| None | Nothing is overridden; the whole mass configuration is computed from the attached shapes. |
| RotationalInertia | Override the rotational inertia. |