mirror of
https://github.com/Ellpeck/ActuallyAdditions.git
synced 2024-12-22 19:39:24 +01:00
Made picture pages not suck
This commit is contained in:
parent
74cd597407
commit
7ae35e05a9
2 changed files with 10 additions and 0 deletions
|
@ -12,6 +12,7 @@ package de.ellpeck.actuallyadditions.mod.booklet.page;
|
|||
|
||||
import de.ellpeck.actuallyadditions.api.booklet.internal.GuiBookletBase;
|
||||
import de.ellpeck.actuallyadditions.mod.util.AssetUtil;
|
||||
import net.minecraft.client.renderer.GlStateManager;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraftforge.fml.client.config.GuiUtils;
|
||||
|
||||
|
@ -35,7 +36,14 @@ public class PagePicture extends BookletPage{
|
|||
super.drawScreenPre(gui, startX, startY, mouseX, mouseY, partialTicks);
|
||||
|
||||
gui.mc.getTextureManager().bindTexture(this.resLoc);
|
||||
|
||||
GlStateManager.pushMatrix();
|
||||
GlStateManager.enableBlend();
|
||||
GlStateManager.disableAlpha();
|
||||
GuiUtils.drawTexturedModalRect(startX-6, startY-7, 0, 0, 256, 256, 0);
|
||||
GlStateManager.disableBlend();
|
||||
GlStateManager.enableAlpha();
|
||||
GlStateManager.popMatrix();
|
||||
|
||||
PageTextOnly.renderTextToPage(gui, this, startX+6, startY-7+this.yTextOffset);
|
||||
}
|
||||
|
|
|
@ -82,6 +82,7 @@ public class FluidDisplay extends Gui{
|
|||
if(stack != null && fluid != null && this.resLoc != null){
|
||||
mc.getTextureManager().bindTexture(this.resLoc);
|
||||
|
||||
GlStateManager.pushMatrix();
|
||||
GlStateManager.enableBlend();
|
||||
GlStateManager.disableAlpha();
|
||||
GlStateManager.tryBlendFuncSeparate(770, 771, 1, 0);
|
||||
|
@ -89,6 +90,7 @@ public class FluidDisplay extends Gui{
|
|||
GuiInputter.drawModalRectWithCustomSizedTexture(barX+1, barY+84-i, 36, 172, 16, i, 16, 512);
|
||||
GlStateManager.disableBlend();
|
||||
GlStateManager.enableAlpha();
|
||||
GlStateManager.popMatrix();
|
||||
}
|
||||
|
||||
if(this.drawTextNextTo){
|
||||
|
|
Loading…
Reference in a new issue