bounceIterations
The number of bounce passes the world runs each simulation step, after contacts and joints have been solved. Each pass pushes apart the bodies of every contact that struck with a bounciness above zero, at the speed its bounciness allows, and never adds energy. More passes let a bounce settle more accurately, which reduces unwanted spinning of bouncing boxes, and each pass adds work for every bouncy contact in the world. The value must be from the minimum up to the maximum bounce pass count.
阅读时间1 分钟最后更新于 6 天前
Definition
- Type: Property
- Namespace: Unity.U2D.Physics
- Assembly: UnityEngine.PhysicsCore2DModule
public int bounceIterations { readonly get; set; }
Remarks
The bounce pass count range is PhysicsConstants.MinBounceIterations to PhysicsConstants.MaxBounceIterations. Setting a value outside that range clamps it into the range. See PhysicsWorld.bounceIterations.