Interface IClientRegistry
- All Known Implementing Classes:
ClientRegistryImpl
public interface IClientRegistry
-
Method Summary
Modifier and TypeMethodDescriptionvoiddrawPressureGauge(com.mojang.blaze3d.vertex.PoseStack matrixStack, net.minecraft.client.gui.Font fontRenderer, float minPressure, float maxPressure, float dangerPressure, float minWorkingPressure, float currentPressure, int xPos, int yPos) Draw a Pressure Gauge in GUI context, the same as in many PneumaticCraft machine GUI's.getAnimatedStat(net.minecraft.client.gui.screens.Screen gui, int backgroundColor) Creates a GuiAnimatedStat without icon.getAnimatedStat(net.minecraft.client.gui.screens.Screen gui, net.minecraft.resources.ResourceLocation iconTexture, int backgroundColor) Creates a GuiAnimatedStat which uses a texture location as static icon.getAnimatedStat(net.minecraft.client.gui.screens.Screen gui, net.minecraft.world.item.ItemStack iconStack, int backgroundColor) Creates a GuiAnimatedStat which uses an itemstack as static icon.voidregisterRenderOverride(net.minecraftforge.registries.IForgeRegistryEntry<?> entry, IAssemblyRenderOverriding renderOverride) Register some custom item rendering behaviour for an item when held in an Assembly machine.
-
Method Details
-
getAnimatedStat
Creates a GuiAnimatedStat without icon.- Parameters:
gui- the owning GUI screenbackgroundColor- background color for the stat in ARGB format- Returns:
- a new stat widget
-
getAnimatedStat
IGuiAnimatedStat getAnimatedStat(net.minecraft.client.gui.screens.Screen gui, net.minecraft.world.item.ItemStack iconStack, int backgroundColor) Creates a GuiAnimatedStat which uses an itemstack as static icon.- Parameters:
gui- the owning GUI screeniconStack- an itemstack to use as the stat widget's iconbackgroundColor- background color for the stat in ARGB format- Returns:
- a new stat widget
-
getAnimatedStat
IGuiAnimatedStat getAnimatedStat(net.minecraft.client.gui.screens.Screen gui, net.minecraft.resources.ResourceLocation iconTexture, int backgroundColor) Creates a GuiAnimatedStat which uses a texture location as static icon.- Parameters:
gui- the owning GUI screeniconTexture- a texture to use as the stat widget's iconbackgroundColor- background color for the stat in ARGB format- Returns:
- a new stat widget
-
drawPressureGauge
void drawPressureGauge(com.mojang.blaze3d.vertex.PoseStack matrixStack, net.minecraft.client.gui.Font fontRenderer, float minPressure, float maxPressure, float dangerPressure, float minWorkingPressure, float currentPressure, int xPos, int yPos) Draw a Pressure Gauge in GUI context, the same as in many PneumaticCraft machine GUI's.- Parameters:
matrixStack- the matrix stackfontRenderer- fontrenderer used to draw the numbers of the pressure gauge.minPressure- The minimal pressure that needs to be displayed (this is -1 in most applications).maxPressure- The maximal pressure that needs to be rendered (seePressureTierfor standard pressure thresholds)dangerPressure- The transition pressure from green to red (seePressureTierfor standard pressure thresholds)minWorkingPressure- The transition pressure from yellow to green (varies per machine).currentPressure- The pressure that the needle should point to.xPos- x position of the gauge.yPos- y position of the gauge.
-
registerRenderOverride
void registerRenderOverride(@Nonnull net.minecraftforge.registries.IForgeRegistryEntry<?> entry, @Nonnull IAssemblyRenderOverriding renderOverride) Register some custom item rendering behaviour for an item when held in an Assembly machine.- Parameters:
entry- a Forge registry entry, which should be an itemrenderOverride- customized rendering behaviour for that item
-