Oh that's slightly outdated code.
GL11.glPushMatrix();
GL11.glEnable(GL11.GL_BLEND);
GL11.glColor4f(1, 1, 1, 1);
ResourceLocation r = new ResourceLocation(Reference.PREFIX + "textures/gui/armorBar.png");
res = new ScaledResolution(Minecraft.getMinecraft(), Minecraft.getMinecraft().displayWidth, Minecraft.getMinecraft().displayHeight);
int x = (res.getScaledWidth() / 2) - 11;
int y = res.getScaledHeight() - 49;
switch(EventArmorTick.size) {
case 1:
Minecraft.getMinecraft().getTextureManager().bindTexture(r);
Util.drawTexturedModalRect(x, y, 0, 0, 9, 9);
break;
}
GL11.glDisable(GL11.GL_BLEND);
GL11.glPopMatrix();
Here's drawTexturedModalRect. Pretty sure this is the same as the normal drawTexturedModalRect, I don't remember why I added it.
public static void drawTexturedModalRect(int par1, int par2, int par3, int par4, int par5, int par6) {
float f = 0.00390625F;
float f1 = 0.00390625F;
Tessellator tessellator = Tessellator.instance;
tessellator.startDrawingQuads();
tessellator.addVertexWithUV((double)(par1 + 0), (double)(par2 + par6), 1D, (double)((float)(par3 + 0) * f), (double)((float)(par4 + par6) * f1));
tessellator.addVertexWithUV((double)(par1 + par5), (double)(par2 + par6), 1D, (double)((float)(par3 + par5) * f), (double)((float)(par4 + par6) * f1));
tessellator.addVertexWithUV((double)(par1 + par5), (double)(par2 + 0), 1D, (double)((float)(par3 + par5) * f), (double)((float)(par4 + 0) * f1));
tessellator.addVertexWithUV((double)(par1 + 0), (double)(par2 + 0), 1D, (double)((float)(par3 + 0) * f), (double)((float)(par4 + 0) * f1));
tessellator.draw();
}