Class ProgressBar

java.lang.Object
info.u_team.u_team_core.gui.elements.ProgressBar
All Implemented Interfaces:
net.minecraft.client.gui.components.events.GuiEventListener, net.minecraft.client.gui.components.Widget

public class ProgressBar extends Object implements net.minecraft.client.gui.components.events.GuiEventListener, net.minecraft.client.gui.components.Widget
  • Field Details

    • progress

      protected Supplier<Double> progress
    • click

      protected Consumer<Double> click
    • width

      protected int width
    • height

      protected int height
    • x

      protected int x
    • y

      protected int y
    • backgroundColor

      protected RGBA backgroundColor
    • progressColor

      protected RGBA progressColor
    • enabled

      protected boolean enabled
    • visible

      protected boolean visible
    • hovered

      protected boolean hovered
  • Constructor Details

  • Method Details

    • render

      public void render(com.mojang.blaze3d.vertex.PoseStack poseStack, int mouseX, int mouseY, float partialTicks)
      Specified by:
      render in interface net.minecraft.client.gui.components.Widget
    • onClick

      public void onClick(double mouseX, double mouseY)
    • mouseClicked

      public boolean mouseClicked(double mouseX, double mouseY, int button)
      Specified by:
      mouseClicked in interface net.minecraft.client.gui.components.events.GuiEventListener
    • isPressable

      protected boolean isPressable(double mouseX, double mouseY)
    • playPressSound

      public void playPressSound(net.minecraft.client.sounds.SoundManager soundHandler)
    • setProgressSupplier

      public void setProgressSupplier(Supplier<Double> progress)
    • getProgress

      public double getProgress()
    • getWidth

      public int getWidth()
    • setWidth

      public void setWidth(int width)
    • getHeight

      public int getHeight()
    • setHeight

      public void setHeight(int height)
    • getX

      public int getX()
    • setX

      public void setX(int x)
    • getY

      public int getY()
    • setY

      public void setY(int y)
    • isEnabled

      public boolean isEnabled()
    • setEnabled

      public void setEnabled(boolean enabled)
    • isVisible

      public boolean isVisible()
    • setVisible

      public void setVisible(boolean visible)
    • isHovered

      public boolean isHovered()
    • getBackgroundColor

      public RGBA getBackgroundColor()
    • setBackgroundColor

      public void setBackgroundColor(RGBA backGroundColor)
    • getProgressColor

      public RGBA getProgressColor()
    • setProgressColor

      public void setProgressColor(RGBA progressColor)
    • setClick

      public void setClick(Consumer<Double> click)