import jaclib.memory.Stream;
import jaggl.MapBuffer;
import jaggl.OpenGL;
import java.awt.Canvas;

public final class Class545_Sub2_Sub2 extends Class545_Sub2 {

   boolean aBool10328;
   Class456 aClass456_10329 = new Class456();
   Class456 aClass456_10330 = new Class456();
   String aString10331;
   Class456 aClass456_10332 = new Class456();
   Class456 aClass456_10333 = new Class456();
   Class456 aClass456_10334 = new Class456();
   Class456 aClass456_10335 = new Class456();
   long aLong10336;
   int[] anIntArray10337 = new int[1000];
   OpenGL anOpenGL10338;
   boolean aBool10339;
   float[] aFloatArray10340;
   int anInt10341;
   Class456 aClass456_10342 = new Class456();
   boolean aBool10343;
   int[] anIntArray10344;
   boolean aBool10345;
   String aString10346;
   boolean aBool10347;
   int anInt10348;
   boolean aBool10349;
   Class100_Sub2 aClass100_Sub2_10350;
   Class258_Sub1 aClass258_Sub1_10351;
   boolean aBool10352;
   boolean aBool10353;
   int anInt10354;
   boolean aBool10355;
   Class258_Sub2[] aClass258_Sub2Array10356 = new Class258_Sub2[16];
   float[] aFloatArray10357;


   public void kz(int var1, int var2) {
      int var3 = 0;
      if((var1 & 1) != 0) {
         OpenGL.glClearColor((float)(var2 & 16711680) / 1.671168E7F, (float)(var2 & '\uff00') / 65280.0F, (float)(var2 & 255) / 255.0F, (float)(var2 >>> 24) / 255.0F);
         var3 = 16384;
      }

      if((var1 & 2) != 0) {
         this.method15023(true);
         var3 |= 256;
      }

      if((var1 & 4) != 0) {
         var3 |= 1024;
      }

      OpenGL.glClear(var3);
   }

   public Class103 method15316(String var1) {
      byte[] var2 = this.method15902(var1);
      if(var2 == null) {
         return null;
      } else {
         Class28 var3 = this.method14970(var2);
         return new Class103_Sub1(this, var3);
      }
   }

   public void method14991(Class341 var1) {
      Class348[] var2 = var1.aClass348Array4375;
      int var3 = 0;
      boolean var4 = false;
      boolean var5 = false;
      boolean var6 = false;

      int var7;
      for(var7 = 0; var7 < var2.length; ++var7) {
         Class348 var8 = var2[var7];
         Class258_Sub2 var9 = this.aClass258_Sub2Array10356[var7];
         int var10 = 0;
         int var11 = var9.method13113();
         long var12 = var9.method4651();
         var9.method4648();

         for(int var14 = 0; var14 < var8.method6350(); ++var14) {
            Class347 var15 = var8.method6347(var14);
            switch(var15.anInt4437) {
            case 0:
               OpenGL.glVertexPointer(3, 5126, var11, var12 + (long)var10);
               var6 = true;
            case 1:
            case 4:
            case 5:
            case 7:
            default:
               break;
            case 2:
               OpenGL.glClientActiveTexture('\u84c0' + var3++);
               OpenGL.glTexCoordPointer(3, 5126, var11, var12 + (long)var10);
               break;
            case 3:
               OpenGL.glClientActiveTexture('\u84c0' + var3++);
               OpenGL.glTexCoordPointer(1, 5126, var11, var12 + (long)var10);
               break;
            case 6:
               OpenGL.glColorPointer(4, 5121, var11, var12 + (long)var10);
               var4 = true;
               break;
            case 8:
               OpenGL.glClientActiveTexture('\u84c0' + var3++);
               OpenGL.glTexCoordPointer(4, 5126, var11, var12 + (long)var10);
               break;
            case 9:
               OpenGL.glClientActiveTexture('\u84c0' + var3++);
               OpenGL.glTexCoordPointer(2, 5126, var11, var12 + (long)var10);
               break;
            case 10:
               OpenGL.glNormalPointer(5126, var11, var12 + (long)var10);
               var5 = true;
            }

            var10 += var15.anInt4431;
         }
      }

      if(this.aBool10347 != var6) {
         if(var6) {
            OpenGL.glEnableClientState('\u8074');
         } else {
            OpenGL.glDisableClientState('\u8074');
         }

         this.aBool10347 = var6;
      }

      if(this.aBool10345 != var5) {
         if(var5) {
            OpenGL.glEnableClientState('\u8075');
         } else {
            OpenGL.glDisableClientState('\u8075');
         }

         this.aBool10345 = var5;
      }

      if(this.aBool10339 != var4) {
         if(var4) {
            OpenGL.glEnableClientState('\u8076');
         } else {
            OpenGL.glDisableClientState('\u8076');
         }

         this.aBool10339 = var4;
      }

      if(this.anInt10341 < var3) {
         for(var7 = this.anInt10341; var7 < var3; ++var7) {
            OpenGL.glClientActiveTexture('\u84c0' + var7);
            OpenGL.glEnableClientState('\u8078');
         }

         this.anInt10341 = var3;
      } else if(this.anInt10341 > var3) {
         for(var7 = var3; var7 < this.anInt10341; ++var7) {
            OpenGL.glClientActiveTexture('\u84c0' + var7);
            OpenGL.glDisableClientState('\u8078');
         }

         this.anInt10341 = var3;
      }

   }

   public boolean method14968() {
      return this.aBool10343;
   }

   Class545_Sub2_Sub2(OpenGL var1, Canvas var2, long var3, Interface24 var5, Class253 var6, int var7) {
      super(var5, var6, var7, 1);
      new MapBuffer();
      new MapBuffer();
      this.aFloatArray10340 = new float[4];
      this.aFloatArray10357 = new float[16];
      int[] var8 = new int[1];

      try {
         this.anOpenGL10338 = var1;
         this.anOpenGL10338.method2776();
         this.aString10346 = OpenGL.glGetString(7936).toLowerCase();
         this.aString10331 = OpenGL.glGetString(7937).toLowerCase();
         if(this.aString10346.indexOf("microsoft") == -1 && this.aString10346.indexOf("brian paul") == -1 && this.aString10346.indexOf("mesa") == -1) {
            String var9 = OpenGL.glGetString(7938);
            String[] var10 = Class34.method879(var9.replace('.', ' '), ' ', -1962926761);
            if(var10.length >= 2) {
               int var11;
               try {
                  var11 = Class78.method1629(var10[0], -1296471650);
                  int var12 = Class78.method1629(var10[1], -590764405);
                  this.anInt10348 = var11 * 10 + var12;
               } catch (NumberFormatException var19) {
                  throw new RuntimeException("");
               }

               if(this.anInt10348 < 12) {
                  throw new RuntimeException("");
               } else {
                  OpenGL.glGetIntegerv('\u84e2', var8, 0);
                  this.anInt9764 = var8[0];
                  if(this.anInt9764 < 2) {
                     throw new RuntimeException("");
                  } else {
                     this.anInt9636 = 8;
                     this.aBool10349 = this.anOpenGL10338.method2775("GL_ARB_vertex_buffer_object");
                     this.aBool9768 = this.anOpenGL10338.method2775("GL_ARB_multisample");
                     this.aBool10353 = this.anOpenGL10338.method2775("GL_ARB_texture_rectangle");
                     this.anOpenGL10338.method2775("GL_ARB_texture_cube_map");
                     this.aBool10328 = this.anOpenGL10338.method2775("GL_ARB_texture_non_power_of_two");
                     this.aBool9769 = true;
                     this.aBool10352 = this.anOpenGL10338.method2775("GL_ARB_vertex_shader");
                     this.anOpenGL10338.method2775("GL_ARB_vertex_program");
                     this.aBool10343 = this.anOpenGL10338.method2775("GL_ARB_fragment_shader");
                     this.anOpenGL10338.method2775("GL_ARB_fragment_program");
                     this.anOpenGL10338.method2775("GL_EXT_framebuffer_object");
                     this.anIntArray10344 = new int[this.anInt9764];
                     this.aBool9765 = this.anOpenGL10338.method2775("GL_EXT_framebuffer_object");
                     this.aBool9694 = this.anOpenGL10338.method2775("GL_EXT_framebuffer_blit");
                     this.aBool9767 = this.anOpenGL10338.method2775("GL_EXT_framebuffer_multisample");
                     if(!this.method14967() || !this.method14968()) {
                        if(!this.anOpenGL10338.method2775("GL_ARB_multitexture")) {
                           throw new RuntimeException("");
                        }

                        if(!this.anOpenGL10338.method2775("GL_ARB_texture_env_combine")) {
                           throw new RuntimeException("");
                        }
                     }

                     this.anInt10354 = Stream.method3022()?'\u8367':5121;
                     if(this.aString10331.indexOf("radeon") != -1) {
                        var11 = 0;
                        boolean var23 = false;
                        boolean var13 = false;
                        String[] var14 = Class34.method879(this.aString10331.replace('/', ' '), ' ', -1260369062);

                        for(int var15 = 0; var15 < var14.length; ++var15) {
                           String var16 = var14[var15];

                           try {
                              if(var16.length() > 0) {
                                 if(var16.charAt(0) == 120 && var16.length() >= 3 && IncommingOpcode.method5361(var16.substring(1, 3), 1588581680)) {
                                    var16 = var16.substring(1);
                                    var13 = true;
                                 }

                                 if(var16.equals("hd")) {
                                    var23 = true;
                                 } else {
                                    if(var16.startsWith("hd")) {
                                       var16 = var16.substring(2);
                                       var23 = true;
                                    }

                                    if(var16.length() >= 4 && IncommingOpcode.method5361(var16.substring(0, 4), 1622097573)) {
                                       var11 = Class78.method1629(var16.substring(0, 4), -941262936);
                                       break;
                                    }
                                 }
                              }
                           } catch (Exception var20) {
                              ;
                           }
                        }

                        if(!var13 && !var23) {
                           if(var11 >= 7000 && var11 <= 7999) {
                              this.aBool10349 = false;
                           }

                           if(var11 >= 7000 && var11 <= 9250) {
                              this.aBool9769 = false;
                           }
                        }

                        this.aBool10353 &= this.anOpenGL10338.method2775("GL_ARB_half_float_pixel");
                     }

                     if(this.aString10346.indexOf("intel") != -1) {
                        ;
                     }

                     if(this.aBool10349) {
                        try {
                           int[] var22 = new int[1];
                           OpenGL.glGenBuffersARB(1, var22, 0);
                        } catch (Throwable var18) {
                           throw new RuntimeException("");
                        }
                     }

                     this.method11448(var2, new Class151_Sub2_Sub2_Sub1(this, var2, var3), -896473865);
                     this.method11449(var2, (byte)101);
                     this.method14989('\u8000', false);
                     this.method14989('\u8000', false);
                  }
               }
            } else {
               throw new RuntimeException("");
            }
         } else {
            throw new RuntimeException("");
         }
      } catch (Throwable var21) {
         var21.printStackTrace();
         this.method11431(434608761);
         if(var21 instanceof OutOfMemoryError) {
            throw (OutOfMemoryError)var21;
         } else {
            throw new RuntimeException("");
         }
      }
   }

   public void method11525() {
      OpenGL.glFinish();
   }

   public Class85 method11427() {
      int var1 = -1;
      if(this.aString10346.indexOf("nvidia") != -1) {
         var1 = 4318;
      } else if(this.aString10346.indexOf("intel") != -1) {
         var1 = '\u8086';
      } else if(this.aString10346.indexOf("ati") != -1) {
         var1 = 4098;
      }

      return new Class85(var1, "OpenGL", this.anInt10348, this.aString10331, 0L);
   }

   void method11429(int var1, int var2) throws Exception_Sub5 {
      this.aClass151_Sub2_7358.method14944();
      if(this.anInterface24_7370 != null) {
         this.anInterface24_7370.method117((byte)115);
      }

   }

   public void method11430() {
      OpenGL.glFinish();
   }

   void method11470() {
      super.method11470();
      if(this.anOpenGL10338 != null) {
         this.anOpenGL10338.method2777();
         this.anOpenGL10338.release();
         this.anOpenGL10338 = null;
      }

   }

   void method11528() {
      super.method11470();
      if(this.anOpenGL10338 != null) {
         this.anOpenGL10338.method2777();
         this.anOpenGL10338.release();
         this.anOpenGL10338 = null;
      }

   }

   Class151_Sub2 method11512(Canvas var1, int var2, int var3) {
      return new Class151_Sub2_Sub2_Sub1(this, var1);
   }

   public Class151_Sub1 method11454() {
      return new Class151_Sub1_Sub1_Sub1(this);
   }

   public Interface7 method11455(int var1, int var2, Class98 var3, Class91 var4, int var5) {
      return new Class262(this, var3, var4, var1, var2, var5);
   }

   public Interface8 method11456(int var1, int var2) {
      return new Class262(this, Class98.aClass98_990, Class91.aClass91_901, var1, var2);
   }

   public Interface8 method11457(int var1, int var2, int var3) {
      return new Class262(this, Class98.aClass98_990, Class91.aClass91_901, var1, var2, var3);
   }

   public int[] ay(int var1, int var2, int var3, int var4) {
      int[] var5 = new int[var3 * var4];
      int var6 = this.aClass151_7359.method2742();

      for(int var7 = 0; var7 < var4; ++var7) {
         OpenGL.glReadPixelsi(var1, var6 - var2 - var7 - 1, var3, 1, '\u80e1', this.anInt10354, var5, var7 * var3);
      }

      return var5;
   }

   public void method11458() {
      if(this.aClass151_7359 != null) {
         int var1 = this.aClass151_7359.method2741();
         int var2 = this.aClass151_7359.method2742();
         if(var1 > 0 || var2 > 0) {
            int var3 = this.anInt9619;
            int var4 = this.anInt9643;
            int var5 = this.anInt9686;
            int var6 = this.anInt9753;
            this.method11459();
            int var7 = this.anInt9678;
            int var8 = this.anInt9679;
            int var9 = this.anInt9735;
            int var10 = this.anInt9745;
            this.L();
            OpenGL.glReadBuffer(1028);
            OpenGL.glDrawBuffer(1029);
            this.method15014();
            this.method15071(false);
            this.method15027(false);
            this.method15022(false);
            this.method15023(false);
            this.method15051((Interface38)null);
            this.method15053(1);
            this.method15173(0);
            OpenGL.glMatrixMode(5889);
            OpenGL.glLoadIdentity();
            OpenGL.glOrtho(0.0D, 1.0D, 0.0D, 1.0D, -1.0D, 1.0D);
            OpenGL.glMatrixMode(5888);
            OpenGL.glLoadIdentity();
            OpenGL.glRasterPos2i(0, 0);
            OpenGL.glCopyPixels(0, 0, var1, var2, 6144);
            OpenGL.glFlush();
            OpenGL.glReadBuffer(1029);
            OpenGL.glDrawBuffer(1029);
            this.r(var7, var9, var8, var10);
            this.method11460(var3, var4, var5, var6);
         }
      }
   }

