Package-level declarations
Types
Box2D building DSL utility class. BodyDef extension storing FixtureDef instances in fixtureDefinitions collection. Provides inlined building methods that construct fixture definitions.
Marks KTX Box2D type-safe builders.
Box2D building DSL utility class. FixtureDef extension exposing new properties. Note that when using fixture builders from BodyDefinition, FixtureDefinition.shape field should not be modified - fixture's shape of the chosen type will already be set in the FixtureDefinition instance.
Callback lambda for querying with an AABB.
Callback lambda for ray-casts.
Stores constants that can be returned by KtxQueryCallback to control its behavior.
Stores constants that can be returned by KtxRayCastCallback to control its behavior.
Properties
Functions
Type-safe Body building DSL.
Utility builder method for constructing fixtures with PolygonShape set as box. Note that - contrary to PolygonShape.setAsBox methods - this method consumes actual not halved box width and height sizes.
Utility builder method for constructing fixtures with ChainShape.
Utility builder method for constructing fixtures with ChainShape. Note that this method consumes a FloatArray instead of array of Vector2 instances, which might be less readable, but creates slightly less garbage. This method is advised to be used instead of the Vector2-consuming variant on mobile devices.
Utility builder method for constructing fixtures with CircleShape.
Handles additional building properties provided by BodyDefinition and FixtureDefinition. Prefer this method over World.createBody when using BodyDefinition directly.
World factory function.
Allows to create a DistanceJoint. this
Body will be set as the JointDef.bodyA and will be available through Joint.getBodyA.
Utility builder method for constructing fixtures with EdgeShape.
Utility builder method for constructing fixtures with EdgeShape. Note that this method consumes floats instead of Vector2 instances, which might be less concise, but also creates slightly less garbage. This method is advised to be used instead of the Vector2-consuming variant on mobile devices.
Utility extension method for setting up of FixtureDef.filter. Allows to copy an existing Filter instance to avoid copying each property manually.
Inlined utility extension method for setting up of FixtureDef.filter. Exposes Filter properties under this
.
Utility builder method for constructing fixtures of custom shape type.
Allows to create a FrictionJoint. this
Body will be set as the JointDef.bodyA and will be available through Joint.getBodyA.
Allows to create a GearJoint. this
Body will be set as the JointDef.bodyA and will be available through Joint.getBodyA.
Utility builder method for constructing fixtures with looped ChainShape.
Utility builder method for constructing fixtures with looped ChainShape. Note that this method consumes a FloatArray instead of array of Vector2 instances, which might be less readable, but creates slightly less garbage. This method is advised to be used instead of the Vector2-consuming variant on mobile devices.
Allows to create a MotorJoint. this
Body will be set as the JointDef.bodyA and will be available through Joint.getBodyA.
Allows to create a MouseJoint. this
Body will be set as the JointDef.bodyA and will be available through Joint.getBodyA.
Utility builder method for constructing fixtures with PolygonShape.
Utility builder method for constructing fixtures with PolygonShape. Note that this method consumes a FloatArray instead of array of Vector2 instances, which might be less readable, but creates slightly less garbage. This method is advised to be used instead of the Vector2-consuming variant on mobile devices.
Allows to create a PrismaticJoint. this
Body will be set as the JointDef.bodyA and will be available through Joint.getBodyA.
Allows to create a PulleyJoint. this
Body will be set as the JointDef.bodyA and will be available through Joint.getBodyA.
Allows to create a RevoluteJoint. this
Body will be set as the JointDef.bodyA and will be available through Joint.getBodyA.
Allows to create a RopeJoint. this
Body will be set as the JointDef.bodyA and will be available through Joint.getBodyA.
Allows to create a WeldJoint. this
Body will be set as the JointDef.bodyA and will be available through Joint.getBodyA.
Allows to create a WheelJoint. this
Body will be set as the JointDef.bodyA and will be available through Joint.getBodyA.