Manually advances the physics simulation by one iteration.
You can optionally pass in the delta
and correction
values to be used by Engine.update.
If undefined they use the Matter defaults of 60Hz and no correction.
Calling step
directly bypasses any checks of enabled
or autoUpdate
.
It also ignores any custom getDelta
functions, as you should be passing the delta
value in to this call.
You can adjust the number of iterations that Engine.update performs internally. Use the Scene Matter Physics config object to set the following properties:
positionIterations (defaults to 6) velocityIterations (defaults to 4) constraintIterations (defaults to 2)
Adjusting these values can help performance in certain situations, depending on the physics requirements of your game.
name | type | arguments | Default | description |
---|---|---|---|---|
delta | number | <optional> | 16.666 |
The delta value. |