Difference between revisions of "B2.Body:destroyFixture"

From GiderosMobile
m (Text replacement - "</source" to "</syntaxhighlight")
Line 10: Line 10:
 
<source lang="lua">
 
<source lang="lua">
 
b2.Body:destroyFixture(fixture)
 
b2.Body:destroyFixture(fixture)
</source>
+
</syntaxhighlight>
  
 
=== Parameters ===
 
=== Parameters ===

Revision as of 16:35, 12 July 2023


Available since: Gideros 2011.6
Class: b2.Body

Description

Destroys a fixture. This removes the fixture from the broad-phase and destroys all contacts associated with this fixture. This will automatically adjust the mass of the body if the body is dynamic and the fixture has positive density. All fixtures attached to a body are implicitly destroyed when the body is destroyed.

Warning: this function is locked during callbacks. <source lang="lua"> b2.Body:destroyFixture(fixture) </syntaxhighlight>

Parameters

fixture: (b2.Fixture) the fixture to be removed




LiquidFun