Class EmptyShape

All Implemented Interfaces:
com.jme3.export.Savable, com.jme3.util.clone.JmeCloneable, Cloneable, Comparable<NativePhysicsObject>

public class EmptyShape extends CollisionShape
An empty collision shape based on Bullet's btEmptyShape.
  • Field Details

    • logger2

      public static final Logger logger2
      message logger for this class
  • Constructor Details

    • EmptyShape

      protected EmptyShape()
      No-argument constructor needed by SavableClassUtil.
    • EmptyShape

      public EmptyShape(boolean unused)
      Instantiate an empty shape.
      Parameters:
      unused - to distinguish this from the no-argument constructor
  • Method Details

    • unscaledVolume

      public float unscaledVolume()
      Return the volume of the shape.
      Returns:
      0
    • canSplit

      public boolean canSplit()
      Test whether the shape can be split by an arbitrary plane.
      Overrides:
      canSplit in class CollisionShape
      Returns:
      true
    • cloneFields

      public void cloneFields(com.jme3.util.clone.Cloner cloner, Object original)
      Callback from Cloner to convert this shallow-cloned shape into a deep-cloned one, using the specified Cloner and original to resolve copied fields.
      Specified by:
      cloneFields in interface com.jme3.util.clone.JmeCloneable
      Overrides:
      cloneFields in class CollisionShape
      Parameters:
      cloner - the Cloner that's cloning this shape (not null)
      original - the instance from which this shape was shallow-cloned (not null, unaffected)
    • maxRadius

      public float maxRadius()
      Calculate how far the shape extends from its center.
      Overrides:
      maxRadius in class CollisionShape
      Returns:
      0
    • read

      public void read(com.jme3.export.JmeImporter importer) throws IOException
      De-serialize the shape from the specified importer, for example when loading from a J3O file.
      Specified by:
      read in interface com.jme3.export.Savable
      Overrides:
      read in class CollisionShape
      Parameters:
      importer - (not null)
      Throws:
      IOException - from the importer
    • scaledVolume

      public float scaledVolume()
      Return the volume of the shape, including scale and margin.
      Overrides:
      scaledVolume in class CollisionShape
      Returns:
      0