Package com.badlogic.gdx.physics.box2d.joints

Examples of com.badlogic.gdx.physics.box2d.joints.DistanceJoint


   * to cease colliding.
   * @warning This function is locked during callbacks. */
  public Joint createJoint (JointDef def) {
    long jointAddr = createProperJoint(def);
    Joint joint = null;
    if (def.type == JointType.DistanceJoint) joint = new DistanceJoint(this, jointAddr);
    if (def.type == JointType.FrictionJoint) joint = new FrictionJoint(this, jointAddr);
    if (def.type == JointType.GearJoint) joint = new GearJoint(this, jointAddr, ((GearJointDef) def).joint1, ((GearJointDef) def).joint2);
    if (def.type == JointType.MotorJoint) joint = new MotorJoint(this, jointAddr);
    if (def.type == JointType.MouseJoint) joint = new MouseJoint(this, jointAddr);
    if (def.type == JointType.PrismaticJoint) joint = new PrismaticJoint(this, jointAddr);
View Full Code Here


   * @warning This function is locked during callbacks. */
  public Joint createJoint (JointDef def) {
    org.jbox2d.dynamics.joints.JointDef jd = def.toJBox2d();
    org.jbox2d.dynamics.joints.Joint j = world.createJoint(jd);
    Joint joint = null;
    if (def.type == JointType.DistanceJoint) joint = new DistanceJoint(this, (org.jbox2d.dynamics.joints.DistanceJoint)j);
    if (def.type == JointType.FrictionJoint) joint = new FrictionJoint(this, (org.jbox2d.dynamics.joints.FrictionJoint)j);
    if (def.type == JointType.GearJoint) joint = new GearJoint(this, (org.jbox2d.dynamics.joints.GearJoint)j, ((GearJointDef) def).joint1, ((GearJointDef) def).joint2);
    if (def.type == JointType.MotorJoint) joint = new MotorJoint(this, (org.jbox2d.dynamics.joints.MotorJoint)j);
    if (def.type == JointType.MouseJoint) joint = new MouseJoint(this, (org.jbox2d.dynamics.joints.MouseJoint)j);
    if (def.type == JointType.PrismaticJoint) joint = new PrismaticJoint(this, (org.jbox2d.dynamics.joints.PrismaticJoint)j);
View Full Code Here

   * to cease colliding.
   * @warning This function is locked during callbacks. */
  public Joint createJoint (JointDef def) {
    long jointAddr = createProperJoint(def);
    Joint joint = null;
    if (def.type == JointType.DistanceJoint) joint = new DistanceJoint(this, jointAddr);
    if (def.type == JointType.FrictionJoint) joint = new FrictionJoint(this, jointAddr);
    if (def.type == JointType.GearJoint) joint = new GearJoint(this, jointAddr);
    if (def.type == JointType.MouseJoint) joint = new MouseJoint(this, jointAddr);
    if (def.type == JointType.PrismaticJoint) joint = new PrismaticJoint(this, jointAddr);
    if (def.type == JointType.PulleyJoint) joint = new PulleyJoint(this, jointAddr);
View Full Code Here

   * @warning This function is locked during callbacks. */
  public Joint createJoint (JointDef def) {
    org.jbox2d.dynamics.joints.JointDef jd = def.toJBox2d();
    org.jbox2d.dynamics.joints.Joint j = world.createJoint(jd);
    Joint joint = null;
    if (def.type == JointType.DistanceJoint) joint = new DistanceJoint(this, (org.jbox2d.dynamics.joints.DistanceJoint)j);
    if (def.type == JointType.FrictionJoint) joint = new FrictionJoint(this, (org.jbox2d.dynamics.joints.FrictionJoint)j);
    // FIXME if(def.type == JointType.GearJoint) joint = new DistanceJoint(this, (org.jbox2d.dynamics.joints.DistanceJoint)j);
    if (def.type == JointType.MouseJoint) joint = new MouseJoint(this, (org.jbox2d.dynamics.joints.MouseJoint)j);
    if (def.type == JointType.PrismaticJoint) joint = new PrismaticJoint(this, (org.jbox2d.dynamics.joints.PrismaticJoint)j);
    if (def.type == JointType.PulleyJoint) joint = new PulleyJoint(this, (org.jbox2d.dynamics.joints.PulleyJoint)j);
View Full Code Here

   * @warning This function is locked during callbacks. */
  public Joint createJoint (JointDef def) {
    org.jbox2d.dynamics.joints.JointDef jd = def.toJBox2d();
    org.jbox2d.dynamics.joints.Joint j = world.createJoint(jd);
    Joint joint = null;
    if (def.type == JointType.DistanceJoint) joint = new DistanceJoint(this, (org.jbox2d.dynamics.joints.DistanceJoint)j);
    if (def.type == JointType.FrictionJoint) joint = new FrictionJoint(this, (org.jbox2d.dynamics.joints.FrictionJoint)j);
    if (def.type == JointType.GearJoint) joint = new GearJoint(this, (org.jbox2d.dynamics.joints.GearJoint)j, ((GearJointDef) def).joint1, ((GearJointDef) def).joint2);
    if (def.type == JointType.MouseJoint) joint = new MouseJoint(this, (org.jbox2d.dynamics.joints.MouseJoint)j);
    if (def.type == JointType.PrismaticJoint) joint = new PrismaticJoint(this, (org.jbox2d.dynamics.joints.PrismaticJoint)j);
    if (def.type == JointType.PulleyJoint) joint = new PulleyJoint(this, (org.jbox2d.dynamics.joints.PulleyJoint)j);
View Full Code Here

   * @warning This function is locked during callbacks. */
  public Joint createJoint (JointDef def) {
    org.jbox2d.dynamics.joints.JointDef jd = def.toJBox2d();
    org.jbox2d.dynamics.joints.Joint j = world.createJoint(jd);
    Joint joint = null;
    if (def.type == JointType.DistanceJoint) joint = new DistanceJoint(this, (org.jbox2d.dynamics.joints.DistanceJoint)j);
    if (def.type == JointType.FrictionJoint) joint = new FrictionJoint(this, (org.jbox2d.dynamics.joints.FrictionJoint)j);
    if (def.type == JointType.GearJoint) joint = new GearJoint(this, (org.jbox2d.dynamics.joints.GearJoint)j, ((GearJointDef) def).joint1, ((GearJointDef) def).joint2);
    if (def.type == JointType.MotorJoint) joint = new MotorJoint(this, (org.jbox2d.dynamics.joints.MotorJoint)j);
    if (def.type == JointType.MouseJoint) joint = new MouseJoint(this, (org.jbox2d.dynamics.joints.MouseJoint)j);
    if (def.type == JointType.PrismaticJoint) joint = new PrismaticJoint(this, (org.jbox2d.dynamics.joints.PrismaticJoint)j);
View Full Code Here

   * to cease colliding.
   * @warning This function is locked during callbacks. */
  public Joint createJoint (JointDef def) {
    long jointAddr = createProperJoint(def);
    Joint joint = null;
    if (def.type == JointType.DistanceJoint) joint = new DistanceJoint(this, jointAddr);
    if (def.type == JointType.FrictionJoint) joint = new FrictionJoint(this, jointAddr);
    if (def.type == JointType.GearJoint) joint = new GearJoint(this, jointAddr, ((GearJointDef) def).joint1, ((GearJointDef) def).joint2);
    if (def.type == JointType.MouseJoint) joint = new MouseJoint(this, jointAddr);
    if (def.type == JointType.PrismaticJoint) joint = new PrismaticJoint(this, jointAddr);
    if (def.type == JointType.PulleyJoint) joint = new PulleyJoint(this, jointAddr);
View Full Code Here

TOP

Related Classes of com.badlogic.gdx.physics.box2d.joints.DistanceJoint

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.