use of pneumaticCraft.client.gui.widget.GuiAnimatedStat in project PneumaticCraft by MineMaarten.
the class GuiAerialInterface method initGui.
@Override
public void initGui() {
super.initGui();
if (PneumaticCraftAPIHandler.getInstance().liquidXPs.size() > 0)
addAnimatedStat("gui.tab.info.aerialInterface.liquidXp.info.title", new ItemStack(Items.water_bucket), 0xFF55FF55, false).setText(getLiquidXPText());
if (Loader.isModLoaded(ModIds.COFH_CORE)) {
addAnimatedStat("gui.tab.info.aerialInterface.interfacingRF.info.title", new ItemStack(Items.glowstone_dust), 0xFFFF2222, false).setText("gui.tab.info.aerialInterface.interfacingRF.info");
}
if (te.getUpgrades(ItemMachineUpgrade.UPGRADE_DISPENSER_DAMAGE) > 0) {
GuiAnimatedStat optionStat = addAnimatedStat("gui.tab.aerialInterface.feedMode", new ItemStack(Items.beef), 0xFFFFCC00, false);
List<String> text = new ArrayList<String>();
for (int i = 0; i < 4; i++) text.add(" ");
optionStat.setTextWithoutCuttingString(text);
GuiButtonSpecial button = new GuiButtonSpecial(1, 5, 20, 20, 20, "");
button.setRenderStacks(new ItemStack(Items.beef));
button.setTooltipText(I18n.format("gui.tab.aerialInterface.feedMode.feedFullyUtilize"));
optionStat.addWidget(button);
modeButtons[0] = button;
button = new GuiButtonSpecial(2, 30, 20, 20, 20, "");
button.setRenderStacks(new ItemStack(Items.apple));
button.setTooltipText(I18n.format("gui.tab.aerialInterface.feedMode.feedWhenPossible"));
optionStat.addWidget(button);
modeButtons[1] = button;
button = new GuiButtonSpecial(3, 55, 20, 20, 20, "");
button.setRenderStacks(new ItemStack(Items.golden_apple));
button.setTooltipText(Arrays.asList(WordUtils.wrap(I18n.format("gui.tab.aerialInterface.feedMode.utilizeFullHealthElsePossible"), 40).split(System.getProperty("line.separator"))));
optionStat.addWidget(button);
modeButtons[2] = button;
} else {
for (int i = 0; i < modeButtons.length; i++) modeButtons[i] = null;
}
}
use of pneumaticCraft.client.gui.widget.GuiAnimatedStat in project PneumaticCraft by MineMaarten.
the class GuiGasLift method initGui.
@Override
public void initGui() {
super.initGui();
addWidget(new WidgetTank(-1, guiLeft + 80, guiTop + 15, te.getTank()));
statusStat = addAnimatedStat("gui.tab.status", new ItemStack(Blockss.gasLift), 0xFFFFAA00, false);
GuiAnimatedStat optionStat = addAnimatedStat("gui.tab.gasLift.mode", new ItemStack(Blockss.pressureTube), 0xFFFFCC00, false);
List<String> text = new ArrayList<String>();
for (int i = 0; i < 4; i++) text.add(" ");
optionStat.setTextWithoutCuttingString(text);
GuiButtonSpecial button = new GuiButtonSpecial(1, 5, 20, 20, 20, "");
button.setRenderStacks(new ItemStack(Items.bucket));
button.setTooltipText(I18n.format("gui.tab.gasLift.mode.pumpEmpty"));
optionStat.addWidget(button);
modeButtons[0] = button;
button = new GuiButtonSpecial(2, 30, 20, 20, 20, "");
button.setRenderStacks(new ItemStack(Items.water_bucket));
button.setTooltipText(I18n.format("gui.tab.gasLift.mode.pumpLeave"));
optionStat.addWidget(button);
modeButtons[1] = button;
button = new GuiButtonSpecial(3, 55, 20, 20, 20, "");
button.setRenderStacks(new ItemStack(Blockss.pressureTube));
button.setTooltipText(I18n.format("gui.tab.gasLift.mode.drawIn"));
optionStat.addWidget(button);
modeButtons[2] = button;
}
use of pneumaticCraft.client.gui.widget.GuiAnimatedStat in project PneumaticCraft by MineMaarten.
the class GuiOmnidirectionalHopper method initGui.
@Override
public void initGui() {
super.initGui();
statusStat = addAnimatedStat("gui.tab.hopperStatus", new ItemStack(Blockss.omnidirectionalHopper), 0xFFFFAA00, false);
GuiAnimatedStat optionStat = addAnimatedStat("gui.tab.gasLift.mode", new ItemStack(net.minecraft.init.Blocks.lever), 0xFFFFCC00, false);
List<String> text = new ArrayList<String>();
for (int i = 0; i < 4; i++) text.add(" ");
optionStat.setTextWithoutCuttingString(text);
GuiButtonSpecial button = new GuiButtonSpecial(1, 5, 20, 20, 20, "");
button.setRenderStacks(new ItemStack(Items.bucket));
button.setTooltipText(I18n.format("gui.tab.omnidirectionalHopper.mode.empty"));
optionStat.addWidget(button);
modeButtons[0] = button;
button = new GuiButtonSpecial(2, 30, 20, 20, 20, "");
button.setRenderStacks(new ItemStack(Items.water_bucket));
button.setTooltipText(I18n.format("gui.tab.omnidirectionalHopper.mode.leaveItem"));
optionStat.addWidget(button);
modeButtons[1] = button;
}
use of pneumaticCraft.client.gui.widget.GuiAnimatedStat in project PneumaticCraft by MineMaarten.
the class GuiPlasticMixer method initGui.
@Override
public void initGui() {
super.initGui();
addWidget(new WidgetTemperature(0, guiLeft + 55, guiTop + 25, 295, 500, te.getLogic(0)));
addWidget(new WidgetTemperature(1, guiLeft + 82, guiTop + 25, 295, 500, te.getLogic(1), PneumaticValues.PLASTIC_MIXER_MELTING_TEMP));
addWidget(new WidgetTank(3, guiLeft + 152, guiTop + 14, te.getFluidTank()));
GuiAnimatedStat stat = addAnimatedStat("gui.tab.plasticMixer.plasticSelection", new ItemStack(Itemss.plastic, 1, 1), 0xFF005500, false);
List<String> text = new ArrayList<String>();
for (int i = 0; i < 12; i++) {
text.add(" ");
}
stat.setTextWithoutCuttingString(text);
buttons = new GuiButtonSpecial[16];
for (int x = 0; x < 4; x++) {
for (int y = 0; y < 4; y++) {
int index = y * 4 + x;
ItemStack plastic = new ItemStack(Itemss.plastic, 1, index);
buttons[index] = new GuiButtonSpecial(index + 1, x * 21 + 4, y * 21 + 30, 20, 20, "").setRenderStacks(plastic).setTooltipText(plastic.getDisplayName());
stat.addWidget(buttons[index]);
}
}
stat.addWidget(lockSelection = new GuiCheckBox(17, 4, 18, 0xFF000000, "gui.plasticMixer.lockSelection").setChecked(te.lockSelection).setTooltip(I18n.format("gui.plasticMixer.lockSelection.tooltip")));
}
use of pneumaticCraft.client.gui.widget.GuiAnimatedStat in project PneumaticCraft by MineMaarten.
the class GuiLogisticsRequester method initGui.
@Override
public void initGui() {
super.initGui();
addAnimatedStat("gui.tab.info.ghostSlotInteraction.title", new ItemStack(Blocks.hopper), 0xFF00AAFF, true).setText("gui.tab.info.ghostSlotInteraction");
if (Loader.isModLoaded(ModIds.AE2)) {
if (logistics.isPlacedOnInterface()) {
Item item = GameRegistry.findItem(ModIds.AE2, "item.ItemMultiPart");
if (item == null) {
Log.warning("AE2 cable couldn't be found!");
item = Itemss.logisticsFrameRequester;
}
GuiAnimatedStat stat = addAnimatedStat("gui.tab.info.logisticsRequester.aeIntegration.title", new ItemStack(item, 1, 16), 0xFF00AAFF, false);
List<String> text = new ArrayList<String>();
for (int i = 0; i < 2; i++) text.add("");
text.add("gui.tab.info.logisticsRequester.aeIntegration");
stat.setText(text);
stat.addWidget(aeIntegration = new GuiCheckBox(1, 16, 13, 0xFF000000, "gui.tab.info.logisticsRequester.aeIntegration.enable"));
}
}
}
Aggregations