/** * creates a SphereCollisionShape with the given radius * @param radius */ public SphereCollisionShape(float radius) { this.radius = radius; createShape(); }
/** * Instantiate a sphere shape with the specified radius. * * @param radius the desired radius (≥0) */ public SphereCollisionShape(float radius) { this.radius = radius; createShape(); }
/** * Instantiate the configured shape in Bullet. */ protected void createShape() { objectId = createShape(radius); Logger.getLogger(this.getClass().getName()).log(Level.FINE, "Created Shape {0}", Long.toHexString(objectId)); // new SphereShape(radius); // objectId.setLocalScaling(Converter.convert(getScale())); // objectId.setMargin(margin); setScale(scale); // Set the scale to 1 setMargin(margin); }
/** * De-serialize this shape, for example when loading from a J3O file. * * @param im importer (not null) * @throws IOException from importer */ public void read(JmeImporter im) throws IOException { super.read(im); InputCapsule capsule = im.getCapsule(this); radius = capsule.readFloat("radius", 0.5f); createShape(); }
public void read(JmeImporter im) throws IOException { super.read(im); InputCapsule capsule = im.getCapsule(this); radius = capsule.readFloat("radius", 0.5f); createShape(); }
/** * creates a SphereCollisionShape with the given radius * @param radius */ public SphereCollisionShape(float radius) { this.radius = radius; createShape(); }
/** * creates a SphereCollisionShape with the given radius * @param radius */ public SphereCollisionShape(float radius) { this.radius = radius; createShape(); }
/** * creates a SphereCollisionShape with the given radius * @param radius */ public SphereCollisionShape(float radius) { this.radius = radius; createShape(); }
protected void createShape() { objectId = createShape(radius); Logger.getLogger(this.getClass().getName()).log(Level.INFO, "Created Shape {0}", Long.toHexString(objectId)); // new SphereShape(radius); // objectId.setLocalScaling(Converter.convert(getScale())); // objectId.setMargin(margin); setScale(scale); setMargin(margin); }
protected void createShape() { objectId = createShape(radius); Logger.getLogger(this.getClass().getName()).log(Level.FINE, "Created Shape {0}", Long.toHexString(objectId)); // new SphereShape(radius); // objectId.setLocalScaling(Converter.convert(getScale())); // objectId.setMargin(margin); setScale(scale); // Set the scale to 1 setMargin(margin); }
public void read(JmeImporter im) throws IOException { super.read(im); InputCapsule capsule = im.getCapsule(this); radius = capsule.readFloat("radius", 0.5f); createShape(); }
public void read(JmeImporter im) throws IOException { super.read(im); InputCapsule capsule = im.getCapsule(this); radius = capsule.readFloat("radius", 0.5f); createShape(); }
public void read(JmeImporter im) throws IOException { super.read(im); InputCapsule capsule = im.getCapsule(this); radius = capsule.readFloat("radius", 0.5f); createShape(); }