Jump to content
Search In
  • More options...
Find results that contain...
Find results in...


  • Content Count

  • Joined

  • Last visited

Community Reputation

0 Neutral

About uranophane

  • Rank
    Tree Puncher
  1. In my mod, I have to render many 3d wireframe boxes. There are often thousands of wireframe cubes that need to be rendered, and my existing algorithm doesn't perform well enough (~3-5 FPS on an i7-7700 + GTX 1060). The code I currently use has the following flow (pseudocode): startGlState(); // this initializes the GlStateManager for (pos in coordinates){ glLineWidth(width); // width varies drawBox(pos, color); // both vary } endGlState(); // this restores the GlStateManager drawBox(pos, color){ getTessellator(); // this instatiates a tessellator startBufferBuilding(); // this in
  2. I copied those numbers from the GL11 class, but I have trouble finding the file in which the Enum was declared. I haven't been using Eclipse for very long. Sorry if it sounds like I'm asking for a java tutorial, I just wish to know how I can navigate to the enum declaration. EDIT: Nevermind, there was no enum. Those constants were declared directly in the GL11 class. I ended up including it and doing GL11.GL_LESS.
  3. Found the solution. It was the simple command GLStateManager.depthfunc(519); ... //draw stuff GLStateManager.depthfunc(515); Found it by digging through the glowing entity renderer.
  4. Actually, what you described is exactly what I was trying to achieve. I was trying to draw 3D lines that overlay on top of the world. 3D as in they "physically" exist in the world, with 3D coordinates that align with the world. However, they are displayed on top of the world at all times. Kind of like how the old Zombe Mob Highlighter's lines work, except they are static and not attached to mobs.
  5. This may sound like a trivial question: how should I draw lines "on top" of the terrain? On top, as in, on a layer that's above the world so that they are visible whether they are underground or above ground. I am quite new to modding and frankly have no idea how Minecraft renders its screen. All I managed to find out was it uses the Tessellator and WorldRenderer (which is a BufferBuilder) objects to draw things. Currently, I'm using the same method as how Minecraft draws its block selection boxes (EXCEPT subscribed to the onWorldRenderFinish event instead of onDrawSelectionBox)
  • Create New...

Important Information

By using this site, you agree to our Privacy Policy.