public final class MixedMaterial extends java.lang.Object implements java.io.Serializable, java.lang.Comparable<MixedMaterial>, java.lang.Cloneable
| Modifier and Type | Class and Description | 
|---|---|
| static class  | MixedMaterial.Mode | 
| static class  | MixedMaterial.Row | 
| Constructor and Description | 
|---|
| MixedMaterial(java.lang.String name,
             MixedMaterial.Row[] rows,
             int biome,
             java.lang.Integer colour)Create a new noisy mixed material. | 
| MixedMaterial(java.lang.String name,
             MixedMaterial.Row[] rows,
             int biome,
             java.lang.Integer colour,
             float scale)Create a new blobby mixed material. | 
| MixedMaterial(java.lang.String name,
             MixedMaterial.Row[] rows,
             int biome,
             java.lang.Integer colour,
             NoiseSettings variation,
             double layerXSlope,
             double layerYSlope,
             boolean repeat)Create a new layered mixed material. | 
| MixedMaterial(java.lang.String name,
             MixedMaterial.Row row,
             int biome,
             java.lang.Integer colour)Create a new "mixed material" which contains only one material. | 
| Modifier and Type | Method and Description | 
|---|---|
| MixedMaterial | clone() | 
| int | compareTo(MixedMaterial o) | 
| static MixedMaterial | create(Platform platform,
      int blockType)Deprecated. 
 | 
| static MixedMaterial | create(Platform platform,
      Material material)Utility method for creating a simple mixed material, consisting of one
 material, with a default name targeted to a specific platform. | 
| static MixedMaterial | create(java.lang.String name,
      Material material)Utility method for creating a simple mixed material, consisting of one
 material, with a specific name. | 
| static <V> V | duplicateNewMaterialsWhile(java.util.concurrent.Callable<V> task)Perform a task during which any new materials deserialised on the
 same thread will be duplicated and given new identities, instead of
 being replaced with existing instances with the same identity if
 available. | 
| boolean | equals(java.lang.Object obj) | 
| int | getBiome() | 
| java.lang.Integer | getColour() | 
| java.awt.image.BufferedImage | getIcon(ColourScheme colourScheme) | 
| java.util.UUID | getId() | 
| double | getLayerXSlope() | 
| double | getLayerYSlope() | 
| Material | getMaterial(long seed,
           int x,
           int y,
           float z) | 
| Material | getMaterial(long seed,
           int x,
           int y,
           int z) | 
| MixedMaterial.Mode | getMode() | 
| java.lang.String | getName() | 
| int | getPatternHeight()Get the height of the pattern, or -1 if this does not apply because there
 is no pattern. | 
| MixedMaterial.Row[] | getRows() | 
| float | getScale() | 
| Material | getSingleMaterial()Get the single material of which this mixed material consists, or
  nullif it contains more than one material. | 
| NoiseSettings | getVariation() | 
| int | hashCode() | 
| boolean | isRepeat() | 
| java.lang.String | toString() | 
public MixedMaterial(java.lang.String name,
                     MixedMaterial.Row row,
                     int biome,
                     java.lang.Integer colour)
name - The name of the mixed material.row - A single row describing the material.biome - The default biome associated with this mixed material, or -1
     for no default biome.colour - The colour associated with this mixed material, or
     null for no default colour.public MixedMaterial(java.lang.String name,
                     MixedMaterial.Row[] rows,
                     int biome,
                     java.lang.Integer colour)
name - The name of the mixed material.rows - The rows describing the materials to be used together with
     their occurrences.biome - The default biome associated with this mixed material, or -1
     for no default biome.colour - The colour associated with this mixed material, or
     null for no default colour.public MixedMaterial(java.lang.String name,
                     MixedMaterial.Row[] rows,
                     int biome,
                     java.lang.Integer colour,
                     float scale)
name - The name of the mixed material.rows - The rows describing the materials to be used together with
     their occurrences.biome - The default biome associated with this mixed material, or -1
     for no default biome.colour - The colour associated with this mixed material, or
     null for no default colour.scale - The scale of the blobs. 1.0f for default size.public MixedMaterial(java.lang.String name,
                     MixedMaterial.Row[] rows,
                     int biome,
                     java.lang.Integer colour,
                     NoiseSettings variation,
                     double layerXSlope,
                     double layerYSlope,
                     boolean repeat)
name - The name of the mixed material.rows - The rows describing the materials to be used together with
     their heights.biome - The default biome associated with this mixed material, or -1
     for no default biome.colour - The colour associated with this mixed material, or
     null for no default colour.variation - The variation in layer height which should be applied,
     or null for no variation.layerXSlope - The slope of the layer for the x-axis.
     Must be zero if repeat is false.layerYSlope - The slope of the layer for the y-axis.
     Must be zero if repeat is false.repeat - Whether the layers should repeat vertically.public java.util.UUID getId()
public java.lang.String getName()
public int getBiome()
public MixedMaterial.Mode getMode()
public float getScale()
public java.lang.Integer getColour()
public NoiseSettings getVariation()
public boolean isRepeat()
public double getLayerXSlope()
public double getLayerYSlope()
public java.awt.image.BufferedImage getIcon(ColourScheme colourScheme)
public Material getMaterial(long seed, int x, int y, float z)
public Material getMaterial(long seed, int x, int y, int z)
public Material getSingleMaterial()
null if it contains more than one material.null if it contains more than one material.public MixedMaterial.Row[] getRows()
public int getPatternHeight()
public int compareTo(MixedMaterial o)
compareTo in interface java.lang.Comparable<MixedMaterial>public java.lang.String toString()
toString in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic boolean equals(java.lang.Object obj)
equals in class java.lang.Objectpublic MixedMaterial clone()
clone in class java.lang.Objectpublic static MixedMaterial create(Platform platform, int blockType)
create(Platform, Material)platform - The platform to which to target the name.blockType - The block type the mixed material should consist ofpublic static MixedMaterial create(Platform platform, Material material)
platform - The platform to which to target the name.material - The simple material the mixed material should consist ofpublic static MixedMaterial create(java.lang.String name, Material material)
name - The name to give the mixed material.material - The simple material the mixed material should consist ofpublic static <V> V duplicateNewMaterialsWhile(java.util.concurrent.Callable<V> task)
V - The return type of the task. May be Void for tasks
           which do not return a value.task - The task to perform.null if it does not
     return a value.java.lang.RuntimeException - If the task throws a checked exception it will
 be wrapped in a RuntimeException.