physics.stop()

Type Function
Library physics.*
Return value Boolean
Revision 2017.3060
Keywords physics, stop, stop physics
See also physics.start()
physics.pause()

Overview

Stops the physics engine. This function will return false and display a warning message if the API cannot be processed.

Gotchas

Syntax

physics.stop()

Example

local physics = require( "physics" )
physics.start()

-- stop phsyics simulation after 2 seconds
timer.performWithDelay( 2000, function()
    
    physics.stop()

end, 1 )