Physics Pose and Physics Area components
Understand the Physics Pose and Physics Area components you use to build a 2D Physics Core object.
Read time 2 minutesLast updated 14 days ago
Understand the Physics Pose and Physics Area components you use to build 2D physics objects.
A physics GameObject in 2D Physics Core needs the following components:
- A Physics Pose component, which makes the GameObject a 2D Physics Core object.
- One or more Physics Area components, which give the GameObject a shape to collide with and display.
Pose
A Physics Pose component sets the following:
- How and when Unity updates the position and rotation of the GameObject with the result of physics calculations.
- Which simulation world the GameObject belongs to.
- Whether the GameObject is fixed in place or responds to forces like gravity.
- How the GameObject responds to forces.
A Physics Pose component doesn't have a physical shape.
Poses store a object, so some 2D Physics Core properties in components refer to the underlying body.
PhysicsBodyArea
A Physics Area component sets the shape of a GameObject for physics calculations and collisions.
An Area component also sets which other shapes it can collide with, and its surface properties such as friction and bounciness.
Areas store a object, so some 2D Physics Core properties in components refer to the underlying shape.
PhysicsShape2D Physics Core provides nine types of Physics Area component.
Physics Area component | Shape |
|---|---|
| Physics Area Capsule | A capsule formed by a central line and a radius. |
| Physics Area Circle | A circle with a center and a radius. |
| Physics Area Composite | A compound shape that combines other shapes. For more information, refer to Combine Physics Core 2D API shapes. |
| Physics Area Contour | A set of points that form a closed shape. Concave sections are allowed. |
| Physics Area Path | A set of points that form a barrier. |
| Physics Area Polygon | A set of points that form a closed shape. Concave sections aren't allowed. |
| Physics Area Primitive | Lets you select between a circle, capsule, polygon, segment, or chain segment. |
| Physics Area Segment | Two points that form a line. |
| Physics Area Sprite | The physics outline of a sprite. |
You can add multiple areas to a GameObject. For example, add one area for the solid part of a character, then a second, larger area as a trigger zone that detects when something enters it.