physics.setPositionIterations()

Type Function
Library physics.*
Return value none
Revision Release 2024.3703
Keywords physics, position iterations
See also physics.start()
physics.setVelocityIterations()

Overview

Sets the accuracy of the engine's position calculations. The default value is 3.

Syntax

physics.setPositionIterations( value )
value (required)

Number. The number of iterations. The default value is 3, which means that the engine will iterate through three position approximations per frame for each object. Increasing this number will cause fewer momentary inaccuracies like overlapping objects, but it will increase computational overhead. The default value should work for most general cases.

Example

physics.setPositionIterations( 6 )