Class SimpleDisplayStateRenderer
java.lang.Object
net.darkhax.botanypots.common.api.data.display.render.DisplayRenderer<SimpleDisplayState>
net.darkhax.botanypots.common.api.data.display.render.AbstractDisplayRenderer<SimpleDisplayState,RenderOptions>
net.darkhax.botanypots.common.impl.data.display.renderer.SimpleDisplayStateRenderer
public final class SimpleDisplayStateRenderer
extends AbstractDisplayRenderer<SimpleDisplayState,RenderOptions>
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetRenderOptions(SimpleDisplayState display) Gets the render options to apply from the display.voidrender(net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context context, SimpleDisplayState display, RenderOptions renderOptions, com.mojang.blaze3d.vertex.PoseStack pose, 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.static voidrenderBlockState(net.minecraft.world.level.block.state.BlockState blockState, net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context context, com.mojang.blaze3d.vertex.PoseStack pose, net.minecraft.world.level.Level level, net.minecraft.core.BlockPos pos, net.minecraft.client.renderer.MultiBufferSource bufferSource, Optional<TintColor> tintColor, int light, int overlay, Set<net.minecraft.core.Direction> faces) Methods inherited from class net.darkhax.botanypots.common.api.data.display.render.AbstractDisplayRenderer
getHeight, renderMethods inherited from class net.darkhax.botanypots.common.api.data.display.render.DisplayRenderer
bind, getRenderer, renderState
-
Field Details
-
RENDERER
-
-
Constructor Details
-
SimpleDisplayStateRenderer
public SimpleDisplayStateRenderer()
-
-
Method Details
-
getRenderOptions
Description copied from class:AbstractDisplayRendererGets the render options to apply from the display.- Specified by:
getRenderOptionsin classAbstractDisplayRenderer<SimpleDisplayState,RenderOptions> - Parameters:
display- The display to render.- Returns:
- The options to use when rendering.
-
render
public void render(net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context context, SimpleDisplayState display, RenderOptions renderOptions, com.mojang.blaze3d.vertex.PoseStack pose, 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:AbstractDisplayRendererRenders the display in the world.- Specified by:
renderin classAbstractDisplayRenderer<SimpleDisplayState,RenderOptions> - Parameters:
context- Context provided when rendering a block entity.display- The display to render.renderOptions- User defined rendering options used to configure the renderer.pose- 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.
-
renderBlockState
public static void renderBlockState(net.minecraft.world.level.block.state.BlockState blockState, net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context context, com.mojang.blaze3d.vertex.PoseStack pose, net.minecraft.world.level.Level level, net.minecraft.core.BlockPos pos, net.minecraft.client.renderer.MultiBufferSource bufferSource, Optional<TintColor> tintColor, int light, int overlay, Set<net.minecraft.core.Direction> faces)
-