public abstract class BlockFluidBase extends Block implements IFluidBlock
Block.EnumOffsetType
IForgeRegistryEntry.Impl<T extends IForgeRegistryEntry<T>>
Modifier and Type | Field and Description |
---|---|
protected static java.util.Map<Block,java.lang.Boolean> |
defaultDisplacements |
protected Fluid |
definedFluid
This is the fluid used in the constructor.
|
protected int |
density |
protected int |
densityDir |
protected java.util.Map<Block,java.lang.Boolean> |
displacements |
static PropertyFloat |
FLOW_DIRECTION |
static com.google.common.collect.ImmutableList<IUnlistedProperty<java.lang.Float>> |
FLUID_RENDER_PROPS |
protected java.lang.String |
fluidName |
static PropertyInteger |
LEVEL |
static PropertyFloat[] |
LEVEL_CORNERS |
protected int |
maxScaledLight |
protected int |
quantaPerBlock |
protected float |
quantaPerBlockFloat |
protected BlockRenderLayer |
renderLayer |
protected int |
temperature |
protected int |
tickRate |
BLOCK_STATE_IDS, blockHardness, blockMapColor, blockMaterial, blockParticleGravity, blockResistance, blockSoundType, blockState, capturedDrops, captureDrops, enableStats, FULL_BLOCK_AABB, fullBlock, harvesters, isBlockContainer, lightOpacity, lightValue, needsRandomTick, NULL_AABB, RANDOM, REGISTRY, slipperiness, translucent, useNeighborBrightness
delegate
Constructor and Description |
---|
BlockFluidBase(Fluid fluid,
Material material) |
addCollisionBoxToList, addCollisionBoxToList, addDestroyEffects, addHitEffects, addInformation, addLandingEffects, beginLeavesDecay, breakBlock, canBeConnectedTo, canBeReplacedByLeaves, canConnectRedstone, canCreatureSpawn, canDropFromExplosion, canEntityDestroy, canEntitySpawn, canHarvestBlock, canPlaceBlockAt, canPlaceBlockOnSide, canPlaceTorchOnTop, canProvidePower, canRenderInLayer, canSilkHarvest, canSilkHarvest, canSpawnInBlock, canSustainLeaves, canSustainPlant, captureDrops, causesSuffocation, collisionRayTrace, createTileEntity, damageDropped, disableStats, doesSideBlockRendering, dropBlockAsItem, dropBlockAsItemWithChance, dropXpOnBlockBreak, eventReceived, fillWithRain, getActualState, getAiPathNodeType, getAmbientOcclusionLightValue, getBeaconColorMultiplier, getBedDirection, getBedSpawnPosition, getBlockById, getBlockFromItem, getBlockFromName, getBlockHardness, getBlockState, getBoundingBox, getComparatorInputOverride, getCreativeTabToDisplayOn, getDefaultState, getDrops, getEnableStats, getEnchantPowerBonus, getExpDrop, getExplosionResistance, getExplosionResistance, getFireSpreadSpeed, getFlammability, getHarvestLevel, getHarvestTool, getIdFromBlock, getItem, getLightOpacity, getLightOpacity, getLightValue, getLocalizedName, getMapColor, getMaterial, getMobilityFlag, getOffset, getOffsetType, getPickBlock, getPlayerRelativeBlockHardness, getRenderType, getSelectedBoundingBox, getSilkTouchDrop, getSoundType, getSoundType, getStateById, getStateForPlacement, getStateForPlacement, getStateId, getStrongPower, getSubBlocks, getTickRandomly, getUnlocalizedName, getUseNeighborBrightness, getValidRotations, getWeakChanges, getWeakPower, harvestBlock, hasComparatorInputOverride, hasCustomBreakingProgress, hasTileEntity, hasTileEntity, isAABBInsideMaterial, isAir, isAssociatedBlock, isBeaconBase, isBed, isBedFoot, isBlockNormalCube, isBlockSolid, isBurning, isCollidable, isEntityInsideMaterial, isEqualTo, isFertile, isFireSource, isFlammable, isFoliage, isFullBlock, isFullyOpaque, isLadder, isLeaves, isNormalCube, isNormalCube, isReplaceable, isReplaceableOreGen, isSideSolid, isToolEffective, isTranslucent, isWood, observedNeighborChange, onBlockActivated, onBlockClicked, onBlockDestroyedByExplosion, onBlockDestroyedByPlayer, onBlockExploded, onBlockHarvested, onBlockPlacedBy, onEntityCollidedWithBlock, onEntityWalk, onFallenUpon, onLanded, onNeighborChange, onPlantGrow, quantityDropped, quantityDroppedWithBonus, randomDisplayTick, randomTick, rayTrace, recolorBlock, registerBlocks, removedByPlayer, rotateBlock, setBedOccupied, setBlockUnbreakable, setCreativeTab, setDefaultState, setHardness, setHarvestLevel, setHarvestLevel, setLightLevel, setLightOpacity, setResistance, setSoundType, setTickRandomly, setUnlocalizedName, shouldCheckWeakPower, spawnAsEntity, toString, updateTick, withMirror, withRotation
getRegistryName, getRegistryType, setRegistryName, setRegistryName, setRegistryName
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
canDrain, drain, place
protected static final java.util.Map<Block,java.lang.Boolean> defaultDisplacements
protected java.util.Map<Block,java.lang.Boolean> displacements
public static final PropertyInteger LEVEL
public static final PropertyFloat[] LEVEL_CORNERS
public static final PropertyFloat FLOW_DIRECTION
public static final com.google.common.collect.ImmutableList<IUnlistedProperty<java.lang.Float>> FLUID_RENDER_PROPS
protected int quantaPerBlock
protected float quantaPerBlockFloat
protected int density
protected int densityDir
protected int temperature
protected int tickRate
protected BlockRenderLayer renderLayer
protected int maxScaledLight
protected final java.lang.String fluidName
protected final Fluid definedFluid
@Nonnull protected BlockStateContainer createBlockState()
createBlockState
in class Block
public int getMetaFromState(@Nonnull IBlockState state)
getMetaFromState
in class Block
@Deprecated @Nonnull public IBlockState getStateFromMeta(int meta)
getStateFromMeta
in class Block
public BlockFluidBase setQuantaPerBlock(int quantaPerBlock)
public BlockFluidBase setDensity(int density)
public BlockFluidBase setTemperature(int temperature)
public BlockFluidBase setTickRate(int tickRate)
public BlockFluidBase setRenderLayer(BlockRenderLayer renderLayer)
public BlockFluidBase setMaxScaledLight(int maxScaledLight)
public boolean canDisplace(IBlockAccess world, BlockPos pos)
public boolean displaceIfPossible(World world, BlockPos pos)
public abstract int getQuantaValue(IBlockAccess world, BlockPos pos)
public abstract boolean canCollideCheck(@Nonnull IBlockState state, boolean fullHit)
canCollideCheck
in class Block
public abstract int getMaxRenderHeightMeta()
public void onBlockAdded(@Nonnull World world, @Nonnull BlockPos pos, @Nonnull IBlockState state)
onBlockAdded
in class Block
public void neighborChanged(@Nonnull IBlockState state, @Nonnull World world, @Nonnull BlockPos pos, @Nonnull Block neighborBlock, @Nonnull BlockPos neighbourPos)
neighborChanged
in class Block
public boolean requiresUpdates()
requiresUpdates
in class Block
public boolean isPassable(@Nonnull IBlockAccess world, @Nonnull BlockPos pos)
isPassable
in class Block
@Nonnull public Item getItemDropped(@Nonnull IBlockState state, @Nonnull java.util.Random rand, int fortune)
getItemDropped
in class Block
public int quantityDropped(@Nonnull java.util.Random par1Random)
quantityDropped
in class Block
@Nonnull public Vec3d modifyAcceleration(@Nonnull World world, @Nonnull BlockPos pos, @Nonnull Entity entity, @Nonnull Vec3d vec)
modifyAcceleration
in class Block
public int getLightValue(@Nonnull IBlockState state, @Nonnull IBlockAccess world, @Nonnull BlockPos pos)
Block
getLightValue
in class Block
state
- Block stateworld
- The current worldpos
- Block position in worldpublic boolean isOpaqueCube(@Nonnull IBlockState state)
isOpaqueCube
in class Block
public boolean isFullCube(@Nonnull IBlockState state)
isFullCube
in class Block
public int getPackedLightmapCoords(@Nonnull IBlockState state, @Nonnull IBlockAccess world, @Nonnull BlockPos pos)
getPackedLightmapCoords
in class Block
@Nonnull public BlockRenderLayer getBlockLayer()
getBlockLayer
in class Block
public boolean shouldSideBeRendered(@Nonnull IBlockState state, @Nonnull IBlockAccess world, @Nonnull BlockPos pos, @Nonnull EnumFacing side)
shouldSideBeRendered
in class Block
@Nonnull public IBlockState getExtendedState(@Nonnull IBlockState oldState, @Nonnull IBlockAccess worldIn, @Nonnull BlockPos pos)
Block
getExtendedState
in class Block
public static final int getDensity(IBlockAccess world, BlockPos pos)
public static final int getTemperature(IBlockAccess world, BlockPos pos)
public static double getFlowDirection(IBlockAccess world, BlockPos pos)
public final int getQuantaValueBelow(IBlockAccess world, BlockPos pos, int belowThis)
public final int getQuantaValueAbove(IBlockAccess world, BlockPos pos, int aboveThis)
public final float getQuantaPercentage(IBlockAccess world, BlockPos pos)
public float getFluidHeightAverage(float... flow)
public float getFluidHeightForRender(IBlockAccess world, BlockPos pos)
public Vec3d getFlowVector(IBlockAccess world, BlockPos pos)
public Fluid getFluid()
IFluidBlock
getFluid
in interface IFluidBlock
public float getFilledPercentage(World world, BlockPos pos)
IFluidBlock
getFilledPercentage
in interface IFluidBlock
public AxisAlignedBB getCollisionBoundingBox(@Nonnull IBlockState blockState, @Nonnull IBlockAccess worldIn, @Nonnull BlockPos pos)
getCollisionBoundingBox
in class Block