Posted June 21, 201411 yr Hi, Does minecraft limit the texture size ? I create an image (512*512) which contains my gui. BUt when i m trying to load my gui, i ve got 4 gui(i think it s 256*256). How can i create a gui more tall than 256? Thanks for reading
June 22, 201411 yr Author So i fail to draw this, so i stick 2 textures, one for my panel and another for my container.
June 22, 201411 yr Well its actually quite 'easy'. Tessellator!!! I have made a drawing helper class I can post if you want it. All you have to do is bind the texture you want and figure out where you want to draw it! Just say the word if you want the helper class. Otherwise, ask for hints on how to do it (aside from tessellator. I already gave that hint) We all stuff up sometimes... But I seem to be at the bottom of that pot.
June 22, 201411 yr Hi Show a screenshot of what you actually see? Also your code for creating and rendering the GUI? -TGG
June 22, 201411 yr Notch made it somewhere in the code that the max size is 256x256, so you need to call your own render method. Don't PM me with questions. They will be ignored! Make a thread on the appropriate board for support. 1.12 -> 1.13 primer by williewillus. 1.7.10 and older versions of Minecraft are no longer supported due to it's age! Update to the latest version for support. http://www.howoldisminecraft1710.today/
July 4, 201411 yr public void drawTexturedRect(int x, int y, int u, int v, int width, int height, int textureWidth, int textureHeight) { float f = 1F / (float)textureWidth; float f1 = 1F / (float)textureHeight; Tessellator tessellator = Tessellator.instance; tessellator.startDrawingQuads(); tessellator.addVertexWithUV((double)(x), (double)(y + height), 0, (double)((float)(u) * f), (double)((float)(v + height) * f1)); tessellator.addVertexWithUV((double)(x + width), (double)(y + height), 0, (double)((float)(u + width) * f), (double)((float)(v + height) * f1)); tessellator.addVertexWithUV((double)(x + width), (double)(y), 0, (double)((float)(u + width) * f), (double)((float)(v) * f1)); tessellator.addVertexWithUV((double)(x), (double)(y), 0, (double)((float)(u) * f), (double)((float)(v) * f1)); tessellator.draw(); }
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.