Code: Select all
CollisionShape boxShape = new BoxShape(new Vector3f(0.1f,1.5f,0.1f));
collisionShapes.add(boxShape);
tr.origin.set(0f, 1.5f-4.5f, 10);
box = localCreateRigidBody(10, tr, boxShape);
contraint = new Point2PointConstraint(box, new Vector3f(0,-1.5,0));
dynamicsWorld.addConstraint(contraint, false);