Package com.jme3.collision

Examples of com.jme3.collision.CollisionResults.clear()


              Node n = res.getGeometry().getParent();
              String na = n.getName();
              log.fine("picked " + na + " id:"+ id);
              Vector3f loc = n.getLocalTranslation();
              sin.getClientFacade().sendAction(id, loc.x, loc.y, loc.z, false, true);
              results.clear();
              return;
            } else {//FIXME click on anything, check nav, then send request
              // this is the one
              Vector3f location = res.getContactPoint();
              if(location != null){
View Full Code Here


                        + " sent:"+ ServerValues.getServerCoordX(location.x)
                        + ","+ ServerValues.getServerCoordY(location.z)
                        + ","+ ServerValues.getServerCoordZ(location.y));
                    sin.getClientFacade().sendMoveToAction(handler.getSelectedObjectId(), pos.position.x, pos.position.y, pos.position.z, location.x, location.y,
                        location.z);
                    results.clear();
                    return;
                  } else {
                    log.fine("Unable to build path from "+pos.position+" to "+location);
                  }
                }
View Full Code Here

              return;
            }
          }

        }
        results.clear();
      } else
        log.info("picked nothing");
    }
  }
View Full Code Here

        try {
          if (results.size() > 0) {

            candidateGrassPatchLocation.set(ax, results
                .getCollision(0).getContactPoint().y, az);
            results.clear();

            if (isGrassLayer(candidateGrassPatchLocation, terrain,
                minIntensity, terrainWidth, channelId)) {
              // this will be in world coords, but we want it to
              // be in local
View Full Code Here

            float realHeight = pos.y;

            pos.addLocal(0, bbox.getYExtent(), 0);
            ray.setOrigin(pos);

            results.clear();
            terrainBlock.collideWith(ray, Matrix4f.IDENTITY, bbox, results);

            if (results.size() > 0){
                Vector3f contactPoint = results.getClosestCollision().getContactPoint();
                float delta = Math.abs(realHeight - contactPoint.y);
View Full Code Here

        }

        debugfrustums = false;
        if (flushQueues) {
            occluders.clear();
        }
        //restore setting for future rendering
        r.setFrameBuffer(viewPort.getOutputFrameBuffer());
        renderManager.setForcedMaterial(null);
        renderManager.setForcedTechnique(null);
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.