Examples of DistanceJoint


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

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

   * @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

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);
    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

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

   * @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

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

   * @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

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

   * @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

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.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

Examples of dwlab.behavior_models.DistanceJoint

    hinge.visualizer = new Visualizer( "FF0000", 1.0, true );
    weight1.visualizer = new Visualizer( "00FF00", 1.0, true );
    weight2.visualizer = new Visualizer( "FFFF00", 1.0, true );
    rope1.visualizer = new ContourVisualizer( 0.25d, "0000FF", 2.0d, true );
    rope2.visualizer = rope1.visualizer;
    weight1.attachModel( new DistanceJoint( hinge ) );
    weight2.attachModel( new DistanceJoint( weight1 ) );
  }
View Full Code Here

Examples of eas.simulation.spatial.sim2D.physicalSimulation.physicsEngine.DistanceJoint

        envs[0] = env;
       
        env.addAgent(new Phys3Agent(0, env, "Agent0", 10, params), new Vector2D(0, -10), 180);
        env.addAgent(new Phys3JetAgent(1, env, "Agent1", 10, params), new Vector2D(-3, 0), 180);
        env.addAgent(new Phys3JetAgent(2, env, "Agent2", 10, params), new Vector2D(3, 0), 180);
        j1 = new DistanceJoint(
                env.getAgent(0),
                env.getAgent(1),
                new Vector2f(4, -5),
                new Vector2f(0, 0.9f),
                0);
        j2 = new DistanceJoint(
                env.getAgent(0),
                env.getAgent(2),
                new Vector2f(-4, -5),
                new Vector2f(0, 0.9f),
                0);
View Full Code Here

Examples of eas.simulation.spatial.sim2D.physicalSimulation.physicsEngine.DistanceJoint

            env.removeAgent(100);
            env.removeAgent(101);
            env.addAgent(new Phys3Agent(0, env, "Agent0", 10, params), new Vector2D(0, -10), 180);
            env.addAgent(new Phys3JetAgent(1, env, "Agent1", 10, params), new Vector2D(-3, 0), 180);
            env.addAgent(new Phys3JetAgent(2, env, "Agent2", 10, params), new Vector2D(3, 0), 180);
            j1 = new DistanceJoint(
                    env.getAgent(0),
                    env.getAgent(1),
                    new Vector2f(4, -5),
                    new Vector2f(0, 0.9f),
                    0);
            j2 = new DistanceJoint(
                    env.getAgent(0),
                    env.getAgent(2),
                    new Vector2f(-4, -5),
                    new Vector2f(0, 0.9f),
                    0);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.