SetSpritePhysicsDensity

Description

Sets the density value to use for the given sprite shape during physics calculations. Default value is 1.0. This affects the mass calculation for the given size of the sprite. This command will recalculate the mass and center of mass for this sprite. Use a shapeID of 0 to apply this density to all shapes or specify a shape ID greater than 0 to apply it only to that shape. Shape IDs start at 1 for the first shape.

Definition

SetSpritePhysicsDensity( iSpriteIndex, density, shapeID )

Parameters