Constructor
new Box2dWeldJoint(objectA, objectB, anchor, collideopt)
Create a weld joint
Parameters:
Name | Type | Attributes | Default | Description |
---|---|---|---|---|
objectA | Box2dObject | |||
objectB | Box2dObject | |||
anchor | Vector2 | |||
collide | boolean | <optional> | false |
- Source
Extends
- Box2dJoint
Methods
getFrequency() → {number}
Get the frequency in Hertz
- Source
Returns:
- Type:
- number
getLocalAnchorA() → {Vector2}
Get the local anchor point relative to objectA's origin
- Source
Returns:
- Type:
- Vector2
getLocalAnchorB() → {Vector2}
Get the local anchor point relative to objectB's origin
- Source
Returns:
- Type:
- Vector2
getReferenceAngle() → {number}
Get the reference angle
- Source
Returns:
- Type:
- number
getSpringDampingRatio() → {number}
Get the damping ratio
- Source
Returns:
- Type:
- number
setFrequency(hz)
Set the frequency in Hertz
Parameters:
Name | Type | Description |
---|---|---|
hz | number |
- Source
setSpringDampingRatio(ratio)
Set the damping ratio
Parameters:
Name | Type | Description |
---|---|---|
ratio | number |
- Source