Class ClientRegistryImpl

java.lang.Object
me.desht.pneumaticcraft.client.ClientRegistryImpl
All Implemented Interfaces:
IClientRegistry

public class ClientRegistryImpl extends Object implements IClientRegistry
  • Method Details

    • getInstance

      public static ClientRegistryImpl getInstance()
    • getAnimatedStat

      public IGuiAnimatedStat getAnimatedStat(net.minecraft.client.gui.screens.Screen gui, int backgroundColor)
      Description copied from interface: IClientRegistry
      Creates a GuiAnimatedStat without icon.
      Specified by:
      getAnimatedStat in interface IClientRegistry
      Parameters:
      gui - the owning GUI screen
      backgroundColor - background color for the stat in ARGB format
      Returns:
      a new stat widget
    • getAnimatedStat

      public IGuiAnimatedStat getAnimatedStat(net.minecraft.client.gui.screens.Screen gui, net.minecraft.world.item.ItemStack iconStack, int backgroundColor)
      Description copied from interface: IClientRegistry
      Creates a GuiAnimatedStat which uses an itemstack as static icon.
      Specified by:
      getAnimatedStat in interface IClientRegistry
      Parameters:
      gui - the owning GUI screen
      iconStack - an itemstack to use as the stat widget's icon
      backgroundColor - background color for the stat in ARGB format
      Returns:
      a new stat widget
    • getAnimatedStat

      public IGuiAnimatedStat getAnimatedStat(net.minecraft.client.gui.screens.Screen gui, net.minecraft.resources.ResourceLocation iconTexture, int backgroundColor)
      Description copied from interface: IClientRegistry
      Creates a GuiAnimatedStat which uses a texture location as static icon.
      Specified by:
      getAnimatedStat in interface IClientRegistry
      Parameters:
      gui - the owning GUI screen
      iconTexture - a texture to use as the stat widget's icon
      backgroundColor - background color for the stat in ARGB format
      Returns:
      a new stat widget
    • drawPressureGauge

      public void drawPressureGauge(net.minecraft.client.gui.GuiGraphics graphics, net.minecraft.client.gui.Font fontRenderer, float minPressure, float maxPressure, float dangerPressure, float minWorkingPressure, float currentPressure, int xPos, int yPos)
      Description copied from interface: IClientRegistry
      Draw a Pressure Gauge in GUI context, the same as in many PneumaticCraft machine GUI's.
      Specified by:
      drawPressureGauge in interface IClientRegistry
      Parameters:
      graphics - the GUI draw context
      fontRenderer - 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 (see PressureTier for standard pressure thresholds)
      dangerPressure - The transition pressure from green to red (see PressureTier for 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

      public void registerRenderOverride(@Nonnull net.minecraft.world.level.ItemLike entry, @Nonnull IAssemblyRenderOverriding renderOverride)
      Description copied from interface: IClientRegistry
      Register some custom item rendering behaviour for an item when held in an Assembly machine.
      Specified by:
      registerRenderOverride in interface IClientRegistry
      Parameters:
      entry - an item or block
      renderOverride - customized rendering behaviour for that item
    • getAssemblyRenderOverride

      public IAssemblyRenderOverriding getAssemblyRenderOverride(net.minecraft.world.level.ItemLike entry)
    • registerRenderOverride

      public void registerRenderOverride(@NotNull @NotNull net.minecraft.world.level.ItemLike entry, @NotNull @NotNull IChargingStationRenderOverride renderOverride)
      Description copied from interface: IClientRegistry
      Register some custom item rendering behaviour for an item when held in a Charging Station.
      Specified by:
      registerRenderOverride in interface IClientRegistry
      Parameters:
      entry - an item or block
      renderOverride - customized rendering behaviour for that item
    • getChargingRenderOverride

      @Nonnull public IChargingStationRenderOverride getChargingRenderOverride(net.minecraft.world.level.ItemLike item)