Class b2GearJointDef

Gear joint definition. This definition requires two existing revolute or prismatic joints (any combination will work). The provided joints must attach a dynamic body to a static body.

Hierarchy

Index

Constructor methods

Properties

Constructor methods

constructor(): b2GearJointDef

Constructor.

Returns

b2GearJointDef

Properties

public bodyA: b2Body

The first attached body.

public bodyB: b2Body

The second attached body.

public collideConnected: boolean

Set this flag to true if the attached bodies should collide.

public joint1: b2Joint

The first revolute/prismatic joint attached to the gear joint.

public joint2: b2Joint

The second revolute/prismatic joint attached to the gear joint.

public ratio: number

The gear ratio.

public type: number

The joint type is set automatically for concrete joint types.

public userData: any

Use this to attach application specific data to your joints.