use of net.minecraft.client.gui.GuiButton in project LogisticsPipes by RS485.
the class GuiFluidSupplierPipe method initGui.
@SuppressWarnings("unchecked")
@Override
public void initGui() {
super.initGui();
buttonList.clear();
buttonList.add(new GuiButton(0, width / 2 + 45, height / 2 - 25, 30, 20, logic.isRequestingPartials() ? StringUtils.translate(GuiFluidSupplierPipe.PREFIX + "Yes") : StringUtils.translate(GuiFluidSupplierPipe.PREFIX + "No")));
}
use of net.minecraft.client.gui.GuiButton in project LogisticsPipes by RS485.
the class GuiLogisticsCraftingTable method drawGuiContainerBackgroundLayer.
@Override
protected void drawGuiContainerBackgroundLayer(float fA, int iA, int jA) {
for (GuiButton sycleButton : sycleButtons) {
sycleButton.visible = _crafter.targetType != null;
}
GuiGraphics.drawGuiBackGround(mc, guiLeft, guiTop, right, bottom, zLevel, true);
GuiGraphics.drawGuiBackGround(mc, guiLeft, guiTop, right, bottom, zLevel, true);
for (int x = 0; x < 3; x++) {
for (int y = 0; y < 3; y++) {
GuiGraphics.drawSlotBackground(mc, guiLeft + 34 + x * 18, guiTop + 9 + y * 18);
}
}
GuiGraphics.drawSlotBackground(mc, guiLeft + 124, guiTop + 27);
for (int x = 0; x < 9; x++) {
for (int y = 0; y < 2; y++) {
GuiGraphics.drawSlotBackground(mc, guiLeft + 7 + x * 18, guiTop + 79 + y * 18);
}
}
GuiGraphics.drawPlayerInventoryBackground(mc, guiLeft + 8, guiTop + 135);
ItemIdentifierStack[] items = new ItemIdentifierStack[9];
for (int i = 0; i < 9; i++) {
if (_crafter.matrix.getIDStackInSlot(i) != null) {
items[i] = _crafter.matrix.getIDStackInSlot(i);
}
}
ItemStackRenderer.renderItemIdentifierStackListIntoGui(Arrays.asList(items), null, 0, guiLeft + 8, guiTop + 79, 9, 9, 18, 18, 0.0F, DisplayAmount.NEVER);
GL11.glTranslatef(0F, 0F, 20F);
for (int a = 0; a < 9; a++) {
Gui.drawRect(guiLeft + 8 + (a * 18), guiTop + 80, guiLeft + 24 + (a * 18), guiTop + 96, 0xc08b8b8b);
}
GL11.glTranslatef(0F, 0F, -20F);
}
use of net.minecraft.client.gui.GuiButton in project LogisticsPipes by RS485.
the class GuiExtractor method initGui.
@SuppressWarnings("unchecked")
@Override
public void initGui() {
super.initGui();
int left = width / 2 - xSize / 2;
int top = height / 2 - ySize / 2;
//DOWN
buttonList.add(new GuiButton(0, left + 110, top + 103, 40, 20, ""));
//UP
buttonList.add(new GuiButton(1, left + 110, top + 43, 40, 20, ""));
//NORTH
buttonList.add(new GuiButton(2, left + 50, top + 53, 50, 20, ""));
//SOUTH
buttonList.add(new GuiButton(3, left + 50, top + 93, 50, 20, ""));
//WEST
buttonList.add(new GuiButton(4, left + 10, top + 73, 40, 20, ""));
//EAST
buttonList.add(new GuiButton(5, left + 100, top + 73, 40, 20, ""));
//DEFAULT
buttonList.add(new GuiButton(6, left + 10, top + 23, 60, 20, ""));
refreshButtons();
}
use of net.minecraft.client.gui.GuiButton in project LogisticsPipes by RS485.
the class GuiExtractor method refreshButtons.
private void refreshButtons() {
for (Object p : buttonList) {
GuiButton button = (GuiButton) p;
button.displayString = isExtract(ForgeDirection.getOrientation(button.id));
}
}
use of net.minecraft.client.gui.GuiButton in project LogisticsPipes by RS485.
the class SneakyConfigurationPopup method initGui.
@Override
public void initGui() {
super.initGui();
buttonList.clear();
configDisplay = new SideConfigDisplay(config) {
@Override
public void handleSelection(SelectedFace selection) {
SneakyConfigurationPopup.this.handleSelection(selection);
}
};
configDisplay.init();
configDisplay.renderNeighbours = true;
buttonList.add(new GuiButton(0, right - 106, bottom - 26, 100, 20, "Cancel"));
bounds = new Rectangle(guiLeft + 5, guiTop + 20, this.xSize - 10, this.ySize - 50);
}
Aggregations