   public final void method15086(Class374 var1, int var2, int var3, int var4, int var5) {
      byte var6;
      int var7;
      if(var1 == Class374.aClass374_4671) {
         var6 = 1;
         var7 = var5 * 2;
      } else if(var1 == Class374.aClass374_4668) {
         var6 = 3;
         var7 = var5 + 1;
      } else if(var1 == Class374.aClass374_4670) {
         var6 = 4;
         var7 = var5 * 3;
      } else if(var1 == Class374.aClass374_4667) {
         var6 = 6;
         var7 = var5 + 2;
      } else if(var1 == Class374.aClass374_4672) {
         var6 = 5;
         var7 = var5 + 2;
      } else {
         var6 = 0;
         var7 = var5;
      }

      Class91 var8 = this.aClass258_Sub1_10351.method236();
      OpenGL.glDrawElements(var6, var7, method15912(var8), this.aClass258_Sub1_10351.method4651() + (long)(var4 * var8.anInt906 * -2107221975));
   }

   public void ba(int var1, int var2) {
      int var3 = 0;
      if((var1 & 1) != 0) {
         OpenGL.glClearColor((float)(var2 & 16711680) / 1.671168E7F, (float)(var2 & '\uff00') / 65280.0F, (float)(var2 & 255) / 255.0F, (float)(var2 >>> 24) / 255.0F);
         var3 = 16384;
      }

      if((var1 & 2) != 0) {
         this.method15023(true);
         var3 |= 256;
      }

      if((var1 & 4) != 0) {
         var3 |= 1024;
      }

      OpenGL.glClear(var3);
   }

   void method15291() {
      if(this.aClass151_7359 != null) {
         OpenGL.glViewport(this.anInt9688 + this.anInt9619, this.anInt9689 + this.aClass151_7359.method2742() - this.anInt9643 - this.anInt9753, this.anInt9686, this.anInt9753);
      }

      OpenGL.glDepthRange(this.aFloat9670, this.aFloat9671);
   }

   void method14982() {
      if(this.aClass151_7359 != null) {
         int var1 = this.anInt9688 + this.anInt9678;
         int var2 = this.anInt9689 + this.aClass151_7359.method2742() - this.anInt9745;
         int var3 = this.anInt9679 - this.anInt9678;
         int var4 = this.anInt9745 - this.anInt9735;
         if(var3 < 0) {
            var3 = 0;
         }

         if(var4 < 0) {
            var4 = 0;
         }

         OpenGL.glScissor(var1, var2, var3, var4);
      }

   }

   void method15101() {
      if(this.aBool9783) {
         OpenGL.glEnable(3089);
      } else {
         OpenGL.glDisable(3089);
      }

   }

   public void method14965(Class317 var1, Class317 var2, Class317 var3) {
      OpenGL.glMatrixMode(5888);
      this.aClass317_9649.method5611(var1, var2);
      OpenGL.glLoadMatrixf(this.aClass317_9649.aFloatArray4000, 0);
      OpenGL.glMatrixMode(5889);
      OpenGL.glLoadMatrixf(var3.aFloatArray4000, 0);
   }

   public Class151_Sub1 method11655() {
      return new Class151_Sub1_Sub1_Sub1(this);
   }

   void method15089(int var1) {
      if(!this.aBool10355) {
         OpenGL.glPolygonMode(1028, (var1 & 2) != 0?6913:6914);
      }

   }

   void method15025() {
      OpenGL.glDepthMask(this.aBool9713 && this.aBool9691);
   }

   void method15030() {
      if(this.aBool9685 && !this.aBool9630) {
         OpenGL.glEnable(2896);
      } else {
         OpenGL.glDisable(2896);
      }

   }

   void method15031() {
      this.aFloatArray10340[0] = this.aFloat9760 * this.aFloat9701;
      this.aFloatArray10340[1] = this.aFloat9760 * this.aFloat9702;
      this.aFloatArray10340[2] = this.aFloat9760 * this.aFloat9703;
      this.aFloatArray10340[3] = 1.0F;
      OpenGL.glLightModelfv(2899, this.aFloatArray10340, 0);
   }

   void method15032() {
      this.aFloatArray10340[0] = this.aFloat9705 * this.aFloat9701;
      this.aFloatArray10340[1] = this.aFloat9705 * this.aFloat9702;
      this.aFloatArray10340[2] = this.aFloat9705 * this.aFloat9703;
      this.aFloatArray10340[3] = 1.0F;
      OpenGL.glLightfv(16384, 4609, this.aFloatArray10340, 0);
      this.aFloatArray10340[0] = -this.aFloat9706 * this.aFloat9701;
      this.aFloatArray10340[1] = -this.aFloat9706 * this.aFloat9702;
      this.aFloatArray10340[2] = -this.aFloat9706 * this.aFloat9703;
      this.aFloatArray10340[3] = 1.0F;
      OpenGL.glLightfv(16385, 4609, this.aFloatArray10340, 0);
   }

   void method15331() {
      OpenGL.glMatrixMode(5890);
      if(this.aClass368Array9717[this.anInt9625] != Class368.aClass368_4615) {
         OpenGL.glLoadMatrixf(this.aClass317Array9716[this.anInt9625].method5636(this.aFloatArray10357), 0);
      } else {
         OpenGL.glLoadIdentity();
      }

      OpenGL.glMatrixMode(5888);
   }

   void method15035() {
      if(this.aBool9733) {
         OpenGL.glEnable(16384);
         OpenGL.glEnable(16385);
      } else {
         OpenGL.glDisable(16384);
         OpenGL.glDisable(16385);
      }

   }

   void method15187() {
      if(this.aBool9783) {
         OpenGL.glEnable(3089);
      } else {
         OpenGL.glDisable(3089);
      }

   }

   void method15232() {}

   boolean method15038(Class98 var1, Class91 var2) {
      return true;
   }

   Interface33 method15043(Class98 var1, Class91 var2, int var3, int var4) {
      return this.method15048(var1, var2, var3, var4);
   }

   public void method15254() {
      int var1 = this.anIntArray10344[this.anInt9625];
      if(var1 != 0) {
         this.anIntArray10344[this.anInt9625] = 0;
         OpenGL.glBindTexture(var1, 0);
         OpenGL.glDisable(var1);
      }

   }

   static final int method15901(Class367 var0) {
      if(var0 == Class367.aClass367_4609) {
         return 7681;
      } else if(var0 == Class367.aClass367_4610) {
         return 8448;
      } else if(var0 == Class367.aClass367_4613) {
         return '\u8575';
      } else if(var0 == Class367.aClass367_4612) {
         return 260;
      } else if(var0 == Class367.aClass367_4611) {
         return '\u84e7';
      } else {
         throw new IllegalArgumentException();
      }
   }

   Interface33 method15231(Class98 var1, int var2, int var3, boolean var4, byte[] var5, int var6, int var7) {
      if(!this.aBool10328 && (!Class75.method1618(var2, 98312473) || !Class75.method1618(var3, 98312473))) {
         if(this.aBool10353) {
            return new Class275_Sub2(this, var1, var2, var3, var5, var6, var7);
         } else {
            Class275_Sub1 var8 = new Class275_Sub1(this, var1, Class91.aClass91_897, Class468.method7880(var2, (byte)-64), Class468.method7880(var3, (byte)-35));
            var8.method205(0, 0, var2, var3, var5, var1, var6, var7);
            return var8;
         }
      } else {
         return new Class275_Sub1(this, var1, var2, var3, var4, var5, var6, var7);
      }
   }

   Interface33 method15060(Class98 var1, int var2, int var3, boolean var4, float[] var5, int var6, int var7) {
      if(!this.aBool10328 && (!Class75.method1618(var2, 98312473) || !Class75.method1618(var3, 98312473))) {
         if(this.aBool10353) {
            return new Class275_Sub2(this, var1, var2, var3, var5, var6, var7);
         } else {
            Class275_Sub1 var8 = new Class275_Sub1(this, var1, Class91.aClass91_902, Class468.method7880(var2, (byte)-112), Class468.method7880(var3, (byte)-60));
            var8.method13067(0, 0, var2, var3, var5, var1, var6, var7);
            return var8;
         }
      } else {
         return new Class275_Sub1(this, var1, var2, var3, var4, var5, var6, var7);
      }
   }

   void method15004() {}

   Interface37 method15046(int var1, boolean var2, int[][] var3) {
      return new Class275_Sub4(this, var1, var2, var3);
   }

   Interface3 method15047(Class98 var1, int var2, int var3, int var4, boolean var5, byte[] var6) {
      return new Class275_Sub3(this, var1, var2, var3, var4, var5, var6);
   }

   public void method15052() {
      int var1 = this.anIntArray10344[this.anInt9625];
      if(var1 != 0) {
         this.anIntArray10344[this.anInt9625] = 0;
         OpenGL.glBindTexture(var1, 0);
         OpenGL.glDisable(var1);
      }

   }

   void method15063() {
      OpenGL.glMatrixMode(5890);
      if(this.aClass368Array9717[this.anInt9625] != Class368.aClass368_4615) {
         OpenGL.glLoadMatrixf(this.aClass317Array9716[this.anInt9625].method5636(this.aFloatArray10357), 0);
      } else {
         OpenGL.glLoadIdentity();
      }

      OpenGL.glMatrixMode(5888);
   }

   void method15064() {
      OpenGL.glActiveTexture('\u84c0' + this.anInt9625);
   }

   void method15126() {
      OpenGL.glTexEnvi(8960, '\u8571', method15904(this.aClass367Array9718[this.anInt9625]));
   }

   void method15083() {
      OpenGL.glTexEnvi(8960, '\u8572', method15904(this.aClass367Array9743[this.anInt9625]));
   }

   final void method15056(int var1, Class351 var2, boolean var3, boolean var4) {
      OpenGL.glTexEnvi(8960, '\u8580' + var1, method15903(var2));
      if(var3) {
         OpenGL.glTexEnvi(8960, '\u8590' + var1, var4?771:770);
      } else {
         OpenGL.glTexEnvi(8960, '\u8590' + var1, var4?769:768);
      }

   }

   final void method15058(int var1, Class351 var2, boolean var3) {
      OpenGL.glTexEnvi(8960, '\u8588' + var1, method15903(var2));
      OpenGL.glTexEnvi(8960, '\u8598' + var1, var3?771:770);
   }

   void method15277(boolean var1) {
      if(var1) {
         OpenGL.glEnable('\u809d');
      } else {
         OpenGL.glDisable('\u809d');
      }

   }

   byte[] method15902(String var1) {
      return this.method14969("gl", var1);
   }

   static final int method15903(Class351 var0) {
      if(var0 == Class351.aClass351_4455) {
         return 5890;
      } else if(var0 == Class351.aClass351_4457) {
         return '\u8577';
      } else if(var0 == Class351.aClass351_4456) {
         return '\u8578';
      } else if(var0 == Class351.aClass351_4458) {
         return '\u8576';
      } else {
         throw new IllegalArgumentException();
      }
   }

   void method15143(int var1) {
      OpenGL.glColorMask((var1 & 1) != 0, (var1 & 2) != 0, (var1 & 4) != 0, (var1 & 8) != 0);
   }

   void method15069() {
      if(this.aBool9756) {
         OpenGL.glEnable(3008);
      } else {
         OpenGL.glDisable(3008);
      }

   }

   void method15128() {
      byte var1 = 0;
      byte var2 = 0;
      if(this.anInt9742 == 0) {
         var1 = 0;
         var2 = 0;
      } else if(this.anInt9742 == 1) {
         var1 = 1;
         var2 = 0;
      } else if(this.anInt9742 == 2) {
         var1 = 1;
         var2 = 1;
      }

      if(this.aClass57_9674 == Class57.aClass57_536) {
         OpenGL.glBlendFuncSeparate(770, 771, var1, var2);
      } else if(this.aClass57_9674 == Class57.aClass57_533) {
         OpenGL.glBlendFuncSeparate(1, 1, var1, var2);
      } else if(this.aClass57_9674 == Class57.aClass57_534) {
         OpenGL.glBlendFuncSeparate(774, 1, var1, var2);
      }

   }

   void method15070() {
      if(this.aBool9755) {
         OpenGL.glEnable(3042);
      } else {
         OpenGL.glDisable(3042);
      }

   }

   void method15259() {
      if(this.aBool9749 && this.aBool9746 && this.anInt9623 >= 0) {
         OpenGL.glEnable(2912);
      } else {
         OpenGL.glDisable(2912);
      }

   }

   void method15180() {
      if(this.aClass151_7359 != null) {
         OpenGL.glViewport(this.anInt9688 + this.anInt9619, this.anInt9689 + this.aClass151_7359.method2742() - this.anInt9643 - this.anInt9753, this.anInt9686, this.anInt9753);
      }

      OpenGL.glDepthRange(this.aFloat9670, this.aFloat9671);
   }

   void method15074(boolean var1) {
      if(var1) {
         OpenGL.glEnable('\u809d');
      } else {
         OpenGL.glDisable('\u809d');
      }

   }

   final Interface35 method15237(boolean var1) {
      return new Class258_Sub2(this, var1);
   }

   void method15222() {
      if(this.aBool9616) {
         OpenGL.glEnable(2929);
      } else {
         OpenGL.glDisable(2929);
      }

   }

   static final int method15904(Class367 var0) {
      if(var0 == Class367.aClass367_4609) {
         return 7681;
      } else if(var0 == Class367.aClass367_4610) {
         return 8448;
      } else if(var0 == Class367.aClass367_4613) {
         return '\u8575';
      } else if(var0 == Class367.aClass367_4612) {
         return 260;
      } else if(var0 == Class367.aClass367_4611) {
         return '\u84e7';
      } else {
         throw new IllegalArgumentException();
      }
   }

   public void method15078(int var1, Interface35 var2) {
      this.aClass258_Sub2Array10356[var1] = (Class258_Sub2)var2;
   }

   void method15079(Interface40 var1) {
      this.aClass258_Sub1_10351 = (Class258_Sub1)var1;
      this.aClass258_Sub1_10351.method4648();
   }

   final synchronized void method15905(int var1) {
      IntVar var2 = new IntVar(var1);
      this.aClass456_10332.method7712(var2, (byte)33);
   }

