|
libgdx API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.badlogic.gdx.physics.box2d.Joint
com.badlogic.gdx.physics.box2d.joints.LineJoint
public class LineJoint
A line joint. This joint provides two degrees of freedom: translation along an axis fixed in body1 and rotation in the plane. You can use a joint limit to restrict the range of motion and a joint motor to drive the motion or to model joint friction.
Field Summary |
---|
Fields inherited from class com.badlogic.gdx.physics.box2d.Joint |
---|
addr, jointEdgeA, jointEdgeB |
Constructor Summary | |
---|---|
LineJoint(World world,
long addr)
|
Method Summary | |
---|---|
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. |
float |
getLowerLimit()
Get the lower joint limit, usually in meters. |
float |
getMaxMotorForce()
Set/Get the maximum motor force, usually in N. |
float |
getMotorForce()
Get the current motor force, usually in N. |
float |
getMotorSpeed()
Get the motor speed, usually in meters per second. |
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/Get the maximum motor force, usually in N. |
void |
setMotorSpeed(float speed)
Set the motor speed, usually in meters per second. |
Methods inherited from class com.badlogic.gdx.physics.box2d.Joint |
---|
getAnchorA, getAnchorB, getBodyA, getBodyB, getReactionForce, getReactionTorque, getType, isActive |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public LineJoint(World world, long addr)
Method Detail |
---|
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 getMaxMotorForce()
public float getMotorForce()
|
libgdx API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |