TechReborn/src/main/java/techreborn/pda/GuiPda.java

47 lines
1.2 KiB
Java
Raw Normal View History

package techreborn.pda;
2015-04-18 13:13:22 +02:00
import net.minecraft.client.gui.GuiScreen;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.util.ResourceLocation;
2015-04-24 15:20:09 +02:00
public class GuiPda extends GuiScreen {
2015-04-18 13:13:22 +02:00
public final int guiWidth = 256;
2015-04-24 15:20:09 +02:00
public final int guiHeight = 180;
private int guiLeft, guiTop;
private static final ResourceLocation pdaGuipages = new ResourceLocation(
"techreborn:" + "textures/gui/pda.png");
public static final ResourceLocation buttonOre = new ResourceLocation(
"techreborn:" + "textures/blocks/ore/book_of_revealing");
2015-04-18 13:13:22 +02:00
2015-04-24 15:20:09 +02:00
public GuiPda(EntityPlayer player)
{
}
2015-04-18 13:13:22 +02:00
@Override
2015-04-24 15:20:09 +02:00
public void initGui()
2015-04-18 13:13:22 +02:00
{
2015-04-21 01:55:48 +02:00
super.initGui();
2015-04-24 15:20:09 +02:00
this.guiLeft = this.width / 2 - this.guiWidth / 2;
this.guiTop = this.height / 2 - this.guiHeight / 2;
GuiButtonCustomTexture oresButton = new GuiButtonCustomTexture(1,
guiLeft + 20, guiTop + 20, 0, 224, 16, 16, buttonOre);
2015-04-21 01:55:48 +02:00
2015-04-24 15:20:09 +02:00
buttonList.add(oresButton);
2015-04-18 13:13:22 +02:00
}
2015-04-24 15:20:09 +02:00
2015-04-18 13:13:22 +02:00
@Override
2015-04-24 15:20:09 +02:00
public void drawScreen(int mouseX, int mouseY, float partialTicks)
2015-04-18 13:13:22 +02:00
{
2015-04-24 15:20:09 +02:00
mc.getTextureManager().bindTexture(pdaGuipages);
drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, this.guiWidth,
this.guiHeight);
mc.renderEngine.bindTexture(buttonOre);
2015-04-18 13:13:22 +02:00
super.drawScreen(mouseX, mouseY, partialTicks);
}
2015-04-21 01:55:48 +02:00
2015-04-18 13:13:22 +02:00
}