   public final synchronized void method11530(int var1) {
      int var2 = 0;
      var1 &= Integer.MAX_VALUE;

      IntVar var3;
      while(!this.aClass456_10330.method7640(-1043407349)) {
         var3 = (IntVar)this.aClass456_10330.method7649((byte)8);
         this.anIntArray10337[var2++] = (int)(var3.aLong2606 * -7222396723785363401L);
         this.anInt9637 -= var3.integer * 442885445;
         if(var2 == 1000) {
            OpenGL.glDeleteBuffersARB(var2, this.anIntArray10337, 0);
            var2 = 0;
         }
      }

      if(var2 > 0) {
         OpenGL.glDeleteBuffersARB(var2, this.anIntArray10337, 0);
         var2 = 0;
      }

      while(!this.aClass456_10342.method7640(334223834)) {
         var3 = (IntVar)this.aClass456_10342.method7649((byte)8);
         this.anIntArray10337[var2++] = (int)(var3.aLong2606 * -7222396723785363401L);
         this.anInt9722 -= var3.integer * 442885445;
         if(var2 == 1000) {
            OpenGL.glDeleteTextures(var2, this.anIntArray10337, 0);
            var2 = 0;
         }
      }

      if(var2 > 0) {
         OpenGL.glDeleteTextures(var2, this.anIntArray10337, 0);
         var2 = 0;
      }

      while(!this.aClass456_10332.method7640(136337233)) {
         var3 = (IntVar)this.aClass456_10332.method7649((byte)8);
         this.anIntArray10337[var2++] = var3.integer * 442885445;
         if(var2 == 1000) {
            OpenGL.glDeleteFramebuffersEXT(var2, this.anIntArray10337, 0);
            var2 = 0;
         }
      }

      if(var2 > 0) {
         OpenGL.glDeleteFramebuffersEXT(var2, this.anIntArray10337, 0);
         var2 = 0;
      }

      while(!this.aClass456_10333.method7640(616635137)) {
         var3 = (IntVar)this.aClass456_10333.method7649((byte)8);
         this.anIntArray10337[var2++] = (int)(var3.aLong2606 * -7222396723785363401L);
         this.anInt9638 -= var3.integer * 442885445;
         if(var2 == 1000) {
            OpenGL.glDeleteRenderbuffersEXT(var2, this.anIntArray10337, 0);
            var2 = 0;
         }
      }

      if(var2 > 0) {
         OpenGL.glDeleteRenderbuffersEXT(var2, this.anIntArray10337, 0);
         boolean var5 = false;
      }

      while(!this.aClass456_10329.method7640(-1351016741)) {
         var3 = (IntVar)this.aClass456_10329.method7649((byte)8);
         OpenGL.glDeleteLists((int)(var3.aLong2606 * -7222396723785363401L), var3.integer * 442885445);
      }

      Class225 var4;
      while(!this.aClass456_10334.method7640(-588052060)) {
         var4 = this.aClass456_10334.method7649((byte)8);
         OpenGL.glDeleteProgram((int)(var4.aLong2606 * -7222396723785363401L));
      }

      while(!this.aClass456_10335.method7640(-1313490241)) {
         var4 = this.aClass456_10335.method7649((byte)8);
         OpenGL.glDeleteShader((int)(var4.aLong2606 * -7222396723785363401L));
      }

      while(!this.aClass456_10329.method7640(1061123179)) {
         var3 = (IntVar)this.aClass456_10329.method7649((byte)8);
         OpenGL.glDeleteLists((int)(var3.aLong2606 * -7222396723785363401L), var3.integer * 442885445);
      }

      if(this.za() > 100663296 && Class339.method6240(888737651) > this.aLong10336 + 60000L) {
         System.gc();
         this.aLong10336 = Class339.method6240(-1399073141);
      }

      super.method11433(var1);
   }

   final void method15082(Interface40 var1, Class374 var2, int var3, int var4, int var5, int var6) {
      byte var7;
      int var8;
      if(var2 == Class374.aClass374_4671) {
         var7 = 1;
         var8 = var6 * 2;
      } else if(var2 == Class374.aClass374_4668) {
         var7 = 3;
         var8 = var6 + 1;
      } else if(var2 == Class374.aClass374_4670) {
         var7 = 4;
         var8 = var6 * 3;
      } else if(var2 == Class374.aClass374_4667) {
         var7 = 6;
         var8 = var6 + 2;
      } else if(var2 == Class374.aClass374_4672) {
         var7 = 5;
         var8 = var6 + 2;
      } else {
         var7 = 0;
         var8 = var6;
      }

      Class91 var9 = var1.method236();
      Class258_Sub1 var10 = (Class258_Sub1)var1;
      var10.method4648();
      OpenGL.glDrawElements(var7, var8, method15912(var9), var10.method4651() + (long)(var5 * var9.anInt906 * -2107221975));
   }

   Interface36 method15048(Class98 var1, Class91 var2, int var3, int var4) {
      return (Interface36)(!this.aBool10328 && (!Class75.method1618(var3, 98312473) || !Class75.method1618(var4, 98312473))?(this.aBool10353?new Class275_Sub2(this, var1, var2, var3, var4):new Class275_Sub1(this, var1, var2, Class468.method7880(var3, (byte)-76), Class468.method7880(var4, (byte)-18))):new Class275_Sub1(this, var1, var2, var3, var4));
   }

   public final synchronized void method11433(int var1) {
      int var2 = 0;
      var1 &= Integer.MAX_VALUE;

      IntVar var3;
      while(!this.aClass456_10330.method7640(1100878752)) {
         var3 = (IntVar)this.aClass456_10330.method7649((byte)8);
         this.anIntArray10337[var2++] = (int)(var3.aLong2606 * -7222396723785363401L);
         this.anInt9637 -= var3.integer * 442885445;
         if(var2 == 1000) {
            OpenGL.glDeleteBuffersARB(var2, this.anIntArray10337, 0);
            var2 = 0;
         }
      }

      if(var2 > 0) {
         OpenGL.glDeleteBuffersARB(var2, this.anIntArray10337, 0);
         var2 = 0;
      }

      while(!this.aClass456_10342.method7640(535177147)) {
         var3 = (IntVar)this.aClass456_10342.method7649((byte)8);
         this.anIntArray10337[var2++] = (int)(var3.aLong2606 * -7222396723785363401L);
         this.anInt9722 -= var3.integer * 442885445;
         if(var2 == 1000) {
            OpenGL.glDeleteTextures(var2, this.anIntArray10337, 0);
            var2 = 0;
         }
      }

      if(var2 > 0) {
         OpenGL.glDeleteTextures(var2, this.anIntArray10337, 0);
         var2 = 0;
      }

      while(!this.aClass456_10332.method7640(1833558349)) {
         var3 = (IntVar)this.aClass456_10332.method7649((byte)8);
         this.anIntArray10337[var2++] = var3.integer * 442885445;
         if(var2 == 1000) {
            OpenGL.glDeleteFramebuffersEXT(var2, this.anIntArray10337, 0);
            var2 = 0;
         }
      }

      if(var2 > 0) {
         OpenGL.glDeleteFramebuffersEXT(var2, this.anIntArray10337, 0);
         var2 = 0;
      }

      while(!this.aClass456_10333.method7640(-706440159)) {
         var3 = (IntVar)this.aClass456_10333.method7649((byte)8);
         this.anIntArray10337[var2++] = (int)(var3.aLong2606 * -7222396723785363401L);
         this.anInt9638 -= var3.integer * 442885445;
         if(var2 == 1000) {
            OpenGL.glDeleteRenderbuffersEXT(var2, this.anIntArray10337, 0);
            var2 = 0;
         }
      }

      if(var2 > 0) {
         OpenGL.glDeleteRenderbuffersEXT(var2, this.anIntArray10337, 0);
         boolean var5 = false;
      }

      while(!this.aClass456_10329.method7640(1807371406)) {
         var3 = (IntVar)this.aClass456_10329.method7649((byte)8);
         OpenGL.glDeleteLists((int)(var3.aLong2606 * -7222396723785363401L), var3.integer * 442885445);
      }

      Class225 var4;
      while(!this.aClass456_10334.method7640(1535527117)) {
         var4 = this.aClass456_10334.method7649((byte)8);
         OpenGL.glDeleteProgram((int)(var4.aLong2606 * -7222396723785363401L));
      }

      while(!this.aClass456_10335.method7640(265816484)) {
         var4 = this.aClass456_10335.method7649((byte)8);
         OpenGL.glDeleteShader((int)(var4.aLong2606 * -7222396723785363401L));
      }

      while(!this.aClass456_10329.method7640(1943387256)) {
         var3 = (IntVar)this.aClass456_10329.method7649((byte)8);
         OpenGL.glDeleteLists((int)(var3.aLong2606 * -7222396723785363401L), var3.integer * 442885445);
      }

      if(this.za() > 100663296 && Class339.method6240(-1558744756) > this.aLong10336 + 60000L) {
         System.gc();
         this.aLong10336 = Class339.method6240(864500048);
      }

      super.method11433(var1);
   }

   final synchronized void method15906(int var1, int var2) {
      IntVar var3 = new IntVar(var2);
      var3.aLong2606 = (long)var1 * -641052250121656953L;
      this.aClass456_10330.method7712(var3, (byte)112);
   }

   final synchronized void method15907(int var1, int var2) {
      IntVar var3 = new IntVar(var2);
      var3.aLong2606 = (long)var1 * -641052250121656953L;
      this.aClass456_10342.method7712(var3, (byte)112);
   }

   final synchronized void method15908(int var1) {
      IntVar var2 = new IntVar(var1);
      this.aClass456_10332.method7712(var2, (byte)44);
   }

   final synchronized void method15909(int var1, int var2) {
      IntVar var3 = new IntVar(var2);
      var3.aLong2606 = (long)var1 * -641052250121656953L;
      this.aClass456_10333.method7712(var3, (byte)90);
   }

   final synchronized void method15910(long var1) {
      Class225 var3 = new Class225();
      var3.aLong2606 = var1 * -641052250121656953L;
      this.aClass456_10335.method7712(var3, (byte)108);
   }

   final synchronized void method15911(int var1) {
      Class225 var2 = new Class225();
      var2.aLong2606 = (long)var1 * -641052250121656953L;
      this.aClass456_10334.method7712(var2, (byte)120);
   }

   static final int method15912(Class91 var0) {
      switch(var0.anInt905 * -1560869161) {
      case 0:
         return 5125;
      case 1:
      default:
         return 5121;
      case 2:
         return 5121;
      case 3:
         return 5126;
      case 4:
         return 5122;
      case 5:
         return 5123;
      case 6:
         return 5120;
      case 7:
         return 5124;
      case 8:
         return 5131;
      }
   }

   static int method15913(Class98 var0) {
      switch(var0.anInt995 * -960308681) {
      case 0:
         return 6410;
      case 1:
         return 6402;
      case 2:
      case 4:
      case 6:
      case 8:
      default:
         throw new IllegalStateException();
      case 3:
         return 6407;
      case 5:
         return 6406;
      case 7:
         return 6409;
      case 9:
         return 6408;
      }
   }

   static int method15914(Class98 var0, Class91 var1) {
      if(var1 == Class91.aClass91_897) {
         switch(var0.anInt995 * -960308681) {
         case 0:
            return 6410;
         case 1:
         case 4:
         case 8:
         default:
            throw new IllegalArgumentException();
         case 2:
            return '\u83f3';
         case 3:
            return 6407;
         case 5:
            return 6406;
         case 6:
            return '\u83f1';
         case 7:
            return 6409;
         case 9:
            return 6408;
         }
      } else if(var1 == Class91.aClass91_899) {
         switch(var0.anInt995 * -960308681) {
         case 0:
            return '\u8d7b';
         case 1:
            return '\u81a5';
         case 2:
         case 4:
         case 6:
         case 8:
         default:
            throw new IllegalArgumentException();
         case 3:
            return '\u8054';
         case 5:
            return '\u803e';
         case 7:
            return '\u8042';
         case 9:
            return '\u805b';
         }
      } else if(var1 == Class91.aClass91_901) {
         switch(var0.anInt995 * -960308681) {
         case 1:
            return '\u81a6';
         default:
            throw new IllegalArgumentException();
         }
      } else if(var1 == Class91.aClass91_903) {
         switch(var0.anInt995 * -960308681) {
         case 0:
            return '\u881f';
         case 1:
         case 2:
         case 4:
         case 6:
         case 8:
         default:
            throw new IllegalArgumentException();
         case 3:
            return '\u881b';
         case 5:
            return '\u881c';
         case 7:
            return '\u881e';
         case 9:
            return '\u881a';
         }
      } else if(var1 == Class91.aClass91_902) {
         switch(var0.anInt995 * -960308681) {
         case 0:
            return '\u8819';
         case 1:
         case 2:
         case 4:
         case 6:
         case 8:
         default:
            throw new IllegalArgumentException();
         case 3:
            return '\u8815';
         case 5:
            return '\u8816';
         case 7:
            return '\u8818';
         case 9:
            return '\u8814';
         }
      } else {
         throw new IllegalArgumentException();
      }
   }

   public void method11717(boolean var1) {}

   final synchronized void method15915(long var1) {
      Class225 var3 = new Class225();
      var3.aLong2606 = var1 * -641052250121656953L;
      this.aClass456_10335.method7712(var3, (byte)79);
   }

   void method11522(int var1, int var2) throws Exception_Sub5 {
      this.aClass151_Sub2_7358.method14944();
      if(this.anInterface24_7370 != null) {
         this.anInterface24_7370.method117((byte)37);
      }

   }

   void method11523(int var1, int var2) throws Exception_Sub5 {
      this.aClass151_Sub2_7358.method14944();
      if(this.anInterface24_7370 != null) {
         this.anInterface24_7370.method117((byte)121);
      }

   }

   static final int method15916(Class367 var0) {
      if(var0 == Class367.aClass367_4609) {
         return 7681;
      } else if(var0 == Class367.aClass367_4610) {
         return 8448;
      } else if(var0 == Class367.aClass367_4613) {
         return '\u8575';
      } else if(var0 == Class367.aClass367_4612) {
         return 260;
      } else if(var0 == Class367.aClass367_4611) {
         return '\u84e7';
      } else {
         throw new IllegalArgumentException();
      }
   }

   public void method11428() {
      if(this.aClass151_7359 != null) {
         int var1 = this.aClass151_7359.method2741();
         int var2 = this.aClass151_7359.method2742();
         if(var1 > 0 || var2 > 0) {
            int var3 = this.anInt9619;
            int var4 = this.anInt9643;
            int var5 = this.anInt9686;
            int var6 = this.anInt9753;
            this.method11459();
            int var7 = this.anInt9678;
            int var8 = this.anInt9679;
            int var9 = this.anInt9735;
            int var10 = this.anInt9745;
            this.L();
            OpenGL.glReadBuffer(1028);
            OpenGL.glDrawBuffer(1029);
            this.method15014();
            this.method15071(false);
            this.method15027(false);
            this.method15022(false);
            this.method15023(false);
            this.method15051((Interface38)null);
            this.method15053(1);
            this.method15173(0);
            OpenGL.glMatrixMode(5889);
            OpenGL.glLoadIdentity();
            OpenGL.glOrtho(0.0D, 1.0D, 0.0D, 1.0D, -1.0D, 1.0D);
            OpenGL.glMatrixMode(5888);
            OpenGL.glLoadIdentity();
            OpenGL.glRasterPos2i(0, 0);
            OpenGL.glCopyPixels(0, 0, var1, var2, 6144);
            OpenGL.glFlush();
            OpenGL.glReadBuffer(1029);
            OpenGL.glDrawBuffer(1029);
            this.r(var7, var9, var8, var10);
            this.method11460(var3, var4, var5, var6);
         }
      }
   }

