Class PhasedDisplayStateRenderer<T extends PhasedDisplayState>
java.lang.Object
net.darkhax.botanypots.common.api.data.display.render.DisplayRenderer<T>
net.darkhax.botanypots.common.impl.data.display.renderer.PhasedDisplayStateRenderer<T>
public final class PhasedDisplayStateRenderer<T extends PhasedDisplayState>
extends DisplayRenderer<T>
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final PhasedDisplayStateRenderer<AgingDisplayState> static final PhasedDisplayStateRenderer<TransitionalDisplayState> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfloatrender(net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context renderContext, T displayState, com.mojang.blaze3d.vertex.PoseStack stack, net.minecraft.world.level.Level level, net.minecraft.core.BlockPos pos, float tickDelta, net.minecraft.client.renderer.MultiBufferSource bufferSource, int light, int overlay, BotanyPotBlockEntity pot, float progress, float growthScale, float heightOffset) Renders the display in the world.Methods inherited from class net.darkhax.botanypots.common.api.data.display.render.DisplayRenderer
bind, getRenderer, renderState
-
Field Details
-
AGING
-
TRANSITIONAL
-
-
Constructor Details
-
PhasedDisplayStateRenderer
public PhasedDisplayStateRenderer()
-
-
Method Details
-
render
public float render(net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context renderContext, T displayState, com.mojang.blaze3d.vertex.PoseStack stack, net.minecraft.world.level.Level level, net.minecraft.core.BlockPos pos, float tickDelta, net.minecraft.client.renderer.MultiBufferSource bufferSource, int light, int overlay, BotanyPotBlockEntity pot, float progress, float growthScale, float heightOffset) Description copied from class:DisplayRendererRenders the display in the world.- Specified by:
renderin classDisplayRenderer<T extends PhasedDisplayState>- Parameters:
renderContext- Context provided when rendering a block entity.displayState- The display to render.stack- The pose stack for the renderer.level- The current level, will always be a client level.pos- The position of te block being rendered.tickDelta- The delta between frames.bufferSource- Buffer source for rendering.light- Packed light of the block.overlay- Packed overlay of the block.pot- The pot block entity.progress- The growth progress of the crop.growthScale- The scale based on current growth progress.heightOffset- A height offset used to make displays stack perfectly on top of each other.- Returns:
- The new height offset for the next display.
-