Constructor
new Box2dTargetJoint(object, fixedObject, worldPos)
Create a target joint
Parameters:
Name | Type | Description |
---|---|---|
object | Box2dObject | |
fixedObject | Box2dObject | |
worldPos | Vector2 |
- Source
Extends
- Box2dJoint
Methods
getFrequency() → {number}
Gets the joint frequency in Hertz
- Source
Returns:
- Type:
- number
getMaxForce() → {number}
Gets the maximum force in Newtons
- Source
Returns:
- Type:
- number
getTarget() → {Vector2}
Get the target point in world coordinates
- Source
Returns:
- Type:
- Vector2
setFrequency(hz)
Sets the joint frequency in Hertz
Parameters:
Name | Type | Description |
---|---|---|
hz | number |
- Source
setMaxForce(force)
Sets the maximum force in Newtons
Parameters:
Name | Type | Description |
---|---|---|
force | number |
- Source
setTarget(pos)
Set the target point in world coordinates
Parameters:
Name | Type | Description |
---|---|---|
pos | Vector2 |
- Source