public class Fluid
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
protected Block |
block
If there is a Block implementation of the Fluid, the Block is linked here.
|
protected int |
density
Density of the fluid - completely arbitrary; negative density indicates that the fluid is
lighter than air.
|
protected IIcon |
flowingIcon |
protected java.lang.String |
fluidName
The unique identification name for this fluid.
|
protected boolean |
isGaseous
This indicates if the fluid is gaseous.
|
protected int |
luminosity
The light level emitted by this fluid.
|
protected EnumRarity |
rarity
The rarity of the fluid.
|
protected IIcon |
stillIcon
The Icons for this fluid.
|
protected int |
temperature
Temperature of the fluid - completely arbitrary; higher temperature indicates that the fluid is
hotter than air.
|
protected java.lang.String |
unlocalizedName
The unlocalized name of this fluid.
|
protected int |
viscosity
Viscosity ("thickness") of the fluid - completely arbitrary; negative values are not
permissible.
|
Constructor and Description |
---|
Fluid(java.lang.String fluidName) |
Modifier and Type | Method and Description |
---|---|
boolean |
canBePlacedInWorld() |
Block |
getBlock() |
int |
getColor() |
int |
getColor(FluidStack stack) |
int |
getColor(World world,
int x,
int y,
int z) |
int |
getDensity() |
int |
getDensity(FluidStack stack) |
int |
getDensity(World world,
int x,
int y,
int z) |
IIcon |
getFlowingIcon() |
IIcon |
getIcon() |
IIcon |
getIcon(FluidStack stack) |
IIcon |
getIcon(World world,
int x,
int y,
int z) |
int |
getID() |
java.lang.String |
getLocalizedName()
Returns the localized name of this fluid.
|
int |
getLuminosity() |
int |
getLuminosity(FluidStack stack) |
int |
getLuminosity(World world,
int x,
int y,
int z) |
java.lang.String |
getName() |
EnumRarity |
getRarity() |
EnumRarity |
getRarity(FluidStack stack) |
EnumRarity |
getRarity(World world,
int x,
int y,
int z) |
int |
getSpriteNumber()
Returns 0 for "/terrain.png".
|
IIcon |
getStillIcon() |
int |
getTemperature() |
int |
getTemperature(FluidStack stack) |
int |
getTemperature(World world,
int x,
int y,
int z) |
java.lang.String |
getUnlocalizedName()
Returns the unlocalized name of this fluid.
|
int |
getViscosity() |
int |
getViscosity(FluidStack stack) |
int |
getViscosity(World world,
int x,
int y,
int z) |
boolean |
isGaseous() |
boolean |
isGaseous(FluidStack stack) |
boolean |
isGaseous(World world,
int x,
int y,
int z) |
static void |
registerLegacyName(java.lang.String legacyName,
java.lang.String canonicalName)
Register a legacy liquid name with the Fluids system
|
Fluid |
setBlock(Block block) |
Fluid |
setDensity(int density) |
Fluid |
setFlowingIcon(IIcon flowingIcon) |
Fluid |
setGaseous(boolean isGaseous) |
Fluid |
setIcons(IIcon commonIcon) |
Fluid |
setIcons(IIcon stillIcon,
IIcon flowingIcon) |
Fluid |
setLuminosity(int luminosity) |
Fluid |
setRarity(EnumRarity rarity) |
Fluid |
setStillIcon(IIcon stillIcon) |
Fluid |
setTemperature(int temperature) |
Fluid |
setUnlocalizedName(java.lang.String unlocalizedName) |
Fluid |
setViscosity(int viscosity) |
protected final java.lang.String fluidName
protected java.lang.String unlocalizedName
protected IIcon stillIcon
protected IIcon flowingIcon
protected int luminosity
protected int density
protected int temperature
protected int viscosity
protected boolean isGaseous
protected EnumRarity rarity
protected Block block
public Fluid setUnlocalizedName(java.lang.String unlocalizedName)
public Fluid setLuminosity(int luminosity)
public Fluid setDensity(int density)
public Fluid setTemperature(int temperature)
public Fluid setViscosity(int viscosity)
public Fluid setGaseous(boolean isGaseous)
public Fluid setRarity(EnumRarity rarity)
public final java.lang.String getName()
public final int getID()
public final Block getBlock()
public final boolean canBePlacedInWorld()
public java.lang.String getLocalizedName()
public java.lang.String getUnlocalizedName()
public final int getSpriteNumber()
public final int getLuminosity()
public final int getDensity()
public final int getTemperature()
public final int getViscosity()
public final boolean isGaseous()
public EnumRarity getRarity()
public int getColor()
public IIcon getIcon()
public IIcon getStillIcon()
public IIcon getFlowingIcon()
public int getLuminosity(FluidStack stack)
public int getDensity(FluidStack stack)
public int getTemperature(FluidStack stack)
public int getViscosity(FluidStack stack)
public boolean isGaseous(FluidStack stack)
public EnumRarity getRarity(FluidStack stack)
public int getColor(FluidStack stack)
public IIcon getIcon(FluidStack stack)
public int getLuminosity(World world, int x, int y, int z)
public int getDensity(World world, int x, int y, int z)
public int getTemperature(World world, int x, int y, int z)
public int getViscosity(World world, int x, int y, int z)
public boolean isGaseous(World world, int x, int y, int z)
public EnumRarity getRarity(World world, int x, int y, int z)
public int getColor(World world, int x, int y, int z)
public static void registerLegacyName(java.lang.String legacyName, java.lang.String canonicalName)
legacyName
- The legacy name to recognizecanonicalName
- The canonical fluid name it will become