Class ItemRenderer
java.lang.Object
net.minecraft.client.renderer.entity.ItemRenderer
- All Implemented Interfaces:
PreparableReloadListener
,ResourceManagerReloadListener
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.minecraft.server.packs.resources.PreparableReloadListener
PreparableReloadListener.PreparationBarrier
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final BlockEntityWithoutLevelRenderer
static final float
static final float
static final float
static final ResourceLocation
static final ResourceLocation
static final int
static final int
static final int
private final ItemColors
private final ItemModelShaper
private final Minecraft
static final ModelResourceLocation
private static final ModelResourceLocation
private final TextureManager
static final ModelResourceLocation
private static final ModelResourceLocation
-
Constructor Summary
ConstructorsConstructorDescriptionItemRenderer
(Minecraft minecraft, TextureManager textureManager, ModelManager modelManager, ItemColors itemColors, BlockEntityWithoutLevelRenderer blockEntityRenderer) -
Method Summary
Modifier and TypeMethodDescriptionstatic VertexConsumer
getArmorFoilBuffer
(MultiBufferSource bufferSource, RenderType renderType, boolean hasFoil) static VertexConsumer
getCompassFoilBuffer
(MultiBufferSource bufferSource, RenderType renderType, PoseStack.Pose pose) static VertexConsumer
getFoilBuffer
(MultiBufferSource bufferSource, RenderType renderType, boolean isItem, boolean glint) static VertexConsumer
getFoilBufferDirect
(MultiBufferSource bufferSource, RenderType renderType, boolean noEntity, boolean withGlint) getModel
(ItemStack stack, Level level, LivingEntity entity, int seed) private static boolean
hasAnimatedTexture
(ItemStack stack) void
onResourceManagerReload
(ResourceManager resourceManager) void
render
(ItemStack itemStack, ItemDisplayContext displayContext, boolean leftHand, PoseStack poseStack, MultiBufferSource bufferSource, int combinedLight, int combinedOverlay, BakedModel p_model) void
renderModelLists
(BakedModel model, ItemStack stack, int combinedLight, int combinedOverlay, PoseStack poseStack, VertexConsumer buffer) void
renderQuadList
(PoseStack poseStack, VertexConsumer buffer, List<BakedQuad> quads, ItemStack itemStack, int combinedLight, int combinedOverlay) void
renderStatic
(LivingEntity entity, ItemStack itemStack, ItemDisplayContext diplayContext, boolean leftHand, PoseStack poseStack, MultiBufferSource bufferSource, Level level, int combinedLight, int combinedOverlay, int seed) void
renderStatic
(ItemStack stack, ItemDisplayContext displayContext, int combinedLight, int combinedOverlay, PoseStack poseStack, MultiBufferSource bufferSource, Level level, int seed) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface net.minecraft.server.packs.resources.PreparableReloadListener
getName
Methods inherited from interface net.minecraft.server.packs.resources.ResourceManagerReloadListener
reload
-
Field Details
-
ENCHANTED_GLINT_ENTITY
-
ENCHANTED_GLINT_ITEM
-
IGNORED
-
GUI_SLOT_CENTER_X
public static final int GUI_SLOT_CENTER_X- See Also:
-
GUI_SLOT_CENTER_Y
public static final int GUI_SLOT_CENTER_Y- See Also:
-
ITEM_COUNT_BLIT_OFFSET
public static final int ITEM_COUNT_BLIT_OFFSET- See Also:
-
COMPASS_FOIL_UI_SCALE
public static final float COMPASS_FOIL_UI_SCALE- See Also:
-
COMPASS_FOIL_FIRST_PERSON_SCALE
public static final float COMPASS_FOIL_FIRST_PERSON_SCALE- See Also:
-
COMPASS_FOIL_TEXTURE_SCALE
public static final float COMPASS_FOIL_TEXTURE_SCALE- See Also:
-
TRIDENT_MODEL
-
TRIDENT_IN_HAND_MODEL
-
SPYGLASS_MODEL
-
SPYGLASS_IN_HAND_MODEL
-
minecraft
-
itemModelShaper
-
textureManager
-
itemColors
-
blockEntityRenderer
-
-
Constructor Details
-
ItemRenderer
public ItemRenderer(Minecraft minecraft, TextureManager textureManager, ModelManager modelManager, ItemColors itemColors, BlockEntityWithoutLevelRenderer blockEntityRenderer)
-
-
Method Details
-
getItemModelShaper
-
renderModelLists
public void renderModelLists(BakedModel model, ItemStack stack, int combinedLight, int combinedOverlay, PoseStack poseStack, VertexConsumer buffer) -
render
public void render(ItemStack itemStack, ItemDisplayContext displayContext, boolean leftHand, PoseStack poseStack, MultiBufferSource bufferSource, int combinedLight, int combinedOverlay, BakedModel p_model) -
hasAnimatedTexture
-
getArmorFoilBuffer
public static VertexConsumer getArmorFoilBuffer(MultiBufferSource bufferSource, RenderType renderType, boolean hasFoil) -
getCompassFoilBuffer
public static VertexConsumer getCompassFoilBuffer(MultiBufferSource bufferSource, RenderType renderType, PoseStack.Pose pose) -
getFoilBuffer
public static VertexConsumer getFoilBuffer(MultiBufferSource bufferSource, RenderType renderType, boolean isItem, boolean glint) -
getFoilBufferDirect
public static VertexConsumer getFoilBufferDirect(MultiBufferSource bufferSource, RenderType renderType, boolean noEntity, boolean withGlint) -
renderQuadList
public void renderQuadList(PoseStack poseStack, VertexConsumer buffer, List<BakedQuad> quads, ItemStack itemStack, int combinedLight, int combinedOverlay) -
getModel
public BakedModel getModel(ItemStack stack, @Nullable Level level, @Nullable LivingEntity entity, int seed) -
renderStatic
public void renderStatic(ItemStack stack, ItemDisplayContext displayContext, int combinedLight, int combinedOverlay, PoseStack poseStack, MultiBufferSource bufferSource, @Nullable Level level, int seed) -
renderStatic
public void renderStatic(@Nullable LivingEntity entity, ItemStack itemStack, ItemDisplayContext diplayContext, boolean leftHand, PoseStack poseStack, MultiBufferSource bufferSource, @Nullable Level level, int combinedLight, int combinedOverlay, int seed) -
onResourceManagerReload
- Specified by:
onResourceManagerReload
in interfaceResourceManagerReloadListener
-
getBlockEntityRenderer
-