Posted June 26, 201411 yr Hello, I am drawing image onto the main screen. For some reason, the image I am trying to draw is coming out completely transparent, but any other image I draw with the same exact method is working fine. I might have exported it out of gimp wrong or something. Any ideas? Other images working: But not the one I want: Here's my code: private final GUIOverlay gui = new GUIOverlay(); @SideOnly(Side.CLIENT) @SubscribeEvent public void renderOverlay(RenderGameOverlayEvent.Post event){ if(event.isCancelable() || event.type != ElementType.EXPERIENCE) return; if(EventArmorFullSet.size != 0) gui.drawArmor(); } public class GUIOverlay { public void drawArmor() { ResourceLocation r = null; switch(EventArmorFullSet.size) { case 1: r = set("half"); Minecraft mc = Minecraft.getMinecraft(); ScaledResolution sr = new ScaledResolution(mc.gameSettings, mc.displayWidth, mc.displayHeight); int x = sr.getScaledWidth() - 225; int y = sr.getScaledHeight() - 50; mc.getTextureManager().bindTexture(r); Util.drawTexturedModalRect(x, y, 0, 0, 9, 9); break; } } public ResourceLocation set(String size){ return new ResourceLocation(Reference.PREFIX + "textures/gui/armorBar_half.png"); } } Lead DivineRPG Developer
June 26, 201411 yr There is a post I had recently about orang color where GreyGhost posted some very helpfull material. Search and read up on it. Before doign anything elaborate, I would boundary your render code inside push/pop calls to make sure that you are not being gifted by some other gl calls. Long time Bukkit & Forge Programmer Happy to try and help
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.