FixtureDef class
class FixtureDef { /** * The shape to use in the fixture. This must be set. */ Shape shape; /** * Use this to store application specific fixture data. */ dynamic userData; /** * The friction coefficient, usually in the range [0,1]. */ double friction; /** * The restitution (elasticity) usually in the range [0,1]. */ double restitution; /** * The density, usually in kg/m^2 */ double density; /** * A sensor shape collects contact information but never generates a collision * response. */ bool isSensor; /** * Contact filtering data; */ Filter filter; /** * Constructs a new FixtureDef with default values. */ FixtureDef() : shape = null, userData = null, friction = 0.2, restitution = 0.0, density = 0.0, filter = new Filter(), isSensor = false { // Setup the filter. filter.categoryBits = 0x0001; filter.maskBits = 0xFFFF; filter.groupIndex = 0; } }
Constructors
new FixtureDef() #
Constructs a new FixtureDef with default values.
FixtureDef() : shape = null, userData = null, friction = 0.2, restitution = 0.0, density = 0.0, filter = new Filter(), isSensor = false { // Setup the filter. filter.categoryBits = 0x0001; filter.maskBits = 0xFFFF; filter.groupIndex = 0; }