Function createJoint

  • Create a joint between two bodies in the world

    Parameters

    • world: World

      The world in which to create the joint

    • bodyA: Shape | Body

      The first body to connect to the joint

    • bodyB: Shape | Body

      The second body to connect to the joint

    • rigidity: number = 1

      The amount the joint will compress

    • elasticity: number = 0

      The amount the joint will stretch

    • soft: boolean = false

    Returns void