   public void method11526() {
      OpenGL.glFinish();
   }

   void method15332() {
      OpenGL.glMatrixMode(5890);
      if(this.aClass368Array9717[this.anInt9625] != Class368.aClass368_4615) {
         OpenGL.glLoadMatrixf(this.aClass317Array9716[this.anInt9625].method5636(this.aFloatArray10357), 0);
      } else {
         OpenGL.glLoadIdentity();
      }

      OpenGL.glMatrixMode(5888);
   }

   final Interface40 method15298(boolean var1) {
      return new Class258_Sub1(this, Class91.aClass91_899, var1);
   }

   void method11529() {
      super.method11470();
      if(this.anOpenGL10338 != null) {
         this.anOpenGL10338.method2777();
         this.anOpenGL10338.release();
         this.anOpenGL10338 = null;
      }

   }

   final synchronized void method15917(int var1) {
      IntVar var2 = new IntVar(var1);
      this.aClass456_10332.method7712(var2, (byte)73);
   }

   public final synchronized void method11531(int var1) {
      int var2 = 0;
      var1 &= Integer.MAX_VALUE;

      IntVar var3;
      while(!this.aClass456_10330.method7640(612404112)) {
         var3 = (IntVar)this.aClass456_10330.method7649((byte)8);
         this.anIntArray10337[var2++] = (int)(var3.aLong2606 * -7222396723785363401L);
         this.anInt9637 -= var3.integer * 442885445;
         if(var2 == 1000) {
            OpenGL.glDeleteBuffersARB(var2, this.anIntArray10337, 0);
            var2 = 0;
         }
      }

      if(var2 > 0) {
         OpenGL.glDeleteBuffersARB(var2, this.anIntArray10337, 0);
         var2 = 0;
      }

      while(!this.aClass456_10342.method7640(-1824806587)) {
         var3 = (IntVar)this.aClass456_10342.method7649((byte)8);
         this.anIntArray10337[var2++] = (int)(var3.aLong2606 * -7222396723785363401L);
         this.anInt9722 -= var3.integer * 442885445;
         if(var2 == 1000) {
            OpenGL.glDeleteTextures(var2, this.anIntArray10337, 0);
            var2 = 0;
         }
      }

      if(var2 > 0) {
         OpenGL.glDeleteTextures(var2, this.anIntArray10337, 0);
         var2 = 0;
      }

      while(!this.aClass456_10332.method7640(46126890)) {
         var3 = (IntVar)this.aClass456_10332.method7649((byte)8);
         this.anIntArray10337[var2++] = var3.integer * 442885445;
         if(var2 == 1000) {
            OpenGL.glDeleteFramebuffersEXT(var2, this.anIntArray10337, 0);
            var2 = 0;
         }
      }

      if(var2 > 0) {
         OpenGL.glDeleteFramebuffersEXT(var2, this.anIntArray10337, 0);
         var2 = 0;
      }

      while(!this.aClass456_10333.method7640(-1646066508)) {
         var3 = (IntVar)this.aClass456_10333.method7649((byte)8);
         this.anIntArray10337[var2++] = (int)(var3.aLong2606 * -7222396723785363401L);
         this.anInt9638 -= var3.integer * 442885445;
         if(var2 == 1000) {
            OpenGL.glDeleteRenderbuffersEXT(var2, this.anIntArray10337, 0);
            var2 = 0;
         }
      }

      if(var2 > 0) {
         OpenGL.glDeleteRenderbuffersEXT(var2, this.anIntArray10337, 0);
         boolean var5 = false;
      }

      while(!this.aClass456_10329.method7640(-291000181)) {
         var3 = (IntVar)this.aClass456_10329.method7649((byte)8);
         OpenGL.glDeleteLists((int)(var3.aLong2606 * -7222396723785363401L), var3.integer * 442885445);
      }

      Class225 var4;
      while(!this.aClass456_10334.method7640(469575202)) {
         var4 = this.aClass456_10334.method7649((byte)8);
         OpenGL.glDeleteProgram((int)(var4.aLong2606 * -7222396723785363401L));
      }

      while(!this.aClass456_10335.method7640(1102089372)) {
         var4 = this.aClass456_10335.method7649((byte)8);
         OpenGL.glDeleteShader((int)(var4.aLong2606 * -7222396723785363401L));
      }

      while(!this.aClass456_10329.method7640(-32433877)) {
         var3 = (IntVar)this.aClass456_10329.method7649((byte)8);
         OpenGL.glDeleteLists((int)(var3.aLong2606 * -7222396723785363401L), var3.integer * 442885445);
      }

      if(this.za() > 100663296 && Class339.method6240(-1497337336) > this.aLong10336 + 60000L) {
         System.gc();
         this.aLong10336 = Class339.method6240(358398594);
      }

      super.method11433(var1);
   }

   public void kv(int var1, int var2) {
      int var3 = 0;
      if((var1 & 1) != 0) {
         OpenGL.glClearColor((float)(var2 & 16711680) / 1.671168E7F, (float)(var2 & '\uff00') / 65280.0F, (float)(var2 & 255) / 255.0F, (float)(var2 >>> 24) / 255.0F);
         var3 = 16384;
      }

      if((var1 & 2) != 0) {
         this.method15023(true);
         var3 |= 256;
      }

      if((var1 & 4) != 0) {
         var3 |= 1024;
      }

      OpenGL.glClear(var3);
   }

   public Class79 method11623(Class79 var1, Class79 var2, float var3, Class79 var4) {
      return var3 < 0.5F?var1:var2;
   }

   final void method15262(int var1, Class351 var2, boolean var3, boolean var4) {
      OpenGL.glTexEnvi(8960, '\u8580' + var1, method15903(var2));
      if(var3) {
         OpenGL.glTexEnvi(8960, '\u8590' + var1, var4?771:770);
      } else {
         OpenGL.glTexEnvi(8960, '\u8590' + var1, var4?769:768);
      }

   }

   Class151_Sub2 method11578(Canvas var1, int var2, int var3) {
      return new Class151_Sub2_Sub2_Sub1(this, var1);
   }

   public void method15303(Class341 var1) {
      Class348[] var2 = var1.aClass348Array4375;
      int var3 = 0;
      boolean var4 = false;
      boolean var5 = false;
      boolean var6 = false;

      int var7;
      for(var7 = 0; var7 < var2.length; ++var7) {
         Class348 var8 = var2[var7];
         Class258_Sub2 var9 = this.aClass258_Sub2Array10356[var7];
         int var10 = 0;
         int var11 = var9.method13113();
         long var12 = var9.method4651();
         var9.method4648();

         for(int var14 = 0; var14 < var8.method6350(); ++var14) {
            Class347 var15 = var8.method6347(var14);
            switch(var15.anInt4437) {
            case 0:
               OpenGL.glVertexPointer(3, 5126, var11, var12 + (long)var10);
               var6 = true;
            case 1:
            case 4:
            case 5:
            case 7:
            default:
               break;
            case 2:
               OpenGL.glClientActiveTexture('\u84c0' + var3++);
               OpenGL.glTexCoordPointer(3, 5126, var11, var12 + (long)var10);
               break;
            case 3:
               OpenGL.glClientActiveTexture('\u84c0' + var3++);
               OpenGL.glTexCoordPointer(1, 5126, var11, var12 + (long)var10);
               break;
            case 6:
               OpenGL.glColorPointer(4, 5121, var11, var12 + (long)var10);
               var4 = true;
               break;
            case 8:
               OpenGL.glClientActiveTexture('\u84c0' + var3++);
               OpenGL.glTexCoordPointer(4, 5126, var11, var12 + (long)var10);
               break;
            case 9:
               OpenGL.glClientActiveTexture('\u84c0' + var3++);
               OpenGL.glTexCoordPointer(2, 5126, var11, var12 + (long)var10);
               break;
            case 10:
               OpenGL.glNormalPointer(5126, var11, var12 + (long)var10);
               var5 = true;
            }

            var10 += var15.anInt4431;
         }
      }

      if(this.aBool10347 != var6) {
         if(var6) {
            OpenGL.glEnableClientState('\u8074');
         } else {
            OpenGL.glDisableClientState('\u8074');
         }

         this.aBool10347 = var6;
      }

      if(this.aBool10345 != var5) {
         if(var5) {
            OpenGL.glEnableClientState('\u8075');
         } else {
            OpenGL.glDisableClientState('\u8075');
         }

         this.aBool10345 = var5;
      }

      if(this.aBool10339 != var4) {
         if(var4) {
            OpenGL.glEnableClientState('\u8076');
         } else {
            OpenGL.glDisableClientState('\u8076');
         }

         this.aBool10339 = var4;
      }

      if(this.anInt10341 < var3) {
         for(var7 = this.anInt10341; var7 < var3; ++var7) {
            OpenGL.glClientActiveTexture('\u84c0' + var7);
            OpenGL.glEnableClientState('\u8078');
         }

         this.anInt10341 = var3;
      } else if(this.anInt10341 > var3) {
         for(var7 = var3; var7 < this.anInt10341; ++var7) {
            OpenGL.glClientActiveTexture('\u84c0' + var7);
            OpenGL.glDisableClientState('\u8078');
         }

         this.anInt10341 = var3;
      }

   }

   public boolean method15326() {
      return this.aBool10343;
   }

   Class151_Sub2 method11489(Canvas var1, int var2, int var3) {
      return new Class151_Sub2_Sub2_Sub1(this, var1);
   }

   void method15284() {
      OpenGL.glMatrixMode(5888);
      OpenGL.glLoadMatrixf(this.aClass317_9766.aFloatArray4000, 0);
      OpenGL.glLightfv(16384, 4611, this.aFloatArray9712, 0);
      OpenGL.glLightfv(16385, 4611, this.aFloatArray9697, 0);
   }

   void method15072() {
      this.aFloat9752 = this.aFloat9675 - (float)this.anInt9750;
      this.aFloat9751 = this.aFloat9752 - (float)this.anInt9623;
      if(this.aFloat9751 < this.aFloat9696) {
         this.aFloat9751 = this.aFloat9696;
      }

      if(this.aBool9681) {
         OpenGL.glFogf(2915, this.aFloat9751);
         OpenGL.glFogf(2916, this.aFloat9752);
         this.aFloatArray10340[0] = (float)(this.anInt9748 & 16711680) / 1.671168E7F;
         this.aFloatArray10340[1] = (float)(this.anInt9748 & '\uff00') / 65280.0F;
         this.aFloatArray10340[2] = (float)(this.anInt9748 & 255) / 255.0F;
         OpenGL.glFogfv(2918, this.aFloatArray10340, 0);
      }

   }

   public void method11542(boolean var1) {}

   void method15306(Interface40 var1) {
      this.aClass258_Sub1_10351 = (Class258_Sub1)var1;
      this.aClass258_Sub1_10351.method4648();
   }

   public Class151_Sub1 method11653() {
      return new Class151_Sub1_Sub1_Sub1(this);
   }

   public Class151_Sub1 method11654() {
      return new Class151_Sub1_Sub1_Sub1(this);
   }

   void method15228() {
      if(this.aBool9685 && !this.aBool9630) {
         OpenGL.glEnable(2896);
      } else {
         OpenGL.glDisable(2896);
      }

   }

   public Class151_Sub1 method11656() {
      return new Class151_Sub1_Sub1_Sub1(this);
   }

   public Class151_Sub1 method11657() {
      return new Class151_Sub1_Sub1_Sub1(this);
   }

   public Interface8 method11722(int var1, int var2) {
      return new Class262(this, Class98.aClass98_990, Class91.aClass91_901, var1, var2);
   }

   void method15134() {
      OpenGL.glDepthFunc(515);
      OpenGL.glEnable(2884);
      OpenGL.glCullFace(1029);
      OpenGL.glClearDepth(1.0F);
      OpenGL.glAlphaFunc(516, 0.0F);
      OpenGL.glPolygonMode(1028, 6914);

      for(int var1 = this.anInt9764 - 1; var1 >= 0; --var1) {
         OpenGL.glActiveTexture('\u84c0' + var1);
         OpenGL.glTexEnvi(8960, 8704, '\u8570');
         OpenGL.glTexEnvi(8960, '\u8571', 8448);
         OpenGL.glTexEnvi(8960, '\u8582', '\u8576');
         OpenGL.glTexEnvi(8960, '\u8572', 8448);
         OpenGL.glTexEnvi(8960, '\u858a', '\u8576');
      }

      OpenGL.glTexEnvi(8960, '\u858a', '\u8578');
      OpenGL.glShadeModel(7425);
      OpenGL.glMatrixMode(5888);
      OpenGL.glLoadIdentity();
      OpenGL.glColorMaterial(1028, 5634);
      OpenGL.glEnable(2903);
      float[] var4 = new float[]{0.0F, 0.0F, 0.0F, 1.0F};

      for(int var2 = 0; var2 < 8; ++var2) {
         int var3 = 16384 + var2;
         OpenGL.glLightfv(var3, 4608, var4, 0);
         OpenGL.glLightf(var3, 4615, 0.0F);
         OpenGL.glLightf(var3, 4616, 0.0F);
      }

      OpenGL.glFogf(2914, 0.95F);
      OpenGL.glFogi(2917, 9729);
      OpenGL.glHint(3156, 4353);
      this.anOpenGL10338.setSwapInterval(0);
      super.method15112();
   }

   public Class85 method11663() {
      int var1 = -1;
      if(this.aString10346.indexOf("nvidia") != -1) {
         var1 = 4318;
      } else if(this.aString10346.indexOf("intel") != -1) {
         var1 = '\u8086';
      } else if(this.aString10346.indexOf("ati") != -1) {
         var1 = 4098;
      }

      return new Class85(var1, "OpenGL", this.anInt10348, this.aString10331, 0L);
   }

   public int[] kx(int var1, int var2, int var3, int var4) {
      int[] var5 = new int[var3 * var4];
      int var6 = this.aClass151_7359.method2742();

      for(int var7 = 0; var7 < var4; ++var7) {
         OpenGL.glReadPixelsi(var1, var6 - var2 - var7 - 1, var3, 1, '\u80e1', this.anInt10354, var5, var7 * var3);
      }

      return var5;
   }

