Interface PhysicsMaterial
Hierarchy
- PhysicsMaterial
Index
Properties
Optional frictionSearch playground for friction
Sets the friction used by this material
The friction determines how much an object will slow down when it is in contact with another object. This is important for simulating realistic physics, such as when an object slides across a surface.
If not provided, a default value of 0.5 will be used.
Optional friction CombineSearch playground for frictionCombine
Describes how two different friction values should be combined. See PhysicsMaterialCombineMode for more details.
If not provided, will use PhysicsMaterialCombineMode.MINIMUM
Optional restitutionSearch playground for restitution
Sets the restitution of the physics material.
The restitution is a factor which describes, the amount of energy that is retained after a collision, which should be a number between 0 and 1..
A restitution of 0 means that no energy is retained and the objects will not bounce off each other, while a restitution of 1 means that all energy is retained and the objects will bounce.
Note, though, due that due to the simulation implementation, an object with a restitution of 1 may still lose energy over time.
If not provided, a default value of 0 will be used.
Optional restitution CombineSearch playground for restitutionCombine
Describes how two different restitution values should be combined. See PhysicsMaterialCombineMode for more details.
If not provided, will use PhysicsMaterialCombineMode.MAXIMUM
Optional static FrictionSearch playground for staticFriction
Sets the static friction used by this material.
Static friction is the friction that must be overcome before a pair of objects can start sliding relative to each other; for physically-realistic behaviour, it should be at least as high as the normal friction value. If not provided, the friction value will be used
Physics material class Helps setting friction and restitution that are used to compute responding forces in collision response