Collider:setRestitution

Sets the restitution (bounciness) of the Collider. By default, the restitution of two Colliders is combined (the max is used) when they collide to cause them to bounce away from each other. The initial restitution is 0.

Collider:setRestitution(restitution)

Arguments

NameTypeDescription
restitutionnumberThe new restitution.

Returns

Nothing

See also