   public int[] kc(int var1, int var2, int var3, int var4) {
      int[] var5 = new int[var3 * var4];
      int var6 = this.aClass151_7359.method2742();

      for(int var7 = 0; var7 < var4; ++var7) {
         OpenGL.glReadPixelsi(var1, var6 - var2 - var7 - 1, var3, 1, '\u80e1', this.anInt10354, var5, var7 * var3);
      }

      return var5;
   }

   void method15281() {
      OpenGL.glMatrixMode(5888);
      OpenGL.glLoadMatrixf(this.aClass317_9766.aFloatArray4000, 0);
      OpenGL.glLightfv(16384, 4611, this.aFloatArray9712, 0);
      OpenGL.glLightfv(16385, 4611, this.aFloatArray9697, 0);
   }

   public void kd(int var1, int var2) {
      int var3 = 0;
      if((var1 & 1) != 0) {
         OpenGL.glClearColor((float)(var2 & 16711680) / 1.671168E7F, (float)(var2 & '\uff00') / 65280.0F, (float)(var2 & 255) / 255.0F, (float)(var2 >>> 24) / 255.0F);
         var3 = 16384;
      }

      if((var1 & 2) != 0) {
         this.method15023(true);
         var3 |= 256;
      }

      if((var1 & 4) != 0) {
         var3 |= 1024;
      }

      OpenGL.glClear(var3);
   }

   Interface3 method15133(Class98 var1, int var2, int var3, int var4, boolean var5, byte[] var6) {
      return new Class275_Sub3(this, var1, var2, var3, var4, var5, var6);
   }

   boolean method15330(Class98 var1, Class91 var2) {
      return true;
   }

   public boolean method15092() {
      return this.aBool10352;
   }

   public boolean method15144() {
      return this.aBool10352;
   }

   public float method15127() {
      return 0.0F;
   }

   void method15140() {
      if(this.aBool9733) {
         OpenGL.glEnable(16384);
         OpenGL.glEnable(16385);
      } else {
         OpenGL.glDisable(16384);
         OpenGL.glDisable(16385);
      }

   }

   public void method11524() {
      OpenGL.glFinish();
   }

   void method15176() {
      this.aFloatArray10340[0] = this.aFloat9705 * this.aFloat9701;
      this.aFloatArray10340[1] = this.aFloat9705 * this.aFloat9702;
      this.aFloatArray10340[2] = this.aFloat9705 * this.aFloat9703;
      this.aFloatArray10340[3] = 1.0F;
      OpenGL.glLightfv(16384, 4609, this.aFloatArray10340, 0);
      this.aFloatArray10340[0] = -this.aFloat9706 * this.aFloat9701;
      this.aFloatArray10340[1] = -this.aFloat9706 * this.aFloat9702;
      this.aFloatArray10340[2] = -this.aFloat9706 * this.aFloat9703;
      this.aFloatArray10340[3] = 1.0F;
      OpenGL.glLightfv(16385, 4609, this.aFloatArray10340, 0);
   }

   void method15153() {
      OpenGL.glDepthFunc(515);
      OpenGL.glEnable(2884);
      OpenGL.glCullFace(1029);
      OpenGL.glClearDepth(1.0F);
      OpenGL.glAlphaFunc(516, 0.0F);
      OpenGL.glPolygonMode(1028, 6914);

      for(int var1 = this.anInt9764 - 1; var1 >= 0; --var1) {
         OpenGL.glActiveTexture('\u84c0' + var1);
         OpenGL.glTexEnvi(8960, 8704, '\u8570');
         OpenGL.glTexEnvi(8960, '\u8571', 8448);
         OpenGL.glTexEnvi(8960, '\u8582', '\u8576');
         OpenGL.glTexEnvi(8960, '\u8572', 8448);
         OpenGL.glTexEnvi(8960, '\u858a', '\u8576');
      }

      OpenGL.glTexEnvi(8960, '\u858a', '\u8578');
      OpenGL.glShadeModel(7425);
      OpenGL.glMatrixMode(5888);
      OpenGL.glLoadIdentity();
      OpenGL.glColorMaterial(1028, 5634);
      OpenGL.glEnable(2903);
      float[] var4 = new float[]{0.0F, 0.0F, 0.0F, 1.0F};

      for(int var2 = 0; var2 < 8; ++var2) {
         int var3 = 16384 + var2;
         OpenGL.glLightfv(var3, 4608, var4, 0);
         OpenGL.glLightf(var3, 4615, 0.0F);
         OpenGL.glLightf(var3, 4616, 0.0F);
      }

      OpenGL.glFogf(2914, 0.95F);
      OpenGL.glFogi(2917, 9729);
      OpenGL.glHint(3156, 4353);
      this.anOpenGL10338.setSwapInterval(0);
      super.method15112();
   }

   public float method15162() {
      return 0.0F;
   }

   final Interface40 method15075(boolean var1) {
      return new Class258_Sub1(this, Class91.aClass91_899, var1);
   }

   public float method15320() {
      return 0.0F;
   }

   public boolean method14967() {
      return this.aBool10352;
   }

   void method15179() {
      if(this.aClass151_7359 != null) {
         OpenGL.glViewport(this.anInt9688 + this.anInt9619, this.anInt9689 + this.aClass151_7359.method2742() - this.anInt9643 - this.anInt9753, this.anInt9686, this.anInt9753);
      }

      OpenGL.glDepthRange(this.aFloat9670, this.aFloat9671);
   }

   boolean method15039(Class98 var1, Class91 var2) {
      return this.aBool9769;
   }

   void method15181() {
      if(this.aClass151_7359 != null) {
         OpenGL.glViewport(this.anInt9688 + this.anInt9619, this.anInt9689 + this.aClass151_7359.method2742() - this.anInt9643 - this.anInt9753, this.anInt9686, this.anInt9753);
      }

      OpenGL.glDepthRange(this.aFloat9670, this.aFloat9671);
   }

   void method15182() {
      if(this.aClass151_7359 != null) {
         OpenGL.glViewport(this.anInt9688 + this.anInt9619, this.anInt9689 + this.aClass151_7359.method2742() - this.anInt9643 - this.anInt9753, this.anInt9686, this.anInt9753);
      }

      OpenGL.glDepthRange(this.aFloat9670, this.aFloat9671);
   }

   void method15329() {
      OpenGL.glMatrixMode(5888);
      OpenGL.glLoadMatrixf(this.aClass317_9766.aFloatArray4000, 0);

      int var1;
      for(var1 = 0; var1 < this.anInt9709; ++var1) {
         Class225_Sub40 var2 = this.aClass225_Sub40Array9719[var1];
         int var3 = var2.method14107(-1712996072);
         int var4 = 16386 + var1;
         float var5 = var2.method14110(-78891819) / 255.0F;
         this.aFloatArray10340[0] = (float)var2.method14103(-976616529);
         this.aFloatArray10340[1] = (float)var2.method14104(-2019622409);
         this.aFloatArray10340[2] = (float)var2.method14105((byte)90);
         this.aFloatArray10340[3] = 1.0F;
         OpenGL.glLightfv(var4, 4611, this.aFloatArray10340, 0);
         this.aFloatArray10340[0] = (float)(var3 >> 16 & 255) * var5;
         this.aFloatArray10340[1] = (float)(var3 >> 8 & 255) * var5;
         this.aFloatArray10340[2] = (float)(var3 & 255) * var5;
         this.aFloatArray10340[3] = 1.0F;
         OpenGL.glLightfv(var4, 4609, this.aFloatArray10340, 0);
         OpenGL.glLightf(var4, 4617, 1.0F / (float)(var2.method14113(1995411920) * var2.method14113(2003940621)));
         OpenGL.glEnable(var4);
      }

      while(var1 < this.anInt9708) {
         OpenGL.glDisable(16386 + var1);
         ++var1;
      }

   }

   void method15283() {
      if(this.aBool9755) {
         OpenGL.glEnable(3042);
      } else {
         OpenGL.glDisable(3042);
      }

   }

   void method15080() {
      if(this.aClass151_7359 != null) {
         int var1 = this.anInt9688 + this.anInt9678;
         int var2 = this.anInt9689 + this.aClass151_7359.method2742() - this.anInt9745;
         int var3 = this.anInt9679 - this.anInt9678;
         int var4 = this.anInt9745 - this.anInt9735;
         if(var3 < 0) {
            var3 = 0;
         }

         if(var4 < 0) {
            var4 = 0;
         }

         OpenGL.glScissor(var1, var2, var3, var4);
      }

   }

   void method15235() {
      if(this.aBool9733) {
         OpenGL.glEnable(16384);
         OpenGL.glEnable(16385);
      } else {
         OpenGL.glDisable(16384);
         OpenGL.glDisable(16385);
      }

   }

   public Class79 method11517(Class79 var1, Class79 var2, float var3, Class79 var4) {
      return var3 < 0.5F?var1:var2;
   }

   public void method15304(int var1, Interface35 var2) {
      this.aClass258_Sub2Array10356[var1] = (Class258_Sub2)var2;
   }

   Interface33 method15244(Class98 var1, int var2, int var3, boolean var4, float[] var5, int var6, int var7) {
      if(!this.aBool10328 && (!Class75.method1618(var2, 98312473) || !Class75.method1618(var3, 98312473))) {
         if(this.aBool10353) {
            return new Class275_Sub2(this, var1, var2, var3, var5, var6, var7);
         } else {
            Class275_Sub1 var8 = new Class275_Sub1(this, var1, Class91.aClass91_902, Class468.method7880(var2, (byte)-21), Class468.method7880(var3, (byte)-104));
            var8.method13067(0, 0, var2, var3, var5, var1, var6, var7);
            return var8;
         }
      } else {
         return new Class275_Sub1(this, var1, var2, var3, var4, var5, var6, var7);
      }
   }

   public void method15209(Class317 var1) {
      float[] var2 = var1.aFloatArray4000;
      var2[1] = -var2[1];
      var2[5] = -var2[5];
      var2[9] = -var2[9];
      var2[13] = -var2[13];
   }

   static int method15918(Class98 var0, Class91 var1) {
      if(var1 == Class91.aClass91_897) {
         switch(var0.anInt995 * -960308681) {
         case 0:
            return 6410;
         case 1:
         case 4:
         case 8:
         default:
            throw new IllegalArgumentException();
         case 2:
            return '\u83f3';
         case 3:
            return 6407;
         case 5:
            return 6406;
         case 6:
            return '\u83f1';
         case 7:
            return 6409;
         case 9:
            return 6408;
         }
      } else if(var1 == Class91.aClass91_899) {
         switch(var0.anInt995 * -960308681) {
         case 0:
            return '\u8d7b';
         case 1:
            return '\u81a5';
         case 2:
         case 4:
         case 6:
         case 8:
         default:
            throw new IllegalArgumentException();
         case 3:
            return '\u8054';
         case 5:
            return '\u803e';
         case 7:
            return '\u8042';
         case 9:
            return '\u805b';
         }
      } else if(var1 == Class91.aClass91_901) {
         switch(var0.anInt995 * -960308681) {
         case 1:
            return '\u81a6';
         default:
            throw new IllegalArgumentException();
         }
      } else if(var1 == Class91.aClass91_903) {
         switch(var0.anInt995 * -960308681) {
         case 0:
            return '\u881f';
         case 1:
         case 2:
         case 4:
         case 6:
         case 8:
         default:
            throw new IllegalArgumentException();
         case 3:
            return '\u881b';
         case 5:
            return '\u881c';
         case 7:
            return '\u881e';
         case 9:
            return '\u881a';
         }
      } else if(var1 == Class91.aClass91_902) {
         switch(var0.anInt995 * -960308681) {
         case 0:
            return '\u8819';
         case 1:
         case 2:
         case 4:
         case 6:
         case 8:
         default:
            throw new IllegalArgumentException();
         case 3:
            return '\u8815';
         case 5:
            return '\u8816';
         case 7:
            return '\u8818';
         case 9:
            return '\u8814';
         }
      } else {
         throw new IllegalArgumentException();
      }
   }

   void method15223() {
      if(this.aBool9616) {
         OpenGL.glEnable(2929);
      } else {
         OpenGL.glDisable(2929);
      }

   }

   final synchronized void method15919(int var1) {
      Class225 var2 = new Class225();
      var2.aLong2606 = (long)var1 * -641052250121656953L;
      this.aClass456_10334.method7712(var2, (byte)34);
   }

   void method15225() {
      if(this.aBool9616) {
         OpenGL.glEnable(2929);
      } else {
         OpenGL.glDisable(2929);
      }

   }

   void method15226() {
      OpenGL.glDepthMask(this.aBool9713 && this.aBool9691);
   }

   void method15278() {
      if(this.aBool9685 && !this.aBool9630) {
         OpenGL.glEnable(2896);
      } else {
         OpenGL.glDisable(2896);
      }

   }

   public final void method14993(Class374 var1, int var2, int var3) {
      byte var4;
      int var5;
      if(var1 == Class374.aClass374_4671) {
         var4 = 1;
         var5 = var3 * 2;
      } else if(var1 == Class374.aClass374_4668) {
         var4 = 3;
         var5 = var3 + 1;
      } else if(var1 == Class374.aClass374_4670) {
         var4 = 4;
         var5 = var3 * 3;
      } else if(var1 == Class374.aClass374_4667) {
         var4 = 6;
         var5 = var3 + 2;
      } else if(var1 == Class374.aClass374_4672) {
         var4 = 5;
         var5 = var3 + 2;
      } else {
         var4 = 0;
         var5 = var3;
      }

      OpenGL.glDrawArrays(var4, var2, var5);
   }

   void method15095() {
      this.aFloatArray10340[0] = this.aFloat9760 * this.aFloat9701;
      this.aFloatArray10340[1] = this.aFloat9760 * this.aFloat9702;
      this.aFloatArray10340[2] = this.aFloat9760 * this.aFloat9703;
      this.aFloatArray10340[3] = 1.0F;
      OpenGL.glLightModelfv(2899, this.aFloatArray10340, 0);
   }

   public Interface7 method11675(int var1, int var2, Class98 var3, Class91 var4, int var5) {
      return new Class262(this, var3, var4, var1, var2, var5);
   }

   void method15229() {
      this.aFloatArray10340[0] = this.aFloat9705 * this.aFloat9701;
      this.aFloatArray10340[1] = this.aFloat9705 * this.aFloat9702;
      this.aFloatArray10340[2] = this.aFloat9705 * this.aFloat9703;
      this.aFloatArray10340[3] = 1.0F;
      OpenGL.glLightfv(16384, 4609, this.aFloatArray10340, 0);
      this.aFloatArray10340[0] = -this.aFloat9706 * this.aFloat9701;
      this.aFloatArray10340[1] = -this.aFloat9706 * this.aFloat9702;
      this.aFloatArray10340[2] = -this.aFloat9706 * this.aFloat9703;
      this.aFloatArray10340[3] = 1.0F;
      OpenGL.glLightfv(16385, 4609, this.aFloatArray10340, 0);
   }

