コード例 #1
0
ファイル: RaceTrack.java プロジェクト: juniorbl/jtoyracing
 private StaticPhysicsNode loadCheckpointModel(String modelPath) {
   StaticPhysicsNode checkPoint = physicsSpace.createStaticNode();
   checkPoint.setLocalTranslation(trackLocation);
   checkPoint.attachChild(ModelUtil.convertOBJToStatial(ResourcesPath.MODELS_PATH + modelPath));
   checkPoint.setLocalScale(1f);
   checkPoint.setMaterial(Material.GHOST);
   StateUtil.makeTransparent(checkPoint);
   return checkPoint;
 }
コード例 #2
0
ファイル: RaceTrack.java プロジェクト: juniorbl/jtoyracing
 private void createTrack(Vector3f trackLocation) {
   track = physicsSpace.createStaticNode();
   track.setLocalTranslation(trackLocation);
   track.setLocalScale(1f);
   track.attachChild(
       ModelUtil.convertOBJToStatial(ResourcesPath.MODELS_PATH + "obj/raceTrack.obj"));
   track.generatePhysicsGeometry(true);
   track.setMaterial(Material.IRON);
   this.attachChild(track);
 }