Class FluidRenderer
java.lang.Object
net.minecraft.client.renderer.block.FluidRenderer
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate voidaddFace(VertexConsumer builder, float x0, float y0, float z0, float u0, float v0, float x1, float y1, float z1, float u1, float v1, float x2, float y2, float z2, float u2, float v2, float x3, float y3, float z3, float u3, float v3, int color, int lightCoords, boolean addBackFace) private voidaddWeightedHeight(float[] weightedHeight, float height) private floatcalculateAverageHeight(BlockAndTintGetter level, Fluid type, float heightSelf, float height2, float height1, BlockPos cornerPos) private floatgetHeight(BlockAndTintGetter level, Fluid fluidType, BlockPos pos) private floatgetHeight(BlockAndTintGetter level, Fluid fluidType, BlockPos pos, BlockState state, FluidState fluidState) private intgetLightCoords(BlockAndTintGetter level, BlockPos pos) private static booleanisFaceOccludedByNeighbor(Direction direction, float height, BlockState neighborState) private static booleanisFaceOccludedBySelf(BlockState state, Direction direction) private static booleanisFaceOccludedByState(Direction direction, float height, BlockState state) private static booleanisNeighborSameFluid(FluidState fluidState, FluidState neighborFluidState) private static booleanisNeighborStateHidingOverlay(FluidState selfState, BlockState otherState, Direction neighborFace) static booleanshouldRenderFace(FluidState fluidState, BlockState selfState, Direction direction, BlockState otherState) static booleanshouldRenderFace(FluidState fluidState, BlockState blockState, Direction direction, FluidState neighborFluidState) Deprecated.voidtesselate(BlockAndTintGetter level, BlockPos pos, FluidRenderer.Output output, BlockState blockState, FluidState fluidState) private voidvertex(VertexConsumer builder, float x, float y, float z, int color, float u, float v, int lightCoords)
-
Field Details
-
MAX_FLUID_HEIGHT
private static final float MAX_FLUID_HEIGHT- See Also:
-
fluidModels
-
-
Constructor Details
-
FluidRenderer
-
-
Method Details
-
isNeighborSameFluid
-
isNeighborStateHidingOverlay
private static boolean isNeighborStateHidingOverlay(FluidState selfState, BlockState otherState, Direction neighborFace) -
isFaceOccludedByState
-
isFaceOccludedByNeighbor
private static boolean isFaceOccludedByNeighbor(Direction direction, float height, BlockState neighborState) -
isFaceOccludedBySelf
-
shouldRenderFace
@Deprecated public static boolean shouldRenderFace(FluidState fluidState, BlockState blockState, Direction direction, FluidState neighborFluidState) Deprecated.Neo: useshouldRenderFace(FluidState, BlockState, Direction, BlockState)instead -
shouldRenderFace
public static boolean shouldRenderFace(FluidState fluidState, BlockState selfState, Direction direction, BlockState otherState) -
tesselate
public void tesselate(BlockAndTintGetter level, BlockPos pos, FluidRenderer.Output output, BlockState blockState, FluidState fluidState) -
addFace
private void addFace(VertexConsumer builder, float x0, float y0, float z0, float u0, float v0, float x1, float y1, float z1, float u1, float v1, float x2, float y2, float z2, float u2, float v2, float x3, float y3, float z3, float u3, float v3, int color, int lightCoords, boolean addBackFace) -
calculateAverageHeight
private float calculateAverageHeight(BlockAndTintGetter level, Fluid type, float heightSelf, float height2, float height1, BlockPos cornerPos) -
addWeightedHeight
private void addWeightedHeight(float[] weightedHeight, float height) -
getHeight
-
getHeight
private float getHeight(BlockAndTintGetter level, Fluid fluidType, BlockPos pos, BlockState state, FluidState fluidState) -
vertex
private void vertex(VertexConsumer builder, float x, float y, float z, int color, float u, float v, int lightCoords) -
getLightCoords
-
shouldRenderFace(FluidState, BlockState, Direction, BlockState)instead