   void method15186() {
      if(this.aBool9783) {
         OpenGL.glEnable(3089);
      } else {
         OpenGL.glDisable(3089);
      }

   }

   void method15171() {
      OpenGL.glMatrixMode(5888);
      OpenGL.glLoadMatrixf(this.aClass317_9766.aFloatArray4000, 0);
      OpenGL.glLightfv(16384, 4611, this.aFloatArray9712, 0);
      OpenGL.glLightfv(16385, 4611, this.aFloatArray9697, 0);
   }

   public float method14983() {
      return 0.0F;
   }

   void method15037() {
      OpenGL.glMatrixMode(5888);
      OpenGL.glLoadMatrixf(this.aClass317_9766.aFloatArray4000, 0);

      int var1;
      for(var1 = 0; var1 < this.anInt9709; ++var1) {
         Class225_Sub40 var2 = this.aClass225_Sub40Array9719[var1];
         int var3 = var2.method14107(-1901943802);
         int var4 = 16386 + var1;
         float var5 = var2.method14110(-490987360) / 255.0F;
         this.aFloatArray10340[0] = (float)var2.method14103(1399941151);
         this.aFloatArray10340[1] = (float)var2.method14104(-1444300795);
         this.aFloatArray10340[2] = (float)var2.method14105((byte)43);
         this.aFloatArray10340[3] = 1.0F;
         OpenGL.glLightfv(var4, 4611, this.aFloatArray10340, 0);
         this.aFloatArray10340[0] = (float)(var3 >> 16 & 255) * var5;
         this.aFloatArray10340[1] = (float)(var3 >> 8 & 255) * var5;
         this.aFloatArray10340[2] = (float)(var3 & 255) * var5;
         this.aFloatArray10340[3] = 1.0F;
         OpenGL.glLightfv(var4, 4609, this.aFloatArray10340, 0);
         OpenGL.glLightf(var4, 4617, 1.0F / (float)(var2.method14113(1016588262) * var2.method14113(1043757004)));
         OpenGL.glEnable(var4);
      }

      while(var1 < this.anInt9708) {
         OpenGL.glDisable(16386 + var1);
         ++var1;
      }

   }

   public Class103 method15233(String var1) {
      byte[] var2 = this.method15902(var1);
      if(var2 == null) {
         return null;
      } else {
         Class28 var3 = this.method14970(var2);
         return new Class103_Sub1(this, var3);
      }
   }

   void method15234() {}

   void method15034() {}

   void method15112() {
      OpenGL.glDepthFunc(515);
      OpenGL.glEnable(2884);
      OpenGL.glCullFace(1029);
      OpenGL.glClearDepth(1.0F);
      OpenGL.glAlphaFunc(516, 0.0F);
      OpenGL.glPolygonMode(1028, 6914);

      for(int var1 = this.anInt9764 - 1; var1 >= 0; --var1) {
         OpenGL.glActiveTexture('\u84c0' + var1);
         OpenGL.glTexEnvi(8960, 8704, '\u8570');
         OpenGL.glTexEnvi(8960, '\u8571', 8448);
         OpenGL.glTexEnvi(8960, '\u8582', '\u8576');
         OpenGL.glTexEnvi(8960, '\u8572', 8448);
         OpenGL.glTexEnvi(8960, '\u858a', '\u8576');
      }

      OpenGL.glTexEnvi(8960, '\u858a', '\u8578');
      OpenGL.glShadeModel(7425);
      OpenGL.glMatrixMode(5888);
      OpenGL.glLoadIdentity();
      OpenGL.glColorMaterial(1028, 5634);
      OpenGL.glEnable(2903);
      float[] var4 = new float[]{0.0F, 0.0F, 0.0F, 1.0F};

      for(int var2 = 0; var2 < 8; ++var2) {
         int var3 = 16384 + var2;
         OpenGL.glLightfv(var3, 4608, var4, 0);
         OpenGL.glLightf(var3, 4615, 0.0F);
         OpenGL.glLightf(var3, 4616, 0.0F);
      }

      OpenGL.glFogf(2914, 0.95F);
      OpenGL.glFogi(2917, 9729);
      OpenGL.glHint(3156, 4353);
      this.anOpenGL10338.setSwapInterval(0);
      super.method15112();
   }

   final synchronized void method15920(long var1) {
      Class225 var3 = new Class225();
      var3.aLong2606 = var1 * -641052250121656953L;
      this.aClass456_10335.method7712(var3, (byte)41);
   }

   boolean method15321(Class98 var1, Class91 var2) {
      return this.aBool9769;
   }

   Interface33 method15163(Class98 var1, int var2, int var3, boolean var4, byte[] var5, int var6, int var7) {
      if(!this.aBool10328 && (!Class75.method1618(var2, 98312473) || !Class75.method1618(var3, 98312473))) {
         if(this.aBool10353) {
            return new Class275_Sub2(this, var1, var2, var3, var5, var6, var7);
         } else {
            Class275_Sub1 var8 = new Class275_Sub1(this, var1, Class91.aClass91_897, Class468.method7880(var2, (byte)-61), Class468.method7880(var3, (byte)-14));
            var8.method205(0, 0, var2, var3, var5, var1, var6, var7);
            return var8;
         }
      } else {
         return new Class275_Sub1(this, var1, var2, var3, var4, var5, var6, var7);
      }
   }

   Interface33 method15242(Class98 var1, int var2, int var3, boolean var4, byte[] var5, int var6, int var7) {
      if(!this.aBool10328 && (!Class75.method1618(var2, 98312473) || !Class75.method1618(var3, 98312473))) {
         if(this.aBool10353) {
            return new Class275_Sub2(this, var1, var2, var3, var5, var6, var7);
         } else {
            Class275_Sub1 var8 = new Class275_Sub1(this, var1, Class91.aClass91_897, Class468.method7880(var2, (byte)-34), Class468.method7880(var3, (byte)-3));
            var8.method205(0, 0, var2, var3, var5, var1, var6, var7);
            return var8;
         }
      } else {
         return new Class275_Sub1(this, var1, var2, var3, var4, var5, var6, var7);
      }
   }

   public float method15315() {
      return 0.0F;
   }

   Interface33 method15243(Class98 var1, int var2, int var3, boolean var4, byte[] var5, int var6, int var7) {
      if(!this.aBool10328 && (!Class75.method1618(var2, 98312473) || !Class75.method1618(var3, 98312473))) {
         if(this.aBool10353) {
            return new Class275_Sub2(this, var1, var2, var3, var5, var6, var7);
         } else {
            Class275_Sub1 var8 = new Class275_Sub1(this, var1, Class91.aClass91_897, Class468.method7880(var2, (byte)-50), Class468.method7880(var3, (byte)-43));
            var8.method205(0, 0, var2, var3, var5, var1, var6, var7);
            return var8;
         }
      } else {
         return new Class275_Sub1(this, var1, var2, var3, var4, var5, var6, var7);
      }
   }

   void method15236() {
      if(this.aBool9733) {
         OpenGL.glEnable(16384);
         OpenGL.glEnable(16385);
      } else {
         OpenGL.glDisable(16384);
         OpenGL.glDisable(16385);
      }

   }

   public void method15305(int var1, Interface35 var2) {
      this.aClass258_Sub2Array10356[var1] = (Class258_Sub2)var2;
   }

   final void method15026(int var1, Class351 var2, boolean var3) {
      OpenGL.glTexEnvi(8960, '\u8588' + var1, method15903(var2));
      OpenGL.glTexEnvi(8960, '\u8598' + var1, var3?771:770);
   }

   Class341 method15076(Class348[] var1) {
      return new Class341_Sub2(var1);
   }

   Interface3 method15248(Class98 var1, int var2, int var3, int var4, boolean var5, byte[] var6) {
      return new Class275_Sub3(this, var1, var2, var3, var4, var5, var6);
   }

   final void method15062() {
      this.aFloatArray10340[0] = (float)(this.anInt9720 & 16711680) / 1.671168E7F;
      this.aFloatArray10340[1] = (float)(this.anInt9720 & '\uff00') / 65280.0F;
      this.aFloatArray10340[2] = (float)(this.anInt9720 & 255) / 255.0F;
      this.aFloatArray10340[3] = (float)(this.anInt9720 >>> 24) / 255.0F;
      OpenGL.glTexEnvfv(8960, 8705, this.aFloatArray10340, 0);
   }

   Interface36 method15021(Class98 var1, Class91 var2, int var3, int var4) {
      return (Interface36)(!this.aBool10328 && (!Class75.method1618(var3, 98312473) || !Class75.method1618(var4, 98312473))?(this.aBool10353?new Class275_Sub2(this, var1, var2, var3, var4):new Class275_Sub1(this, var1, var2, Class468.method7880(var3, (byte)-4), Class468.method7880(var4, (byte)-96))):new Class275_Sub1(this, var1, var2, var3, var4));
   }

   Interface36 method15250(Class98 var1, Class91 var2, int var3, int var4) {
      return (Interface36)(!this.aBool10328 && (!Class75.method1618(var3, 98312473) || !Class75.method1618(var4, 98312473))?(this.aBool10353?new Class275_Sub2(this, var1, var2, var3, var4):new Class275_Sub1(this, var1, var2, Class468.method7880(var3, (byte)-18), Class468.method7880(var4, (byte)-45))):new Class275_Sub1(this, var1, var2, var3, var4));
   }

   public void method15253() {
      int var1 = this.anIntArray10344[this.anInt9625];
      if(var1 != 0) {
         this.anIntArray10344[this.anInt9625] = 0;
         OpenGL.glBindTexture(var1, 0);
         OpenGL.glDisable(var1);
      }

   }

   void method15164(int var1) {
      if(!this.aBool10355) {
         OpenGL.glPolygonMode(1028, (var1 & 2) != 0?6913:6914);
      }

   }

   final void method15261(int var1, Class351 var2, boolean var3, boolean var4) {
      OpenGL.glTexEnvi(8960, '\u8580' + var1, method15903(var2));
      if(var3) {
         OpenGL.glTexEnvi(8960, '\u8590' + var1, var4?771:770);
      } else {
         OpenGL.glTexEnvi(8960, '\u8590' + var1, var4?769:768);
      }

   }

   Class151_Sub2 method11545(Canvas var1, int var2, int var3) {
      return new Class151_Sub2_Sub2_Sub1(this, var1);
   }

   Interface33 method15245(int var1, int var2, boolean var3, int[] var4, int var5, int var6) {
      if(!this.aBool10328 && (!Class75.method1618(var1, 98312473) || !Class75.method1618(var2, 98312473))) {
         if(this.aBool10353) {
            return new Class275_Sub2(this, var1, var2, var4, var5, var6);
         } else {
            Class275_Sub1 var7 = new Class275_Sub1(this, Class98.aClass98_992, Class91.aClass91_897, Class468.method7880(var1, (byte)-12), Class468.method7880(var2, (byte)-105));
            var7.method200(0, 0, var1, var2, var4, var5, var6);
            return var7;
         }
      } else {
         return new Class275_Sub1(this, var1, var2, var3, var4, var5, var6);
      }
   }

   final void method15147(int var1, Class351 var2, boolean var3) {
      OpenGL.glTexEnvi(8960, '\u8588' + var1, method15903(var2));
      OpenGL.glTexEnvi(8960, '\u8598' + var1, var3?771:770);
   }

   final void method15114() {
      this.aFloatArray10340[0] = (float)(this.anInt9720 & 16711680) / 1.671168E7F;
      this.aFloatArray10340[1] = (float)(this.anInt9720 & '\uff00') / 65280.0F;
      this.aFloatArray10340[2] = (float)(this.anInt9720 & 255) / 255.0F;
      this.aFloatArray10340[3] = (float)(this.anInt9720 >>> 24) / 255.0F;
      OpenGL.glTexEnvfv(8960, 8705, this.aFloatArray10340, 0);
   }

   void method15270() {
      OpenGL.glActiveTexture('\u84c0' + this.anInt9625);
   }

   void method15271() {
      OpenGL.glActiveTexture('\u84c0' + this.anInt9625);
   }

   void method15272() {
      OpenGL.glTexEnvi(8960, '\u8571', method15904(this.aClass367Array9718[this.anInt9625]));
   }

   void method15273() {
      OpenGL.glTexEnvi(8960, '\u8571', method15904(this.aClass367Array9718[this.anInt9625]));
   }

   void method15110() {
      OpenGL.glTexEnvi(8960, '\u8572', method15904(this.aClass367Array9743[this.anInt9625]));
   }

   void method15024() {
      if(this.aBool9616) {
         OpenGL.glEnable(2929);
      } else {
         OpenGL.glDisable(2929);
      }

   }

   void method15216(int var1) {
      OpenGL.glColorMask((var1 & 1) != 0, (var1 & 2) != 0, (var1 & 4) != 0, (var1 & 8) != 0);
   }

   void method15029(int var1) {
      OpenGL.glColorMask((var1 & 1) != 0, (var1 & 2) != 0, (var1 & 4) != 0, (var1 & 8) != 0);
   }

   void method14976(int var1) {
      OpenGL.glColorMask((var1 & 1) != 0, (var1 & 2) != 0, (var1 & 4) != 0, (var1 & 8) != 0);
   }

   void method15280() {
      byte var1 = 0;
      byte var2 = 0;
      if(this.anInt9742 == 0) {
         var1 = 0;
         var2 = 0;
      } else if(this.anInt9742 == 1) {
         var1 = 1;
         var2 = 0;
      } else if(this.anInt9742 == 2) {
         var1 = 1;
         var2 = 1;
      }

      if(this.aClass57_9674 == Class57.aClass57_536) {
         OpenGL.glBlendFuncSeparate(770, 771, var1, var2);
      } else if(this.aClass57_9674 == Class57.aClass57_533) {
         OpenGL.glBlendFuncSeparate(1, 1, var1, var2);
      } else if(this.aClass57_9674 == Class57.aClass57_534) {
         OpenGL.glBlendFuncSeparate(774, 1, var1, var2);
      }

   }

   void method15132() {
      byte var1 = 0;
      byte var2 = 0;
      if(this.anInt9742 == 0) {
         var1 = 0;
         var2 = 0;
      } else if(this.anInt9742 == 1) {
         var1 = 1;
         var2 = 0;
      } else if(this.anInt9742 == 2) {
         var1 = 1;
         var2 = 1;
      }

      if(this.aClass57_9674 == Class57.aClass57_536) {
         OpenGL.glBlendFuncSeparate(770, 771, var1, var2);
      } else if(this.aClass57_9674 == Class57.aClass57_533) {
         OpenGL.glBlendFuncSeparate(1, 1, var1, var2);
      } else if(this.aClass57_9674 == Class57.aClass57_534) {
         OpenGL.glBlendFuncSeparate(774, 1, var1, var2);
      }

   }

