From d2b51db61d6c0048f8ade5ec7687fcbb464a5856 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Florian=20N=C3=BCcke?= Date: Sat, 2 May 2015 14:05:22 +0200 Subject: [PATCH] Storing and restoring OpenGL attribs in robot renderer. May help with some things rendering incorrectly if rendered after the robot, otherwise. Possibly. --- .../li/cil/oc/client/renderer/tileentity/RobotRenderer.scala | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/main/scala/li/cil/oc/client/renderer/tileentity/RobotRenderer.scala b/src/main/scala/li/cil/oc/client/renderer/tileentity/RobotRenderer.scala index 804425e49..68fb1a4bd 100644 --- a/src/main/scala/li/cil/oc/client/renderer/tileentity/RobotRenderer.scala +++ b/src/main/scala/li/cil/oc/client/renderer/tileentity/RobotRenderer.scala @@ -285,6 +285,7 @@ object RobotRenderer extends TileEntitySpecialRenderer { val worldTime = entity.getWorldObj.getTotalWorldTime + f GL11.glPushMatrix() + GL11.glPushAttrib(GL11.GL_ALL_ATTRIB_BITS) GL11.glTranslated(x + 0.5, y + 0.5, z + 0.5) // If the move started while we were rendering and we have a reference to @@ -506,6 +507,7 @@ object RobotRenderer extends TileEntitySpecialRenderer { } GL11.glPopMatrix() + GL11.glPopAttrib() RenderState.checkError(getClass.getName + ".renderTileEntityAt: leaving") }