Example usage for com.badlogic.gdx.physics.box2d.joints RevoluteJoint getLowerLimit

List of usage examples for com.badlogic.gdx.physics.box2d.joints RevoluteJoint getLowerLimit

Introduction

In this page you can find the example usage for com.badlogic.gdx.physics.box2d.joints RevoluteJoint getLowerLimit.

Prototype

public float getLowerLimit() 

Source Link

Document

Get the lower joint limit in radians.

Usage

From source file:org.ams.physics.things.def.DefParser.java

License:Open Source License

public static HingeDef hingeToDefinition(Hinge hinge) {
    HingeDef hingeDef = new HingeDef();
    RevoluteJoint joint = hinge.getJoint();

    jointToDefinition(hinge, hingeDef);/*  w  w  w  .j a  v  a 2  s.c  om*/

    hingeDef.enableLimit = joint.isLimitEnabled();
    hingeDef.enableMotor = joint.isMotorEnabled();
    hingeDef.lowerLimit = joint.getLowerLimit();
    hingeDef.upperLimit = joint.getUpperLimit();
    hingeDef.motorSpeed = joint.getMotorSpeed();
    hingeDef.maxMotorTorque = joint.getMaxMotorTorque();

    return hingeDef;
}