   void method15282() {
      byte var1 = 0;
      byte var2 = 0;
      if(this.anInt9742 == 0) {
         var1 = 0;
         var2 = 0;
      } else if(this.anInt9742 == 1) {
         var1 = 1;
         var2 = 0;
      } else if(this.anInt9742 == 2) {
         var1 = 1;
         var2 = 1;
      }

      if(this.aClass57_9674 == Class57.aClass57_536) {
         OpenGL.glBlendFuncSeparate(770, 771, var1, var2);
      } else if(this.aClass57_9674 == Class57.aClass57_533) {
         OpenGL.glBlendFuncSeparate(1, 1, var1, var2);
      } else if(this.aClass57_9674 == Class57.aClass57_534) {
         OpenGL.glBlendFuncSeparate(774, 1, var1, var2);
      }

   }

   public void method15148(Class317 var1, Class317 var2, Class317 var3) {
      OpenGL.glMatrixMode(5888);
      this.aClass317_9649.method5611(var1, var2);
      OpenGL.glLoadMatrixf(this.aClass317_9649.aFloatArray4000, 0);
      OpenGL.glMatrixMode(5889);
      OpenGL.glLoadMatrixf(var3.aFloatArray4000, 0);
   }

   void method15116() {
      if(this.aBool9755) {
         OpenGL.glEnable(3042);
      } else {
         OpenGL.glDisable(3042);
      }

   }

   void method15285() {
      if(this.aBool9755) {
         OpenGL.glEnable(3042);
      } else {
         OpenGL.glDisable(3042);
      }

   }

   void method15292() {
      this.aFloat9752 = this.aFloat9675 - (float)this.anInt9750;
      this.aFloat9751 = this.aFloat9752 - (float)this.anInt9623;
      if(this.aFloat9751 < this.aFloat9696) {
         this.aFloat9751 = this.aFloat9696;
      }

      if(this.aBool9681) {
         OpenGL.glFogf(2915, this.aFloat9751);
         OpenGL.glFogf(2916, this.aFloat9752);
         this.aFloatArray10340[0] = (float)(this.anInt9748 & 16711680) / 1.671168E7F;
         this.aFloatArray10340[1] = (float)(this.anInt9748 & '\uff00') / 65280.0F;
         this.aFloatArray10340[2] = (float)(this.anInt9748 & 255) / 255.0F;
         OpenGL.glFogfv(2918, this.aFloatArray10340, 0);
      }

   }

   void method15293() {
      if(this.aBool9749 && this.aBool9746 && this.anInt9623 >= 0) {
         OpenGL.glEnable(2912);
      } else {
         OpenGL.glDisable(2912);
      }

   }

   static final int method15921(Class351 var0) {
      if(var0 == Class351.aClass351_4455) {
         return 5890;
      } else if(var0 == Class351.aClass351_4457) {
         return '\u8577';
      } else if(var0 == Class351.aClass351_4456) {
         return '\u8578';
      } else if(var0 == Class351.aClass351_4458) {
         return '\u8576';
      } else {
         throw new IllegalArgumentException();
      }
   }

   void method15184() {
      if(this.aClass151_7359 != null) {
         int var1 = this.anInt9688 + this.anInt9678;
         int var2 = this.anInt9689 + this.aClass151_7359.method2742() - this.anInt9745;
         int var3 = this.anInt9679 - this.anInt9678;
         int var4 = this.anInt9745 - this.anInt9735;
         if(var3 < 0) {
            var3 = 0;
         }

         if(var4 < 0) {
            var4 = 0;
         }

         OpenGL.glScissor(var1, var2, var3, var4);
      }

   }

   void method15294(boolean var1) {
      if(var1) {
         OpenGL.glEnable('\u809d');
      } else {
         OpenGL.glDisable('\u809d');
      }

   }

   final Interface40 method15033(boolean var1) {
      return new Class258_Sub1(this, Class91.aClass91_899, var1);
   }

   final Interface40 method15296(boolean var1) {
      return new Class258_Sub1(this, Class91.aClass91_899, var1);
   }

   final Interface40 method15297(boolean var1) {
      return new Class258_Sub1(this, Class91.aClass91_899, var1);
   }

   public void method15201(Class317 var1) {
      float[] var2 = var1.aFloatArray4000;
      var2[1] = -var2[1];
      var2[5] = -var2[5];
      var2[9] = -var2[9];
      var2[13] = -var2[13];
   }

   static int method15922(Class98 var0, Class91 var1) {
      if(var1 == Class91.aClass91_897) {
         switch(var0.anInt995 * -960308681) {
         case 0:
            return 6410;
         case 1:
         case 4:
         case 8:
         default:
            throw new IllegalArgumentException();
         case 2:
            return '\u83f3';
         case 3:
            return 6407;
         case 5:
            return 6406;
         case 6:
            return '\u83f1';
         case 7:
            return 6409;
         case 9:
            return 6408;
         }
      } else if(var1 == Class91.aClass91_899) {
         switch(var0.anInt995 * -960308681) {
         case 0:
            return '\u8d7b';
         case 1:
            return '\u81a5';
         case 2:
         case 4:
         case 6:
         case 8:
         default:
            throw new IllegalArgumentException();
         case 3:
            return '\u8054';
         case 5:
            return '\u803e';
         case 7:
            return '\u8042';
         case 9:
            return '\u805b';
         }
      } else if(var1 == Class91.aClass91_901) {
         switch(var0.anInt995 * -960308681) {
         case 1:
            return '\u81a6';
         default:
            throw new IllegalArgumentException();
         }
      } else if(var1 == Class91.aClass91_903) {
         switch(var0.anInt995 * -960308681) {
         case 0:
            return '\u881f';
         case 1:
         case 2:
         case 4:
         case 6:
         case 8:
         default:
            throw new IllegalArgumentException();
         case 3:
            return '\u881b';
         case 5:
            return '\u881c';
         case 7:
            return '\u881e';
         case 9:
            return '\u881a';
         }
      } else if(var1 == Class91.aClass91_902) {
         switch(var0.anInt995 * -960308681) {
         case 0:
            return '\u8819';
         case 1:
         case 2:
         case 4:
         case 6:
         case 8:
         default:
            throw new IllegalArgumentException();
         case 3:
            return '\u8815';
         case 5:
            return '\u8816';
         case 7:
            return '\u8818';
         case 9:
            return '\u8814';
         }
      } else {
         throw new IllegalArgumentException();
      }
   }

   Class341 method15177(Class348[] var1) {
      return new Class341_Sub2(var1);
   }

   Class341 method15300(Class348[] var1) {
      return new Class341_Sub2(var1);
   }

   Class341 method15301(Class348[] var1) {
      return new Class341_Sub2(var1);
   }

   public void method15302(Class341 var1) {
      Class348[] var2 = var1.aClass348Array4375;
      int var3 = 0;
      boolean var4 = false;
      boolean var5 = false;
      boolean var6 = false;

      int var7;
      for(var7 = 0; var7 < var2.length; ++var7) {
         Class348 var8 = var2[var7];
         Class258_Sub2 var9 = this.aClass258_Sub2Array10356[var7];
         int var10 = 0;
         int var11 = var9.method13113();
         long var12 = var9.method4651();
         var9.method4648();

         for(int var14 = 0; var14 < var8.method6350(); ++var14) {
            Class347 var15 = var8.method6347(var14);
            switch(var15.anInt4437) {
            case 0:
               OpenGL.glVertexPointer(3, 5126, var11, var12 + (long)var10);
               var6 = true;
            case 1:
            case 4:
            case 5:
            case 7:
            default:
               break;
            case 2:
               OpenGL.glClientActiveTexture('\u84c0' + var3++);
               OpenGL.glTexCoordPointer(3, 5126, var11, var12 + (long)var10);
               break;
            case 3:
               OpenGL.glClientActiveTexture('\u84c0' + var3++);
               OpenGL.glTexCoordPointer(1, 5126, var11, var12 + (long)var10);
               break;
            case 6:
               OpenGL.glColorPointer(4, 5121, var11, var12 + (long)var10);
               var4 = true;
               break;
            case 8:
               OpenGL.glClientActiveTexture('\u84c0' + var3++);
               OpenGL.glTexCoordPointer(4, 5126, var11, var12 + (long)var10);
               break;
            case 9:
               OpenGL.glClientActiveTexture('\u84c0' + var3++);
               OpenGL.glTexCoordPointer(2, 5126, var11, var12 + (long)var10);
               break;
            case 10:
               OpenGL.glNormalPointer(5126, var11, var12 + (long)var10);
               var5 = true;
            }

            var10 += var15.anInt4431;
         }
      }

      if(this.aBool10347 != var6) {
         if(var6) {
            OpenGL.glEnableClientState('\u8074');
         } else {
            OpenGL.glDisableClientState('\u8074');
         }

         this.aBool10347 = var6;
      }

      if(this.aBool10345 != var5) {
         if(var5) {
            OpenGL.glEnableClientState('\u8075');
         } else {
            OpenGL.glDisableClientState('\u8075');
         }

         this.aBool10345 = var5;
      }

      if(this.aBool10339 != var4) {
         if(var4) {
            OpenGL.glEnableClientState('\u8076');
         } else {
            OpenGL.glDisableClientState('\u8076');
         }

         this.aBool10339 = var4;
      }

      if(this.anInt10341 < var3) {
         for(var7 = this.anInt10341; var7 < var3; ++var7) {
            OpenGL.glClientActiveTexture('\u84c0' + var7);
            OpenGL.glEnableClientState('\u8078');
         }

         this.anInt10341 = var3;
      } else if(this.anInt10341 > var3) {
         for(var7 = var3; var7 < this.anInt10341; ++var7) {
            OpenGL.glClientActiveTexture('\u84c0' + var7);
            OpenGL.glDisableClientState('\u8078');
         }

         this.anInt10341 = var3;
      }

   }

   Class341 method15299(Class348[] var1) {
      return new Class341_Sub2(var1);
   }

   void method15188() {
      if(this.aBool9783) {
         OpenGL.glEnable(3089);
      } else {
         OpenGL.glDisable(3089);
      }

   }

   Interface37 method15247(int var1, boolean var2, int[][] var3) {
      return new Class275_Sub4(this, var1, var2, var3);
   }

   Interface33 method15099(Class98 var1, int var2, int var3, boolean var4, float[] var5, int var6, int var7) {
      if(!this.aBool10328 && (!Class75.method1618(var2, 98312473) || !Class75.method1618(var3, 98312473))) {
         if(this.aBool10353) {
            return new Class275_Sub2(this, var1, var2, var3, var5, var6, var7);
         } else {
            Class275_Sub1 var8 = new Class275_Sub1(this, var1, Class91.aClass91_902, Class468.method7880(var2, (byte)-34), Class468.method7880(var3, (byte)-108));
            var8.method13067(0, 0, var2, var3, var5, var1, var6, var7);
            return var8;
         }
      } else {
         return new Class275_Sub1(this, var1, var2, var3, var4, var5, var6, var7);
      }
   }

   void method15307(Interface40 var1) {
      this.aClass258_Sub1_10351 = (Class258_Sub1)var1;
      this.aClass258_Sub1_10351.method4648();
   }

   public final void method15104(Class374 var1, int var2, int var3) {
      byte var4;
      int var5;
      if(var1 == Class374.aClass374_4671) {
         var4 = 1;
         var5 = var3 * 2;
      } else if(var1 == Class374.aClass374_4668) {
         var4 = 3;
         var5 = var3 + 1;
      } else if(var1 == Class374.aClass374_4670) {
         var4 = 4;
         var5 = var3 * 3;
      } else if(var1 == Class374.aClass374_4667) {
         var4 = 6;
         var5 = var3 + 2;
      } else if(var1 == Class374.aClass374_4672) {
         var4 = 5;
         var5 = var3 + 2;
      } else {
         var4 = 0;
         var5 = var3;
      }

      OpenGL.glDrawArrays(var4, var2, var5);
   }

   final void method15317(Interface40 var1, Class374 var2, int var3, int var4, int var5, int var6) {
      byte var7;
      int var8;
      if(var2 == Class374.aClass374_4671) {
         var7 = 1;
         var8 = var6 * 2;
      } else if(var2 == Class374.aClass374_4668) {
         var7 = 3;
         var8 = var6 + 1;
      } else if(var2 == Class374.aClass374_4670) {
         var7 = 4;
         var8 = var6 * 3;
      } else if(var2 == Class374.aClass374_4667) {
         var7 = 6;
         var8 = var6 + 2;
      } else if(var2 == Class374.aClass374_4672) {
         var7 = 5;
         var8 = var6 + 2;
      } else {
         var7 = 0;
         var8 = var6;
      }

      Class91 var9 = var1.method236();
      Class258_Sub1 var10 = (Class258_Sub1)var1;
      var10.method4648();
      OpenGL.glDrawElements(var7, var8, method15912(var9), var10.method4651() + (long)(var5 * var9.anInt906 * -2107221975));
   }

   public final void method15318(Class374 var1, int var2, int var3, int var4, int var5) {
      byte var6;
      int var7;
      if(var1 == Class374.aClass374_4671) {
         var6 = 1;
         var7 = var5 * 2;
      } else if(var1 == Class374.aClass374_4668) {
         var6 = 3;
         var7 = var5 + 1;
      } else if(var1 == Class374.aClass374_4670) {
         var6 = 4;
         var7 = var5 * 3;
      } else if(var1 == Class374.aClass374_4667) {
         var6 = 6;
         var7 = var5 + 2;
      } else if(var1 == Class374.aClass374_4672) {
         var6 = 5;
         var7 = var5 + 2;
      } else {
         var6 = 0;
         var7 = var5;
      }

      Class91 var8 = this.aClass258_Sub1_10351.method236();
      OpenGL.glDrawElements(var6, var7, method15912(var8), this.aClass258_Sub1_10351.method4651() + (long)(var4 * var8.anInt906 * -2107221975));
   }

   public final void method15319(Class374 var1, int var2, int var3, int var4, int var5) {
      byte var6;
      int var7;
      if(var1 == Class374.aClass374_4671) {
         var6 = 1;
         var7 = var5 * 2;
      } else if(var1 == Class374.aClass374_4668) {
         var6 = 3;
         var7 = var5 + 1;
      } else if(var1 == Class374.aClass374_4670) {
         var6 = 4;
         var7 = var5 * 3;
      } else if(var1 == Class374.aClass374_4667) {
         var6 = 6;
         var7 = var5 + 2;
      } else if(var1 == Class374.aClass374_4672) {
         var6 = 5;
         var7 = var5 + 2;
      } else {
         var6 = 0;
         var7 = var5;
      }

      Class91 var8 = this.aClass258_Sub1_10351.method236();
      OpenGL.glDrawElements(var6, var7, method15912(var8), this.aClass258_Sub1_10351.method4651() + (long)(var4 * var8.anInt906 * -2107221975));
   }

   public final void method14996(Class374 var1, int var2, int var3, int var4, int var5) {
      byte var6;
      int var7;
      if(var1 == Class374.aClass374_4671) {
         var6 = 1;
         var7 = var5 * 2;
      } else if(var1 == Class374.aClass374_4668) {
         var6 = 3;
         var7 = var5 + 1;
      } else if(var1 == Class374.aClass374_4670) {
         var6 = 4;
         var7 = var5 * 3;
      } else if(var1 == Class374.aClass374_4667) {
         var6 = 6;
         var7 = var5 + 2;
      } else if(var1 == Class374.aClass374_4672) {
         var6 = 5;
         var7 = var5 + 2;
      } else {
         var6 = 0;
         var7 = var5;
      }

      Class91 var8 = this.aClass258_Sub1_10351.method236();
      OpenGL.glDrawElements(var6, var7, method15912(var8), this.aClass258_Sub1_10351.method4651() + (long)(var4 * var8.anInt906 * -2107221975));
   }

   void method15322(int var1) {
      if(!this.aBool10355) {
         OpenGL.glPolygonMode(1028, (var1 & 2) != 0?6913:6914);
      }

   }

   static final int method15923(Class91 var0) {
      switch(var0.anInt905 * -1560869161) {
      case 0:
         return 5125;
      case 1:
      default:
         return 5121;
      case 2:
         return 5121;
      case 3:
         return 5126;
      case 4:
         return 5122;
      case 5:
         return 5123;
      case 6:
         return 5120;
      case 7:
         return 5124;
      case 8:
         return 5131;
      }
   }

   void method15323(int var1) {
      if(!this.aBool10355) {
         OpenGL.glPolygonMode(1028, (var1 & 2) != 0?6913:6914);
      }

   }

   void method15324(int var1) {
      if(!this.aBool10355) {
         OpenGL.glPolygonMode(1028, (var1 & 2) != 0?6913:6914);
      }

   }

   void method15325(int var1) {
      if(!this.aBool10355) {
         OpenGL.glPolygonMode(1028, (var1 & 2) != 0?6913:6914);
      }

   }

   public void method11554(boolean var1) {}

   void method15328() {
      OpenGL.glMatrixMode(5888);
      OpenGL.glLoadMatrixf(this.aClass317_9766.aFloatArray4000, 0);

      int var1;
      for(var1 = 0; var1 < this.anInt9709; ++var1) {
         Class225_Sub40 var2 = this.aClass225_Sub40Array9719[var1];
         int var3 = var2.method14107(-2063065667);
         int var4 = 16386 + var1;
         float var5 = var2.method14110(-1056205662) / 255.0F;
         this.aFloatArray10340[0] = (float)var2.method14103(-1435048972);
         this.aFloatArray10340[1] = (float)var2.method14104(-2007799831);
         this.aFloatArray10340[2] = (float)var2.method14105((byte)33);
         this.aFloatArray10340[3] = 1.0F;
         OpenGL.glLightfv(var4, 4611, this.aFloatArray10340, 0);
         this.aFloatArray10340[0] = (float)(var3 >> 16 & 255) * var5;
         this.aFloatArray10340[1] = (float)(var3 >> 8 & 255) * var5;
         this.aFloatArray10340[2] = (float)(var3 & 255) * var5;
         this.aFloatArray10340[3] = 1.0F;
         OpenGL.glLightfv(var4, 4609, this.aFloatArray10340, 0);
         OpenGL.glLightf(var4, 4617, 1.0F / (float)(var2.method14113(1701514751) * var2.method14113(2091198068)));
         OpenGL.glEnable(var4);
      }

      while(var1 < this.anInt9708) {
         OpenGL.glDisable(16386 + var1);
         ++var1;
      }

   }

   void method15118() {
      if(this.aBool9749 && this.aBool9746 && this.anInt9623 >= 0) {
         OpenGL.glEnable(2912);
      } else {
         OpenGL.glDisable(2912);
      }

   }

   void method15224() {
      if(this.aBool9616) {
         OpenGL.glEnable(2929);
      } else {
         OpenGL.glDisable(2929);
      }

   }

   Interface33 method15067(Class98 var1, Class91 var2, int var3, int var4) {
      return this.method15048(var1, var2, var3, var4);
   }

   void method15230() {
      this.aFloatArray10340[0] = this.aFloat9705 * this.aFloat9701;
      this.aFloatArray10340[1] = this.aFloat9705 * this.aFloat9702;
      this.aFloatArray10340[2] = this.aFloat9705 * this.aFloat9703;
      this.aFloatArray10340[3] = 1.0F;
      OpenGL.glLightfv(16384, 4609, this.aFloatArray10340, 0);
      this.aFloatArray10340[0] = -this.aFloat9706 * this.aFloat9701;
      this.aFloatArray10340[1] = -this.aFloat9706 * this.aFloat9702;
      this.aFloatArray10340[2] = -this.aFloat9706 * this.aFloat9703;
      this.aFloatArray10340[3] = 1.0F;
      OpenGL.glLightfv(16385, 4609, this.aFloatArray10340, 0);
   }

   public Class79 method11624(Class79 var1, Class79 var2, float var3, Class79 var4) {
      return var3 < 0.5F?var1:var2;
   }

   void method15333() {
      if(this.aBool9756) {
         OpenGL.glEnable(3008);
      } else {
         OpenGL.glDisable(3008);
      }

   }

   final Interface35 method15334(boolean var1) {
      return new Class258_Sub2(this, var1);
   }

   final Interface35 method15195(boolean var1) {
      return new Class258_Sub2(this, var1);
   }

   byte[] method15924(String var1) {
      return this.method14969("gl", var1);
   }

   byte[] method15925(String var1) {
      return this.method14969("gl", var1);
   }

   static final int method15926(Class367 var0) {
      if(var0 == Class367.aClass367_4609) {
         return 7681;
      } else if(var0 == Class367.aClass367_4610) {
         return 8448;
      } else if(var0 == Class367.aClass367_4613) {
         return '\u8575';
      } else if(var0 == Class367.aClass367_4612) {
         return 260;
      } else if(var0 == Class367.aClass367_4611) {
         return '\u84e7';
      } else {
         throw new IllegalArgumentException();
      }
   }

   public Class79 method11644(Class79 var1, Class79 var2, float var3, Class79 var4) {
      return var3 < 0.5F?var1:var2;
   }

   void method11527() {
      super.method11470();
      if(this.anOpenGL10338 != null) {
         this.anOpenGL10338.method2777();
         this.anOpenGL10338.release();
         this.anOpenGL10338 = null;
      }

   }

   static final int method15927(Class351 var0) {
      if(var0 == Class351.aClass351_4455) {
         return 5890;
      } else if(var0 == Class351.aClass351_4457) {
         return '\u8577';
      } else if(var0 == Class351.aClass351_4456) {
         return '\u8578';
      } else if(var0 == Class351.aClass351_4458) {
         return '\u8576';
      } else {
         throw new IllegalArgumentException();
      }
   }

   public void method11541(boolean var1) {}

   static final int method15928(Class351 var0) {
      if(var0 == Class351.aClass351_4455) {
         return 5890;
      } else if(var0 == Class351.aClass351_4457) {
         return '\u8577';
      } else if(var0 == Class351.aClass351_4456) {
         return '\u8578';
      } else if(var0 == Class351.aClass351_4458) {
         return '\u8576';
      } else {
         throw new IllegalArgumentException();
      }
   }

   static final int method15929(Class351 var0) {
      if(var0 == Class351.aClass351_4455) {
         return 5890;
      } else if(var0 == Class351.aClass351_4457) {
         return '\u8577';
      } else if(var0 == Class351.aClass351_4456) {
         return '\u8578';
      } else if(var0 == Class351.aClass351_4458) {
         return '\u8576';
      } else {
         throw new IllegalArgumentException();
      }
   }

   final synchronized void method15930(int var1) {
      IntVar var2 = new IntVar(var1);
      this.aClass456_10332.method7712(var2, (byte)81);
   }

   void method15183() {
      if(this.aClass151_7359 != null) {
         int var1 = this.anInt9688 + this.anInt9678;
         int var2 = this.anInt9689 + this.aClass151_7359.method2742() - this.anInt9745;
         int var3 = this.anInt9679 - this.anInt9678;
         int var4 = this.anInt9745 - this.anInt9735;
         if(var3 < 0) {
            var3 = 0;
         }

         if(var4 < 0) {
            var4 = 0;
         }

         OpenGL.glScissor(var1, var2, var3, var4);
      }

   }

   public void method15214(Class317 var1, Class317 var2, Class317 var3) {
      OpenGL.glMatrixMode(5888);
      this.aClass317_9649.method5611(var1, var2);
      OpenGL.glLoadMatrixf(this.aClass317_9649.aFloatArray4000, 0);
      OpenGL.glMatrixMode(5889);
      OpenGL.glLoadMatrixf(var3.aFloatArray4000, 0);
   }

   Interface33 method15081(int var1, int var2, boolean var3, int[] var4, int var5, int var6) {
      if(!this.aBool10328 && (!Class75.method1618(var1, 98312473) || !Class75.method1618(var2, 98312473))) {
         if(this.aBool10353) {
            return new Class275_Sub2(this, var1, var2, var4, var5, var6);
         } else {
            Class275_Sub1 var7 = new Class275_Sub1(this, Class98.aClass98_992, Class91.aClass91_897, Class468.method7880(var1, (byte)-10), Class468.method7880(var2, (byte)-105));
            var7.method200(0, 0, var1, var2, var4, var5, var6);
            return var7;
         }
      } else {
         return new Class275_Sub1(this, var1, var2, var3, var4, var5, var6);
      }
   }

   Class151_Sub2 method11619(Canvas var1, int var2, int var3) {
      return new Class151_Sub2_Sub2_Sub1(this, var1);
   }

   final synchronized void method15931(int var1) {
      Class225 var2 = new Class225();
      var2.aLong2606 = (long)var1 * -641052250121656953L;
      this.aClass456_10334.method7712(var2, (byte)91);
   }

   public void method15013(Class317 var1) {
      float[] var2 = var1.aFloatArray4000;
      var2[1] = -var2[1];
      var2[5] = -var2[5];
      var2[9] = -var2[9];
      var2[13] = -var2[13];
   }

   final synchronized void method15932(int var1) {
      Class225 var2 = new Class225();
      var2.aLong2606 = (long)var1 * -641052250121656953L;
      this.aClass456_10334.method7712(var2, (byte)96);
   }

   static final int method15933(Class91 var0) {
      switch(var0.anInt905 * -1560869161) {
      case 0:
         return 5125;
      case 1:
      default:
         return 5121;
      case 2:
         return 5121;
      case 3:
         return 5126;
      case 4:
         return 5122;
      case 5:
         return 5123;
      case 6:
         return 5120;
      case 7:
         return 5124;
      case 8:
         return 5131;
      }
   }

   void method15150() {
      OpenGL.glTexEnvi(8960, '\u8572', method15904(this.aClass367Array9743[this.anInt9625]));
   }

   static int method15934(Class98 var0) {
      switch(var0.anInt995 * -960308681) {
      case 0:
         return 6410;
      case 1:
         return 6402;
      case 2:
      case 4:
      case 6:
      case 8:
      default:
         throw new IllegalStateException();
      case 3:
         return 6407;
      case 5:
         return 6406;
      case 7:
         return 6409;
      case 9:
         return 6408;
      }
   }

   public Interface8 method11659(int var1, int var2, int var3) {
      return new Class262(this, Class98.aClass98_990, Class91.aClass91_901, var1, var2, var3);
   }

   Interface33 method15246(int var1, int var2, boolean var3, int[] var4, int var5, int var6) {
      if(!this.aBool10328 && (!Class75.method1618(var1, 98312473) || !Class75.method1618(var2, 98312473))) {
         if(this.aBool10353) {
            return new Class275_Sub2(this, var1, var2, var4, var5, var6);
         } else {
            Class275_Sub1 var7 = new Class275_Sub1(this, Class98.aClass98_992, Class91.aClass91_897, Class468.method7880(var1, (byte)-121), Class468.method7880(var2, (byte)-123));
            var7.method200(0, 0, var1, var2, var4, var5, var6);
            return var7;
         }
      } else {
         return new Class275_Sub1(this, var1, var2, var3, var4, var5, var6);
      }
   }

   static int method15935(Class98 var0, Class91 var1) {
      if(var1 == Class91.aClass91_897) {
         switch(var0.anInt995 * -960308681) {
         case 0:
            return 6410;
         case 1:
         case 4:
         case 8:
         default:
            throw new IllegalArgumentException();
         case 2:
            return '\u83f3';
         case 3:
            return 6407;
         case 5:
            return 6406;
         case 6:
            return '\u83f1';
         case 7:
            return 6409;
         case 9:
            return 6408;
         }
      } else if(var1 == Class91.aClass91_899) {
         switch(var0.anInt995 * -960308681) {
         case 0:
            return '\u8d7b';
         case 1:
            return '\u81a5';
         case 2:
         case 4:
         case 6:
         case 8:
         default:
            throw new IllegalArgumentException();
         case 3:
            return '\u8054';
         case 5:
            return '\u803e';
         case 7:
            return '\u8042';
         case 9:
            return '\u805b';
         }
      } else if(var1 == Class91.aClass91_901) {
         switch(var0.anInt995 * -960308681) {
         case 1:
            return '\u81a6';
         default:
            throw new IllegalArgumentException();
         }
      } else if(var1 == Class91.aClass91_903) {
         switch(var0.anInt995 * -960308681) {
         case 0:
            return '\u881f';
         case 1:
         case 2:
         case 4:
         case 6:
         case 8:
         default:
            throw new IllegalArgumentException();
         case 3:
            return '\u881b';
         case 5:
            return '\u881c';
         case 7:
            return '\u881e';
         case 9:
            return '\u881a';
         }
      } else if(var1 == Class91.aClass91_902) {
         switch(var0.anInt995 * -960308681) {
         case 0:
            return '\u8819';
         case 1:
         case 2:
         case 4:
         case 6:
         case 8:
         default:
            throw new IllegalArgumentException();
         case 3:
            return '\u8815';
         case 5:
            return '\u8816';
         case 7:
            return '\u8818';
         case 9:
            return '\u8814';
         }
      } else {
         throw new IllegalArgumentException();
      }
   }
}
