mirror of
https://github.com/Thorfusion/Mekanism-Community-Edition.git
synced 2026-11-26 14:52:58 +00:00
Minor fixes, seems the pushAttrib stuff is purely for saving the data and didn't change any states
This commit is contained in:
2 files changed
+4
-8
No files matched your search
@@ -39,7 +39,8 @@ public class ParticleLaser extends Particle {
|
||||
Tessellator tessellator = Tessellator.getInstance();
|
||||
tessellator.draw();
|
||||
|
||||
MekanismRenderHelper renderHelper = new MekanismRenderHelper(true).enablePolygonOffset().disableCull();
|
||||
MekanismRenderHelper renderHelper = new MekanismRenderHelper(true).disableCull();
|
||||
//TODO: Double check if GL11.GL_POLYGON_BIT is needed. It didn't seem to be used and removing it doesn't seem to have broken anything
|
||||
MekanismRenderer.glowOn();
|
||||
|
||||
float newX = (float) (prevPosX + (posX - prevPosX) * (double) partialTicks - interpPosX);
|
||||
|
||||
@@ -247,9 +247,7 @@ public class MekanismRenderer {
|
||||
}
|
||||
|
||||
public static void glowOn(int glow) {
|
||||
//TODO: Doesn't fully work anymore after change away from GL11
|
||||
GlStateManager.enableLighting();
|
||||
//GL11.glPushAttrib(GL11.GL_LIGHTING_BIT);
|
||||
//TODO: Verify we don't need more here to mirror the saving done by glPushAttrib
|
||||
try {
|
||||
lightmapLastX = OpenGlHelper.lastBrightnessX;
|
||||
lightmapLastY = OpenGlHelper.lastBrightnessY;
|
||||
@@ -269,12 +267,10 @@ public class MekanismRenderer {
|
||||
if (!optifineBreak) {
|
||||
OpenGlHelper.setLightmapTextureCoords(OpenGlHelper.lightmapTexUnit, lightmapLastX, lightmapLastY);
|
||||
}
|
||||
GlStateManager.disableLighting();
|
||||
}
|
||||
|
||||
public static void blendOn() {
|
||||
//GL11.glPushAttrib(GL11.GL_COLOR_BUFFER_BIT | GL11.GL_LIGHTING_BIT);
|
||||
GlStateManager.enableLighting();
|
||||
//TODO: Verify we don't need more here to mirror the saving done by glPushAttrib
|
||||
GlStateManager.shadeModel(GL11.GL_SMOOTH);
|
||||
GlStateManager.disableAlpha();
|
||||
GlStateManager.enableBlend();
|
||||
@@ -282,7 +278,6 @@ public class MekanismRenderer {
|
||||
}
|
||||
|
||||
public static void blendOff() {
|
||||
GlStateManager.disableLighting();
|
||||
GlStateManager.disableBlend();
|
||||
GlStateManager.enableAlpha();
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user