public class GuiButton extends Gui
Modifier and Type | Field and Description |
---|---|
protected static ResourceLocation |
BUTTON_TEXTURES |
java.lang.String |
displayString |
boolean |
enabled |
int |
height |
protected boolean |
hovered |
int |
id |
int |
packedFGColour |
boolean |
visible |
int |
width |
int |
xPosition |
int |
yPosition |
ICONS, OPTIONS_BACKGROUND, STAT_ICONS, zLevel
Constructor and Description |
---|
GuiButton(int buttonId,
int x,
int y,
int widthIn,
int heightIn,
java.lang.String buttonText) |
GuiButton(int buttonId,
int x,
int y,
java.lang.String buttonText) |
Modifier and Type | Method and Description |
---|---|
void |
drawButton(Minecraft mc,
int mouseX,
int mouseY) |
void |
drawButtonForegroundLayer(int mouseX,
int mouseY) |
int |
getButtonWidth() |
protected int |
getHoverState(boolean mouseOver) |
boolean |
isMouseOver() |
protected void |
mouseDragged(Minecraft mc,
int mouseX,
int mouseY) |
boolean |
mousePressed(Minecraft mc,
int mouseX,
int mouseY) |
void |
mouseReleased(int mouseX,
int mouseY) |
void |
playPressSound(SoundHandler soundHandlerIn) |
void |
setWidth(int width) |
drawCenteredString, drawGradientRect, drawHorizontalLine, drawModalRectWithCustomSizedTexture, drawRect, drawScaledCustomSizeModalRect, drawString, drawTexturedModalRect, drawTexturedModalRect, drawTexturedModalRect, drawVerticalLine
protected static final ResourceLocation BUTTON_TEXTURES
public int width
public int height
public int xPosition
public int yPosition
public java.lang.String displayString
public int id
public boolean enabled
public boolean visible
protected boolean hovered
public int packedFGColour
public GuiButton(int buttonId, int x, int y, java.lang.String buttonText)
public GuiButton(int buttonId, int x, int y, int widthIn, int heightIn, java.lang.String buttonText)
protected int getHoverState(boolean mouseOver)
public void drawButton(Minecraft mc, int mouseX, int mouseY)
protected void mouseDragged(Minecraft mc, int mouseX, int mouseY)
public void mouseReleased(int mouseX, int mouseY)
public boolean mousePressed(Minecraft mc, int mouseX, int mouseY)
public boolean isMouseOver()
public void drawButtonForegroundLayer(int mouseX, int mouseY)
public void playPressSound(SoundHandler soundHandlerIn)
public int getButtonWidth()
public void setWidth(int width)