Package net.minecraftforge.fluids
Class ForgeFlowingFluid
- java.lang.Object
-
- net.minecraftforge.registries.ForgeRegistryEntry<Fluid>
-
- net.minecraft.fluid.Fluid
-
- net.minecraft.fluid.FlowingFluid
-
- net.minecraftforge.fluids.ForgeFlowingFluid
-
- All Implemented Interfaces:
IForgeFluid
,IForgeRegistryEntry<Fluid>
- Direct Known Subclasses:
ForgeFlowingFluid.Flowing
,ForgeFlowingFluid.Source
public abstract class ForgeFlowingFluid extends FlowingFluid
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ForgeFlowingFluid.Flowing
static class
ForgeFlowingFluid.Properties
static class
ForgeFlowingFluid.Source
-
Nested classes/interfaces inherited from class net.minecraftforge.registries.ForgeRegistryEntry
ForgeRegistryEntry.UncheckedRegistryEntry<V extends IForgeRegistryEntry<V>>
-
-
Field Summary
Fields Modifier and Type Field Description private java.util.function.Supplier<? extends FlowingFluidBlock>
block
private java.util.function.Supplier<? extends Item>
bucket
private FluidAttributes.Builder
builder
private boolean
canMultiply
private float
explosionResistance
private java.util.function.Supplier<? extends Fluid>
flowing
private int
levelDecreasePerBlock
private int
slopeFindDistance
private java.util.function.Supplier<? extends Fluid>
still
private int
tickRate
-
Fields inherited from class net.minecraft.fluid.FlowingFluid
FALLING, LEVEL
-
Fields inherited from class net.minecraft.fluid.Fluid
FLUID_STATE_REGISTRY, stateDefinition
-
Fields inherited from class net.minecraftforge.registries.ForgeRegistryEntry
delegate
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
ForgeFlowingFluid(ForgeFlowingFluid.Properties properties)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
beforeDestroyingBlock(IWorld worldIn, BlockPos pos, BlockState state)
protected boolean
canBeReplacedWith(FluidState state, IBlockReader world, BlockPos pos, Fluid fluidIn, Direction direction)
protected boolean
canConvertToSource()
protected FluidAttributes
createAttributes()
Creates the fluid attributes object, which will contain all the extended values for the fluid that aren't part of the vanilla system.protected BlockState
createLegacyBlock(FluidState state)
Item
getBucket()
protected int
getDropOff(IWorldReader worldIn)
protected float
getExplosionResistance()
Fluid
getFlowing()
protected int
getSlopeFindDistance(IWorldReader worldIn)
Fluid
getSource()
int
getTickDelay(IWorldReader world)
boolean
isSame(Fluid fluidIn)
-
Methods inherited from class net.minecraft.fluid.FlowingFluid
canSpreadTo, createFluidStateDefinition, getFlow, getFlowing, getHeight, getLegacyLevel, getNewLiquid, getOwnHeight, getShape, getSlopeDistance, getSource, getSpread, getSpreadDelay, isSolidFace, spread, spreadTo, tick
-
Methods inherited from class net.minecraft.fluid.Fluid
animateTick, defaultFluidState, getAmount, getAttributes, getDripParticle, getStateDefinition, getTags, is, isEmpty, isRandomlyTicking, isSource, randomTick, registerDefaultState
-
Methods inherited from class net.minecraftforge.registries.ForgeRegistryEntry
getRegistryName, getRegistryType, setRegistryName, setRegistryName, setRegistryName
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface net.minecraftforge.common.extensions.IForgeFluid
getExplosionResistance, getFluid, isAABBInsideLiquid, isAABBInsideMaterial, isEntityInside
-
-
-
-
Field Detail
-
flowing
private final java.util.function.Supplier<? extends Fluid> flowing
-
still
private final java.util.function.Supplier<? extends Fluid> still
-
bucket
@Nullable private final java.util.function.Supplier<? extends Item> bucket
-
block
@Nullable private final java.util.function.Supplier<? extends FlowingFluidBlock> block
-
builder
private final FluidAttributes.Builder builder
-
canMultiply
private final boolean canMultiply
-
slopeFindDistance
private final int slopeFindDistance
-
levelDecreasePerBlock
private final int levelDecreasePerBlock
-
explosionResistance
private final float explosionResistance
-
tickRate
private final int tickRate
-
-
Constructor Detail
-
ForgeFlowingFluid
protected ForgeFlowingFluid(ForgeFlowingFluid.Properties properties)
-
-
Method Detail
-
getFlowing
public Fluid getFlowing()
- Specified by:
getFlowing
in classFlowingFluid
-
getSource
public Fluid getSource()
- Specified by:
getSource
in classFlowingFluid
-
canConvertToSource
protected boolean canConvertToSource()
- Specified by:
canConvertToSource
in classFlowingFluid
-
beforeDestroyingBlock
protected void beforeDestroyingBlock(IWorld worldIn, BlockPos pos, BlockState state)
- Specified by:
beforeDestroyingBlock
in classFlowingFluid
-
getSlopeFindDistance
protected int getSlopeFindDistance(IWorldReader worldIn)
- Specified by:
getSlopeFindDistance
in classFlowingFluid
-
getDropOff
protected int getDropOff(IWorldReader worldIn)
- Specified by:
getDropOff
in classFlowingFluid
-
canBeReplacedWith
protected boolean canBeReplacedWith(FluidState state, IBlockReader world, BlockPos pos, Fluid fluidIn, Direction direction)
- Specified by:
canBeReplacedWith
in classFluid
-
getTickDelay
public int getTickDelay(IWorldReader world)
- Specified by:
getTickDelay
in classFluid
-
getExplosionResistance
protected float getExplosionResistance()
- Specified by:
getExplosionResistance
in classFluid
-
createLegacyBlock
protected BlockState createLegacyBlock(FluidState state)
- Specified by:
createLegacyBlock
in classFluid
-
createAttributes
protected FluidAttributes createAttributes()
Description copied from class:Fluid
Creates the fluid attributes object, which will contain all the extended values for the fluid that aren't part of the vanilla system. Do not call this from outside. To retrieve the values useFluid.getAttributes()
- Overrides:
createAttributes
in classFluid
-
-