physics.setReportCollisionsInContentCoordinates()
Syntax
physics.setReportCollisionsInContentCoordinates( enabled )
|
enabled (required)
Boolean. Sets the physics engine to return the specific collision point between two bodies, in content coordinates. This means that when two bodies collide, the event.x
and event.y
reported to the collision listener will equate to the exact point where collision occurred.
Example
if ( physics.getReportCollisionsInContentCoordinates() ) then
physics.setReportCollisionsInContentCoordinates( false )
else
physics.setReportCollisionsInContentCoordinates( true )
end
|