Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package net.scratchforfun.mod.gui;
- import org.lwjgl.opengl.GL11;
- import cpw.mods.fml.relauncher.Side;
- import cpw.mods.fml.relauncher.SideOnly;
- import net.minecraft.client.Minecraft;
- import net.minecraft.client.gui.inventory.GuiContainer;
- import net.minecraft.client.resources.I18n;
- import net.minecraft.entity.player.InventoryPlayer;
- import net.minecraft.inventory.Container;
- import net.minecraft.util.ResourceLocation;
- import net.scratchforfun.mod.ScratchForFun;
- import net.scratchforfun.mod.tileentity.TileEntityQuartzFurnace;
- @SideOnly(Side.CLIENT)
- public class GuiQuartzFurnace extends GuiContainer{
- public static final ResourceLocation FURNACEGUI = new ResourceLocation(ScratchForFun.modid, "textures/gui/quartzFurnace.png");
- public TileEntityQuartzFurnace quartzFurnace;
- public GuiQuartzFurnace(InventoryPlayer inventoryPlayer, TileEntityQuartzFurnace entity) {
- super(new ContainerQuartzFurnace(inventoryPlayer, entity));
- this.quartzFurnace = entity;
- this.xSize = 176;
- this.ySize = 166;
- }
- public void drawGuiContainerForegroundLayer(int par1, int par2){
- String name = this.quartzFurnace.isInvNameLocalized() ? this.quartzFurnace.getInvName() : "Quartz Furnace";
- this.fontRenderer.drawString(name, this.xSize /2 - this.fontRenderer.getStringWidth(name) / 2, 6, 4210752);
- this.fontRenderer.drawString("Inventory", 8, this.ySize - 96 + 2, 4210752);
- }
- /** Draws eveything behind the items*/
- protected void drawGuiContainerBackgroundLayer(float par1, int par2, int par3){
- GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
- this.mc.getTextureManager().bindTexture(FURNACEGUI);
- int k = (this.width - this.xSize) / 2;
- int l = (this.height - this.ySize) / 2;
- this.drawTexturedModalRect(k, l, 0, 0, this.xSize, this.ySize);
- int i1;
- /*if (this.quartzFurnace.isBurning())
- {
- i1 = this.quartzFurnace.getBurnTimeRemainingScaled(12);
- this.drawTexturedModalRect(k + 56, l + 36 + 12 - i1, 176, 12 - i1, 14, i1 + 2);
- }
- i1 = this.quartzFurnace.getCookProgressScaled(24);
- this.drawTexturedModalRect(k + 79, l + 34, 176, 14, i1 + 1, 16);*/
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement