public class PrismaticJoint extends Joint
addr, jointEdgeA, jointEdgeB
Constructor and Description |
---|
PrismaticJoint(World world,
long addr) |
Modifier and Type | Method and Description |
---|---|
void |
enableLimit(boolean flag)
Enable/disable the joint limit.
|
void |
enableMotor(boolean flag)
Enable/disable the joint motor.
|
float |
getJointSpeed()
Get the current joint translation speed, usually in meters per second.
|
float |
getJointTranslation()
Get the current joint translation, usually in meters.
|
Vector2 |
getLocalAnchorA() |
Vector2 |
getLocalAnchorB() |
Vector2 |
getLocalAxisA() |
float |
getLowerLimit()
Get the lower joint limit, usually in meters.
|
float |
getMaxMotorForce()
Get the max motor force, usually in N.
|
float |
getMotorForce(float invDt)
Get the current motor force given the inverse time step, usually in N.
|
float |
getMotorSpeed()
Get the motor speed, usually in meters per second.
|
float |
getReferenceAngle()
Get the reference angle.
|
float |
getUpperLimit()
Get the upper joint limit, usually in meters.
|
boolean |
isLimitEnabled()
Is the joint limit enabled?
|
boolean |
isMotorEnabled()
Is the joint motor enabled?
|
void |
setLimits(float lower,
float upper)
Set the joint limits, usually in meters.
|
void |
setMaxMotorForce(float force)
Set the maximum motor force, usually in N.
|
void |
setMotorSpeed(float speed)
Set the motor speed, usually in meters per second.
|
getAnchorA, getAnchorB, getBodyA, getBodyB, getCollideConnected, getReactionForce, getReactionTorque, getType, getUserData, isActive, setUserData
public PrismaticJoint(World world, long addr)
public Vector2 getLocalAnchorA()
public Vector2 getLocalAnchorB()
public Vector2 getLocalAxisA()
public float getJointTranslation()
public float getJointSpeed()
public boolean isLimitEnabled()
public void enableLimit(boolean flag)
public float getLowerLimit()
public float getUpperLimit()
public void setLimits(float lower, float upper)
public boolean isMotorEnabled()
public void enableMotor(boolean flag)
public void setMotorSpeed(float speed)
public float getMotorSpeed()
public void setMaxMotorForce(float force)
public float getMotorForce(float invDt)
public float getMaxMotorForce()
public float getReferenceAngle()