Use a Physics Material 2D to adjust the friction and bounce that occur between 2D physics objects when they collide.
For more information on game physics, refer to 3D Physics.
To create a Physics Material 2D, go to Assets > Create > 2D > Physics Material 2D.
To use your Physics Material 2D, assign it to the Material property of a Collider 2D or Rigidbody 2D component.
Note: The equivalent asset in 3D physics is referred to as a Physics Material.
A Physics Material 2D contains the following properties.
| Property | Description |
|---|---|
| Friction | Sets the coefficient of friction for this collider. |
| Bounciness | Sets the degree to which collisions rebound from the surface. A value of 0 indicates no bounce while a value of 1 indicates a perfect bounce with no loss of energy. |
| Friction Combine | Defines how to combine both material friction values when two colliders interact. The options are:
|
| Bounce Combine | Defines how to combine both material bounciness values when two colliders interact. The options are:
|
PhysicsMaterial2D