/* Class114_Sub2 - Decompiled by JODE
 * Visit http://jode.sourceforge.net/
 */
import jaggl.OpenGL;

public class Class114_Sub2 extends Class114 {
	int[] anIntArray10099;
	static final int anInt10100 = 13;
	Class57_Sub2 aClass57_Sub2_10101;
	Class84_Sub1_Sub1 aClass84_Sub1_Sub1_10102;
	int[] anIntArray10103;
	int anInt10104 = 0;
	int anInt10105 = 0;
	int anInt10106 = 0;
	static final int anInt10107 = 35632;
	float[] aFloatArray10108;
	String aString10109;
	static float[] aFloatArray10110;
	float[] aFloatArray10111;
	static final int anInt10112 = 35633;
	float[] aFloatArray10113;
	float[] aFloatArray10114;
	static int[] anIntArray10115;
	boolean aBool10116 = false;
	String aString10117;
	static boolean $assertionsDisabled = !Class114_Sub2.class.desiredAssertionStatus();

	int method16344(int i, String string, String string_0_) {
		if (string == null)
			return 0;
		int i_1_ = OpenGL.glCreateShader(i);
		OpenGL.glShaderSource(i_1_, string);
		OpenGL.glCompileShader(i_1_);
		OpenGL.glGetShaderiv(i_1_, 35713, anIntArray10115, 0);
		if (anIntArray10115[0] == 0) {
			OpenGL.glDeleteShader(i_1_);
			i_1_ = 0;
		}
		return i_1_;
	}

	void method2715(Class587_Sub44_Sub1 class587_sub44_sub1, int i, Interface33 interface33) {
		int i_2_ = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i_2_ != -1) {
			if (interface33 == null)
				interface33 = (((Class114_Sub2) this).aClass84_Sub1_Sub1_10102.anInterface39_8886);
			if (i < ((Class114_Sub2) this).aClass84_Sub1_Sub1_10102.anInt9010) {
				((Class114_Sub2) this).aClass84_Sub1_Sub1_10102.method15025(i);
				((Class114_Sub2) this).aClass84_Sub1_Sub1_10102.method14834(interface33);
			} else {
				OpenGL.glActiveTexture(33984 + i);
				OpenGL.glBindTexture((((Class217) (Class217) interface33).anInt2596), (((Class217) (Class217) interface33).anInt2598));
			}
			if (((Class114_Sub2) this).anIntArray10103[i_2_] != i) {
				((Class114_Sub2) this).anIntArray10103[i_2_] = i;
				OpenGL.glUniform1i(i_2_, i);
			}
		}
	}

	void method2688(int i, Class288 class288) {
		OpenGL.glUniform3fv(i, 3, class288.method5773(aFloatArray10110), 0);
	}

	public boolean method2677() {
		if (((Class114_Sub2) this).aBool10116)
			return true;
		((Class84_Sub1_Sub1) ((Class114_Sub2) this).aClass84_Sub1_Sub1_10102).aClass114_Sub2_10378 = null;
		((Class114_Sub2) this).anInt10105 = method16347(35633, ((Class114_Sub2) this).aString10109, aString1566);
		((Class114_Sub2) this).anInt10106 = method16347(35632, ((Class114_Sub2) this).aString10117, aString1568);
		if (((Class114_Sub2) this).anInt10105 == 0 || ((Class114_Sub2) this).anInt10106 == 0) {
			if (((Class114_Sub2) this).anInt10105 != 0)
				OpenGL.glDeleteShader(((Class114_Sub2) this).anInt10105);
			if (((Class114_Sub2) this).anInt10106 != 0)
				OpenGL.glDeleteShader(((Class114_Sub2) this).anInt10106);
			return false;
		}
		((Class114_Sub2) this).anInt10104 = OpenGL.glCreateProgram();
		if (((Class114_Sub2) this).anInt10105 != 0)
			OpenGL.glAttachShader(((Class114_Sub2) this).anInt10104, ((Class114_Sub2) this).anInt10105);
		if (((Class114_Sub2) this).anInt10106 != 0)
			OpenGL.glAttachShader(((Class114_Sub2) this).anInt10104, ((Class114_Sub2) this).anInt10106);
		OpenGL.glLinkProgram(((Class114_Sub2) this).anInt10104);
		OpenGL.glGetProgramiv(((Class114_Sub2) this).anInt10104, 35714, anIntArray10115, 0);
		if (anIntArray10115[0] == 0) {
			if (((Class114_Sub2) this).anInt10105 != 0) {
				OpenGL.glDetachShader(((Class114_Sub2) this).anInt10104, ((Class114_Sub2) this).anInt10105);
				OpenGL.glDeleteShader(((Class114_Sub2) this).anInt10105);
			}
			if (((Class114_Sub2) this).anInt10106 != 0) {
				OpenGL.glDetachShader(((Class114_Sub2) this).anInt10104, ((Class114_Sub2) this).anInt10106);
				OpenGL.glDeleteShader(((Class114_Sub2) this).anInt10106);
			}
			OpenGL.glDeleteProgram(((Class114_Sub2) this).anInt10104);
			return false;
		}
		OpenGL.glUseProgram(((Class114_Sub2) this).anInt10104);
		int i = -1;
		for (int i_3_ = 0; i_3_ < ((Class114_Sub2) this).aClass57_Sub2_10101.method1324(-1945128196); i_3_++) {
			if (((Class114_Sub2) this).aClass57_Sub2_10101.method1325(i_3_, 16711935) == this) {
				i = i_3_;
				break;
			}
		}
		if (i == -1)
			return false;
		int i_4_ = 0;
		int i_5_ = 0;
		for (int i_6_ = 0; i_6_ < ((Class114_Sub2) this).aClass57_Sub2_10101.method1355(1823960155); i_6_++) {
			Class587_Sub44_Sub1 class587_sub44_sub1 = ((Class114_Sub2) this).aClass57_Sub2_10101.method1356(i_6_, 411701405);
			if (class587_sub44_sub1 != null) {
				class587_sub44_sub1.method17128(i);
				Class51 class51 = class587_sub44_sub1.method17131(-870884375);
				int i_7_ = (((Class587_Sub44_Sub1_Sub1) (Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).anIntArray10876[i]);
				if (class51 == Class51.aClass51_820 || class51 == Class51.aClass51_815 || class51 == Class51.aClass51_800 || class51 == Class51.aClass51_827 || class51 == Class51.aClass51_874)
					i_4_ = Math.max(i_7_, i_4_);
				else
					i_5_ = Math.max(i_7_, i_5_);
			}
		}
		for (int i_8_ = 0; i_8_ < ((Class114_Sub2) this).aClass57_Sub2_10101.method1333(773295543); i_8_++) {
			Class587_Sub44_Sub1 class587_sub44_sub1 = ((Class114_Sub2) this).aClass57_Sub2_10101.method1423(i_8_, -1427506198);
			if (class587_sub44_sub1 != null) {
				class587_sub44_sub1.method17128(i);
				Class51 class51 = class587_sub44_sub1.method17131(1885809329);
				int i_9_ = (((Class587_Sub44_Sub1_Sub1) (Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).anIntArray10876[i]);
				if (class51 == Class51.aClass51_820 || class51 == Class51.aClass51_815 || class51 == Class51.aClass51_800 || class51 == Class51.aClass51_827 || class51 == Class51.aClass51_874)
					i_4_ = Math.max(i_9_, i_4_);
				else
					i_5_ = Math.max(i_9_, i_5_);
			}
		}
		((Class114_Sub2) this).aFloatArray10111 = new float[i_4_ + 1];
		((Class114_Sub2) this).aFloatArray10113 = new float[i_4_ + 1];
		((Class114_Sub2) this).aFloatArray10108 = new float[i_4_ + 1];
		((Class114_Sub2) this).aFloatArray10114 = new float[i_4_ + 1];
		((Class114_Sub2) this).anIntArray10103 = new int[i_5_ + 1];
		for (int i_10_ = 0; i_10_ < ((Class114_Sub2) this).anIntArray10103.length; i_10_++)
			((Class114_Sub2) this).anIntArray10103[i_10_] = -1;
		((Class114_Sub2) this).aString10109 = null;
		((Class114_Sub2) this).aString10117 = null;
		((Class114_Sub2) this).aBool10116 = true;
		return true;
	}

	void method2678(Class587_Sub44_Sub1 class587_sub44_sub1, float f) {
		int i = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i != -1) {
			if (((Class114_Sub2) this).aFloatArray10111[i] != f) {
				((Class114_Sub2) this).aFloatArray10111[i] = f;
				if ((class587_sub44_sub1.method17131(-928562244) != Class51.aClass51_820) && (class587_sub44_sub1.method17131(190806350) != Class51.aClass51_815))
					throw new IllegalArgumentException_Sub1(class587_sub44_sub1, "");
				OpenGL.glUniform1f(i, f);
			}
		}
	}

	void method2682(Class587_Sub44_Sub1 class587_sub44_sub1, float f, float f_11_) {
		int i = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i != -1) {
			if (((Class114_Sub2) this).aFloatArray10111[i] != f || ((Class114_Sub2) this).aFloatArray10113[i] != f_11_) {
				((Class114_Sub2) this).aFloatArray10111[i] = f;
				((Class114_Sub2) this).aFloatArray10113[i] = f_11_;
				if (class587_sub44_sub1.method17131(-1800569663) != Class51.aClass51_800)
					throw new IllegalArgumentException_Sub1(class587_sub44_sub1, "");
				OpenGL.glUniform2f(i, f, f_11_);
			}
		}
	}

	public boolean method2692() {
		if (((Class114_Sub2) this).aBool10116)
			return true;
		((Class84_Sub1_Sub1) ((Class114_Sub2) this).aClass84_Sub1_Sub1_10102).aClass114_Sub2_10378 = null;
		((Class114_Sub2) this).anInt10105 = method16347(35633, ((Class114_Sub2) this).aString10109, aString1566);
		((Class114_Sub2) this).anInt10106 = method16347(35632, ((Class114_Sub2) this).aString10117, aString1568);
		if (((Class114_Sub2) this).anInt10105 == 0 || ((Class114_Sub2) this).anInt10106 == 0) {
			if (((Class114_Sub2) this).anInt10105 != 0)
				OpenGL.glDeleteShader(((Class114_Sub2) this).anInt10105);
			if (((Class114_Sub2) this).anInt10106 != 0)
				OpenGL.glDeleteShader(((Class114_Sub2) this).anInt10106);
			return false;
		}
		((Class114_Sub2) this).anInt10104 = OpenGL.glCreateProgram();
		if (((Class114_Sub2) this).anInt10105 != 0)
			OpenGL.glAttachShader(((Class114_Sub2) this).anInt10104, ((Class114_Sub2) this).anInt10105);
		if (((Class114_Sub2) this).anInt10106 != 0)
			OpenGL.glAttachShader(((Class114_Sub2) this).anInt10104, ((Class114_Sub2) this).anInt10106);
		OpenGL.glLinkProgram(((Class114_Sub2) this).anInt10104);
		OpenGL.glGetProgramiv(((Class114_Sub2) this).anInt10104, 35714, anIntArray10115, 0);
		if (anIntArray10115[0] == 0) {
			if (((Class114_Sub2) this).anInt10105 != 0) {
				OpenGL.glDetachShader(((Class114_Sub2) this).anInt10104, ((Class114_Sub2) this).anInt10105);
				OpenGL.glDeleteShader(((Class114_Sub2) this).anInt10105);
			}
			if (((Class114_Sub2) this).anInt10106 != 0) {
				OpenGL.glDetachShader(((Class114_Sub2) this).anInt10104, ((Class114_Sub2) this).anInt10106);
				OpenGL.glDeleteShader(((Class114_Sub2) this).anInt10106);
			}
			OpenGL.glDeleteProgram(((Class114_Sub2) this).anInt10104);
			return false;
		}
		OpenGL.glUseProgram(((Class114_Sub2) this).anInt10104);
		int i = -1;
		for (int i_12_ = 0; i_12_ < ((Class114_Sub2) this).aClass57_Sub2_10101.method1324(-1923810982); i_12_++) {
			if (((Class114_Sub2) this).aClass57_Sub2_10101.method1325(i_12_, 16711935) == this) {
				i = i_12_;
				break;
			}
		}
		if (i == -1)
			return false;
		int i_13_ = 0;
		int i_14_ = 0;
		for (int i_15_ = 0; i_15_ < ((Class114_Sub2) this).aClass57_Sub2_10101.method1355(1719949781); i_15_++) {
			Class587_Sub44_Sub1 class587_sub44_sub1 = ((Class114_Sub2) this).aClass57_Sub2_10101.method1356(i_15_, 411701405);
			if (class587_sub44_sub1 != null) {
				class587_sub44_sub1.method17128(i);
				Class51 class51 = class587_sub44_sub1.method17131(1734261621);
				int i_16_ = (((Class587_Sub44_Sub1_Sub1) (Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).anIntArray10876[i]);
				if (class51 == Class51.aClass51_820 || class51 == Class51.aClass51_815 || class51 == Class51.aClass51_800 || class51 == Class51.aClass51_827 || class51 == Class51.aClass51_874)
					i_13_ = Math.max(i_16_, i_13_);
				else
					i_14_ = Math.max(i_16_, i_14_);
			}
		}
		for (int i_17_ = 0; i_17_ < ((Class114_Sub2) this).aClass57_Sub2_10101.method1333(768675405); i_17_++) {
			Class587_Sub44_Sub1 class587_sub44_sub1 = ((Class114_Sub2) this).aClass57_Sub2_10101.method1423(i_17_, -507741698);
			if (class587_sub44_sub1 != null) {
				class587_sub44_sub1.method17128(i);
				Class51 class51 = class587_sub44_sub1.method17131(-1110240435);
				int i_18_ = (((Class587_Sub44_Sub1_Sub1) (Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).anIntArray10876[i]);
				if (class51 == Class51.aClass51_820 || class51 == Class51.aClass51_815 || class51 == Class51.aClass51_800 || class51 == Class51.aClass51_827 || class51 == Class51.aClass51_874)
					i_13_ = Math.max(i_18_, i_13_);
				else
					i_14_ = Math.max(i_18_, i_14_);
			}
		}
		((Class114_Sub2) this).aFloatArray10111 = new float[i_13_ + 1];
		((Class114_Sub2) this).aFloatArray10113 = new float[i_13_ + 1];
		((Class114_Sub2) this).aFloatArray10108 = new float[i_13_ + 1];
		((Class114_Sub2) this).aFloatArray10114 = new float[i_13_ + 1];
		((Class114_Sub2) this).anIntArray10103 = new int[i_14_ + 1];
		for (int i_19_ = 0; i_19_ < ((Class114_Sub2) this).anIntArray10103.length; i_19_++)
			((Class114_Sub2) this).anIntArray10103[i_19_] = -1;
		((Class114_Sub2) this).aString10109 = null;
		((Class114_Sub2) this).aString10117 = null;
		((Class114_Sub2) this).aBool10116 = true;
		return true;
	}

	void method2680(Class587_Sub44_Sub1 class587_sub44_sub1, float f, float f_20_, float f_21_, float f_22_) {
		int i = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i != -1) {
			if (((Class114_Sub2) this).aFloatArray10111[i] != f || ((Class114_Sub2) this).aFloatArray10113[i] != f_20_ || ((Class114_Sub2) this).aFloatArray10108[i] != f_21_ || ((Class114_Sub2) this).aFloatArray10114[i] != f_22_) {
				((Class114_Sub2) this).aFloatArray10111[i] = f;
				((Class114_Sub2) this).aFloatArray10113[i] = f_20_;
				((Class114_Sub2) this).aFloatArray10108[i] = f_21_;
				((Class114_Sub2) this).aFloatArray10114[i] = f_22_;
				if (class587_sub44_sub1.method17131(950348338) != Class51.aClass51_874)
					throw new IllegalArgumentException_Sub1(class587_sub44_sub1, "");
				OpenGL.glUniform4f(i, f, f_20_, f_21_, f_22_);
			}
		}
	}

	void method2681(Class587_Sub44_Sub1 class587_sub44_sub1, float[] fs, int i) {
		int i_23_ = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i_23_ != -1)
			OpenGL.glUniform4fv(i_23_, i, fs, 0);
	}

	void method2709(Class587_Sub44_Sub1 class587_sub44_sub1, float f, float f_24_, float f_25_, float f_26_) {
		int i = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i != -1) {
			if (((Class114_Sub2) this).aFloatArray10111[i] != f || ((Class114_Sub2) this).aFloatArray10113[i] != f_24_ || ((Class114_Sub2) this).aFloatArray10108[i] != f_25_ || ((Class114_Sub2) this).aFloatArray10114[i] != f_26_) {
				((Class114_Sub2) this).aFloatArray10111[i] = f;
				((Class114_Sub2) this).aFloatArray10113[i] = f_24_;
				((Class114_Sub2) this).aFloatArray10108[i] = f_25_;
				((Class114_Sub2) this).aFloatArray10114[i] = f_26_;
				if (class587_sub44_sub1.method17131(-372040332) != Class51.aClass51_874)
					throw new IllegalArgumentException_Sub1(class587_sub44_sub1, "");
				OpenGL.glUniform4f(i, f, f_24_, f_25_, f_26_);
			}
		}
	}

	void method2683(Class587_Sub44_Sub1 class587_sub44_sub1, Class288 class288) {
		if (!$assertionsDisabled && (class587_sub44_sub1.method17131(1842290273) != Class51.aClass51_816))
			throw new AssertionError();
		int i = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i != -1)
			OpenGL.glUniform4fv(i, 4, class288.method5771(aFloatArray10110), 0);
	}

	public void method53() {
		if (((Class114_Sub2) this).anInt10104 != 0) {
			((Class114_Sub2) this).aClass84_Sub1_Sub1_10102.method16566(((Class114_Sub2) this).anInt10104);
			if (((Class114_Sub2) this).anInt10105 != 0)
				((Class114_Sub2) this).aClass84_Sub1_Sub1_10102.method16565((long) ((Class114_Sub2) this).anInt10105);
			if (((Class114_Sub2) this).anInt10106 != 0)
				((Class114_Sub2) this).aClass84_Sub1_Sub1_10102.method16565((long) ((Class114_Sub2) this).anInt10106);
			((Class114_Sub2) this).anInt10104 = 0;
			((Class114_Sub2) this).anInt10105 = 0;
			((Class114_Sub2) this).anInt10106 = 0;
		}
	}

	void method2685(int i, float f, float f_27_, float f_28_) {
		OpenGL.glUniform3f(i, f, f_27_, f_28_);
	}

	void method2690(int i, Class288 class288) {
		OpenGL.glUniform4fv(i, 4, class288.method5771(aFloatArray10110), 0);
	}

	void method2717(int i, float f, float f_29_, float f_30_, float f_31_) {
		OpenGL.glUniform4f(i, f, f_29_, f_30_, f_31_);
	}

	Class114_Sub2(Class84_Sub1_Sub1 class84_sub1_sub1, Class36 class36) {
		((Class114_Sub2) this).anIntArray10099 = new int[13];
		aString1567 = class36.aString630;
		StringBuilder stringbuilder = new StringBuilder();
		if (class36.aString629 != null) {
			aString1566 = class36.aString629;
			if (class36.aClass50Array631 != null) {
				Class50[] class50s = class36.aClass50Array631;
				for (int i = 0; i < class50s.length; i++) {
					Class50 class50 = class50s[i];
					stringbuilder.append(new StringBuilder().append("#define ").append(class50.aString770).append(" ").append(class50.aString771).append('\n').toString());
				}
			}
			stringbuilder.append(new String(class84_sub1_sub1.method16575(aString1566)));
			((Class114_Sub2) this).aString10109 = stringbuilder.toString();
		}
		if (class36.aString628 != null) {
			aString1568 = class36.aString628;
			stringbuilder.setLength(0);
			if (class36.aClass50Array632 != null) {
				Class50[] class50s = class36.aClass50Array632;
				for (int i = 0; i < class50s.length; i++) {
					Class50 class50 = class50s[i];
					stringbuilder.append(new StringBuilder().append("#define ").append(class50.aString770).append(" ").append(class50.aString771).append('\n').toString());
				}
			}
			stringbuilder.append(new String(class84_sub1_sub1.method16575(aString1568)));
			((Class114_Sub2) this).aString10117 = stringbuilder.toString();
		}
		Class461.method8196(((Class114_Sub2) this).anIntArray10099, 0, ((Class114_Sub2) this).anIntArray10099.length, -1);
	}

	void method2679(Class587_Sub44_Sub1 class587_sub44_sub1, float[] fs, int i) {
		int i_32_ = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i_32_ != -1)
			OpenGL.glUniform4fv(i_32_, i, fs, 0);
	}

	void method2718(int i, float f, float f_33_, float f_34_, float f_35_) {
		OpenGL.glUniform4f(i, f, f_33_, f_34_, f_35_);
	}

	void method2689(int i, int i_36_, Interface33 interface33) {
		((Class114_Sub2) this).aClass84_Sub1_Sub1_10102.method15025(i_36_);
		((Class114_Sub2) this).aClass84_Sub1_Sub1_10102.method14834(interface33);
		OpenGL.glUniform1i(i, i_36_);
	}

	public void method54() {
		if (((Class114_Sub2) this).anInt10104 != 0) {
			((Class114_Sub2) this).aClass84_Sub1_Sub1_10102.method16566(((Class114_Sub2) this).anInt10104);
			if (((Class114_Sub2) this).anInt10105 != 0)
				((Class114_Sub2) this).aClass84_Sub1_Sub1_10102.method16565((long) ((Class114_Sub2) this).anInt10105);
			if (((Class114_Sub2) this).anInt10106 != 0)
				((Class114_Sub2) this).aClass84_Sub1_Sub1_10102.method16565((long) ((Class114_Sub2) this).anInt10106);
			((Class114_Sub2) this).anInt10104 = 0;
			((Class114_Sub2) this).anInt10105 = 0;
			((Class114_Sub2) this).anInt10106 = 0;
		}
	}

	public void finalize() {
		method54();
	}

	void method2723(int i, Class288 class288) {
		OpenGL.glUniform3fv(i, 3, class288.method5773(aFloatArray10110), 0);
	}

	public void method19() {
		if (((Class114_Sub2) this).anInt10104 != 0) {
			((Class114_Sub2) this).aClass84_Sub1_Sub1_10102.method16566(((Class114_Sub2) this).anInt10104);
			if (((Class114_Sub2) this).anInt10105 != 0)
				((Class114_Sub2) this).aClass84_Sub1_Sub1_10102.method16565((long) ((Class114_Sub2) this).anInt10105);
			if (((Class114_Sub2) this).anInt10106 != 0)
				((Class114_Sub2) this).aClass84_Sub1_Sub1_10102.method16565((long) ((Class114_Sub2) this).anInt10106);
			((Class114_Sub2) this).anInt10104 = 0;
			((Class114_Sub2) this).anInt10105 = 0;
			((Class114_Sub2) this).anInt10106 = 0;
		}
	}

	public void method23() {
		if (((Class114_Sub2) this).anInt10104 != 0) {
			((Class114_Sub2) this).aClass84_Sub1_Sub1_10102.method16566(((Class114_Sub2) this).anInt10104);
			if (((Class114_Sub2) this).anInt10105 != 0)
				((Class114_Sub2) this).aClass84_Sub1_Sub1_10102.method16565((long) ((Class114_Sub2) this).anInt10105);
			if (((Class114_Sub2) this).anInt10106 != 0)
				((Class114_Sub2) this).aClass84_Sub1_Sub1_10102.method16565((long) ((Class114_Sub2) this).anInt10106);
			((Class114_Sub2) this).anInt10104 = 0;
			((Class114_Sub2) this).anInt10105 = 0;
			((Class114_Sub2) this).anInt10106 = 0;
		}
	}

	Class114_Sub2(Class84_Sub1_Sub1 class84_sub1_sub1, Class57_Sub2 class57_sub2, Class36 class36) {
		this(class84_sub1_sub1, class36);
		((Class114_Sub2) this).aClass57_Sub2_10101 = class57_sub2;
		((Class114_Sub2) this).aClass84_Sub1_Sub1_10102 = class84_sub1_sub1;
	}

	void method16345() {
		method54();
	}

	void method16346() {
		method54();
	}

	void method2694(Class587_Sub44_Sub1 class587_sub44_sub1, float f) {
		int i = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i != -1) {
			if (((Class114_Sub2) this).aFloatArray10111[i] != f) {
				((Class114_Sub2) this).aFloatArray10111[i] = f;
				if ((class587_sub44_sub1.method17131(-1383810904) != Class51.aClass51_820) && (class587_sub44_sub1.method17131(-1442897929) != Class51.aClass51_815))
					throw new IllegalArgumentException_Sub1(class587_sub44_sub1, "");
				OpenGL.glUniform1f(i, f);
			}
		}
	}

	public boolean method2693() {
		if (((Class114_Sub2) this).aBool10116)
			return true;
		((Class84_Sub1_Sub1) ((Class114_Sub2) this).aClass84_Sub1_Sub1_10102).aClass114_Sub2_10378 = null;
		((Class114_Sub2) this).anInt10105 = method16347(35633, ((Class114_Sub2) this).aString10109, aString1566);
		((Class114_Sub2) this).anInt10106 = method16347(35632, ((Class114_Sub2) this).aString10117, aString1568);
		if (((Class114_Sub2) this).anInt10105 == 0 || ((Class114_Sub2) this).anInt10106 == 0) {
			if (((Class114_Sub2) this).anInt10105 != 0)
				OpenGL.glDeleteShader(((Class114_Sub2) this).anInt10105);
			if (((Class114_Sub2) this).anInt10106 != 0)
				OpenGL.glDeleteShader(((Class114_Sub2) this).anInt10106);
			return false;
		}
		((Class114_Sub2) this).anInt10104 = OpenGL.glCreateProgram();
		if (((Class114_Sub2) this).anInt10105 != 0)
			OpenGL.glAttachShader(((Class114_Sub2) this).anInt10104, ((Class114_Sub2) this).anInt10105);
		if (((Class114_Sub2) this).anInt10106 != 0)
			OpenGL.glAttachShader(((Class114_Sub2) this).anInt10104, ((Class114_Sub2) this).anInt10106);
		OpenGL.glLinkProgram(((Class114_Sub2) this).anInt10104);
		OpenGL.glGetProgramiv(((Class114_Sub2) this).anInt10104, 35714, anIntArray10115, 0);
		if (anIntArray10115[0] == 0) {
			if (((Class114_Sub2) this).anInt10105 != 0) {
				OpenGL.glDetachShader(((Class114_Sub2) this).anInt10104, ((Class114_Sub2) this).anInt10105);
				OpenGL.glDeleteShader(((Class114_Sub2) this).anInt10105);
			}
			if (((Class114_Sub2) this).anInt10106 != 0) {
				OpenGL.glDetachShader(((Class114_Sub2) this).anInt10104, ((Class114_Sub2) this).anInt10106);
				OpenGL.glDeleteShader(((Class114_Sub2) this).anInt10106);
			}
			OpenGL.glDeleteProgram(((Class114_Sub2) this).anInt10104);
			return false;
		}
		OpenGL.glUseProgram(((Class114_Sub2) this).anInt10104);
		int i = -1;
		for (int i_37_ = 0; i_37_ < ((Class114_Sub2) this).aClass57_Sub2_10101.method1324(-1742890555); i_37_++) {
			if (((Class114_Sub2) this).aClass57_Sub2_10101.method1325(i_37_, 16711935) == this) {
				i = i_37_;
				break;
			}
		}
		if (i == -1)
			return false;
		int i_38_ = 0;
		int i_39_ = 0;
		for (int i_40_ = 0; i_40_ < ((Class114_Sub2) this).aClass57_Sub2_10101.method1355(111010325); i_40_++) {
			Class587_Sub44_Sub1 class587_sub44_sub1 = ((Class114_Sub2) this).aClass57_Sub2_10101.method1356(i_40_, 411701405);
			if (class587_sub44_sub1 != null) {
				class587_sub44_sub1.method17128(i);
				Class51 class51 = class587_sub44_sub1.method17131(1046272940);
				int i_41_ = (((Class587_Sub44_Sub1_Sub1) (Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).anIntArray10876[i]);
				if (class51 == Class51.aClass51_820 || class51 == Class51.aClass51_815 || class51 == Class51.aClass51_800 || class51 == Class51.aClass51_827 || class51 == Class51.aClass51_874)
					i_38_ = Math.max(i_41_, i_38_);
				else
					i_39_ = Math.max(i_41_, i_39_);
			}
		}
		for (int i_42_ = 0; i_42_ < ((Class114_Sub2) this).aClass57_Sub2_10101.method1333(-2013385810); i_42_++) {
			Class587_Sub44_Sub1 class587_sub44_sub1 = ((Class114_Sub2) this).aClass57_Sub2_10101.method1423(i_42_, -1884150410);
			if (class587_sub44_sub1 != null) {
				class587_sub44_sub1.method17128(i);
				Class51 class51 = class587_sub44_sub1.method17131(422698026);
				int i_43_ = (((Class587_Sub44_Sub1_Sub1) (Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).anIntArray10876[i]);
				if (class51 == Class51.aClass51_820 || class51 == Class51.aClass51_815 || class51 == Class51.aClass51_800 || class51 == Class51.aClass51_827 || class51 == Class51.aClass51_874)
					i_38_ = Math.max(i_43_, i_38_);
				else
					i_39_ = Math.max(i_43_, i_39_);
			}
		}
		((Class114_Sub2) this).aFloatArray10111 = new float[i_38_ + 1];
		((Class114_Sub2) this).aFloatArray10113 = new float[i_38_ + 1];
		((Class114_Sub2) this).aFloatArray10108 = new float[i_38_ + 1];
		((Class114_Sub2) this).aFloatArray10114 = new float[i_38_ + 1];
		((Class114_Sub2) this).anIntArray10103 = new int[i_39_ + 1];
		for (int i_44_ = 0; i_44_ < ((Class114_Sub2) this).anIntArray10103.length; i_44_++)
			((Class114_Sub2) this).anIntArray10103[i_44_] = -1;
		((Class114_Sub2) this).aString10109 = null;
		((Class114_Sub2) this).aString10117 = null;
		((Class114_Sub2) this).aBool10116 = true;
		return true;
	}

	void method2686(Class587_Sub44_Sub1 class587_sub44_sub1, float f) {
		int i = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i != -1) {
			if (((Class114_Sub2) this).aFloatArray10111[i] != f) {
				((Class114_Sub2) this).aFloatArray10111[i] = f;
				if ((class587_sub44_sub1.method17131(1019774612) != Class51.aClass51_820) && (class587_sub44_sub1.method17131(-1203341911) != Class51.aClass51_815))
					throw new IllegalArgumentException_Sub1(class587_sub44_sub1, "");
				OpenGL.glUniform1f(i, f);
			}
		}
	}

	void method2695(Class587_Sub44_Sub1 class587_sub44_sub1, float f) {
		int i = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i != -1) {
			if (((Class114_Sub2) this).aFloatArray10111[i] != f) {
				((Class114_Sub2) this).aFloatArray10111[i] = f;
				if ((class587_sub44_sub1.method17131(1478607473) != Class51.aClass51_820) && (class587_sub44_sub1.method17131(-1087230708) != Class51.aClass51_815))
					throw new IllegalArgumentException_Sub1(class587_sub44_sub1, "");
				OpenGL.glUniform1f(i, f);
			}
		}
	}

	void method2710(int i, float[] fs, int i_45_) {
		OpenGL.glUniform4fv(i, i_45_, fs, 0);
	}

	void method2697(Class587_Sub44_Sub1 class587_sub44_sub1, float f, float f_46_) {
		int i = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i != -1) {
			if (((Class114_Sub2) this).aFloatArray10111[i] != f || ((Class114_Sub2) this).aFloatArray10113[i] != f_46_) {
				((Class114_Sub2) this).aFloatArray10111[i] = f;
				((Class114_Sub2) this).aFloatArray10113[i] = f_46_;
				if (class587_sub44_sub1.method17131(-1794676952) != Class51.aClass51_800)
					throw new IllegalArgumentException_Sub1(class587_sub44_sub1, "");
				OpenGL.glUniform2f(i, f, f_46_);
			}
		}
	}

	void method2721(Class587_Sub44_Sub1 class587_sub44_sub1, float f, float f_47_) {
		int i = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i != -1) {
			if (((Class114_Sub2) this).aFloatArray10111[i] != f || ((Class114_Sub2) this).aFloatArray10113[i] != f_47_) {
				((Class114_Sub2) this).aFloatArray10111[i] = f;
				((Class114_Sub2) this).aFloatArray10113[i] = f_47_;
				if (class587_sub44_sub1.method17131(-1847769720) != Class51.aClass51_800)
					throw new IllegalArgumentException_Sub1(class587_sub44_sub1, "");
				OpenGL.glUniform2f(i, f, f_47_);
			}
		}
	}

	void method2727(Class587_Sub44_Sub1 class587_sub44_sub1, float f, float f_48_) {
		int i = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i != -1) {
			if (((Class114_Sub2) this).aFloatArray10111[i] != f || ((Class114_Sub2) this).aFloatArray10113[i] != f_48_) {
				((Class114_Sub2) this).aFloatArray10111[i] = f;
				((Class114_Sub2) this).aFloatArray10113[i] = f_48_;
				if (class587_sub44_sub1.method17131(718385899) != Class51.aClass51_800)
					throw new IllegalArgumentException_Sub1(class587_sub44_sub1, "");
				OpenGL.glUniform2f(i, f, f_48_);
			}
		}
	}

	void method2691(Class587_Sub44_Sub1 class587_sub44_sub1, float f, float f_49_, float f_50_) {
		int i = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i != -1) {
			if (((Class114_Sub2) this).aFloatArray10111[i] != f || ((Class114_Sub2) this).aFloatArray10113[i] != f_49_ || ((Class114_Sub2) this).aFloatArray10108[i] != f_50_) {
				((Class114_Sub2) this).aFloatArray10111[i] = f;
				((Class114_Sub2) this).aFloatArray10113[i] = f_49_;
				((Class114_Sub2) this).aFloatArray10108[i] = f_50_;
				if (class587_sub44_sub1.method17131(-1953210028) != Class51.aClass51_827)
					throw new IllegalArgumentException_Sub1(class587_sub44_sub1, "");
				OpenGL.glUniform3f(i, f, f_49_, f_50_);
			}
		}
	}

	void method2701(Class587_Sub44_Sub1 class587_sub44_sub1, float f, float f_51_, float f_52_, float f_53_) {
		int i = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i != -1) {
			if (((Class114_Sub2) this).aFloatArray10111[i] != f || ((Class114_Sub2) this).aFloatArray10113[i] != f_51_ || ((Class114_Sub2) this).aFloatArray10108[i] != f_52_ || ((Class114_Sub2) this).aFloatArray10114[i] != f_53_) {
				((Class114_Sub2) this).aFloatArray10111[i] = f;
				((Class114_Sub2) this).aFloatArray10113[i] = f_51_;
				((Class114_Sub2) this).aFloatArray10108[i] = f_52_;
				((Class114_Sub2) this).aFloatArray10114[i] = f_53_;
				if (class587_sub44_sub1.method17131(1430924874) != Class51.aClass51_874)
					throw new IllegalArgumentException_Sub1(class587_sub44_sub1, "");
				OpenGL.glUniform4f(i, f, f_51_, f_52_, f_53_);
			}
		}
	}

	static {
		anIntArray10115 = new int[2];
		aFloatArray10110 = new float[16];
	}

	void method2675(Class587_Sub44_Sub1 class587_sub44_sub1, Class288 class288) {
		if (!$assertionsDisabled && (class587_sub44_sub1.method17131(-880675048) != Class51.aClass51_814))
			throw new AssertionError();
		int i = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i != -1)
			OpenGL.glUniform2fv(i, 4, class288.method5775(aFloatArray10110), 0);
	}

	void method2700(Class587_Sub44_Sub1 class587_sub44_sub1, float f, float f_54_, float f_55_) {
		int i = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i != -1) {
			if (((Class114_Sub2) this).aFloatArray10111[i] != f || ((Class114_Sub2) this).aFloatArray10113[i] != f_54_ || ((Class114_Sub2) this).aFloatArray10108[i] != f_55_) {
				((Class114_Sub2) this).aFloatArray10111[i] = f;
				((Class114_Sub2) this).aFloatArray10113[i] = f_54_;
				((Class114_Sub2) this).aFloatArray10108[i] = f_55_;
				if (class587_sub44_sub1.method17131(1671118955) != Class51.aClass51_827)
					throw new IllegalArgumentException_Sub1(class587_sub44_sub1, "");
				OpenGL.glUniform3f(i, f, f_54_, f_55_);
			}
		}
	}

	void method2705(Class587_Sub44_Sub1 class587_sub44_sub1, float[] fs, int i) {
		int i_56_ = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i_56_ != -1)
			OpenGL.glUniform4fv(i_56_, i, fs, 0);
	}

	void method2706(Class587_Sub44_Sub1 class587_sub44_sub1, float[] fs, int i) {
		int i_57_ = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i_57_ != -1)
			OpenGL.glUniform4fv(i_57_, i, fs, 0);
	}

	void method2713(Class587_Sub44_Sub1 class587_sub44_sub1, Class288 class288) {
		if (!$assertionsDisabled && (class587_sub44_sub1.method17131(900525835) != Class51.aClass51_816))
			throw new AssertionError();
		int i = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i != -1)
			OpenGL.glUniform4fv(i, 4, class288.method5771(aFloatArray10110), 0);
	}

	void method2724(Class587_Sub44_Sub1 class587_sub44_sub1, Class288 class288) {
		if (!$assertionsDisabled && (class587_sub44_sub1.method17131(1553653607) != Class51.aClass51_814))
			throw new AssertionError();
		int i = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i != -1)
			OpenGL.glUniform2fv(i, 4, class288.method5775(aFloatArray10110), 0);
	}

	void method2722(Class587_Sub44_Sub1 class587_sub44_sub1, Class288 class288) {
		if (!$assertionsDisabled && (class587_sub44_sub1.method17131(-1353228513) != Class51.aClass51_814))
			throw new AssertionError();
		int i = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i != -1)
			OpenGL.glUniform2fv(i, 4, class288.method5775(aFloatArray10110), 0);
	}

	void method2702(Class587_Sub44_Sub1 class587_sub44_sub1, Class288 class288) {
		if (!$assertionsDisabled && (class587_sub44_sub1.method17131(775760386) != Class51.aClass51_814))
			throw new AssertionError();
		int i = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i != -1)
			OpenGL.glUniform2fv(i, 4, class288.method5775(aFloatArray10110), 0);
	}

	void method2711(Class587_Sub44_Sub1 class587_sub44_sub1, Class288 class288) {
		if (!$assertionsDisabled && (class587_sub44_sub1.method17131(-2030120431) != Class51.aClass51_814))
			throw new AssertionError();
		int i = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i != -1)
			OpenGL.glUniform2fv(i, 4, class288.method5775(aFloatArray10110), 0);
	}

	void method2684(int i, Class288 class288) {
		OpenGL.glUniform2fv(i, 4, class288.method5775(aFloatArray10110), 0);
	}

	void method2687(int i, float f, float f_58_, float f_59_, float f_60_) {
		OpenGL.glUniform4f(i, f, f_58_, f_59_, f_60_);
	}

	void method2714(Class587_Sub44_Sub1 class587_sub44_sub1, Class288 class288) {
		if (!$assertionsDisabled && (class587_sub44_sub1.method17131(1908683386) != Class51.aClass51_816))
			throw new AssertionError();
		int i = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i != -1)
			OpenGL.glUniform4fv(i, 4, class288.method5771(aFloatArray10110), 0);
	}

	void method2712(Class587_Sub44_Sub1 class587_sub44_sub1, Class288 class288) {
		if (!$assertionsDisabled && (class587_sub44_sub1.method17131(-1642225815) != Class51.aClass51_814))
			throw new AssertionError();
		int i = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i != -1)
			OpenGL.glUniform2fv(i, 4, class288.method5775(aFloatArray10110), 0);
	}

	void method2716(int i, float f, float f_61_, float f_62_) {
		OpenGL.glUniform3f(i, f, f_61_, f_62_);
	}

	void method2699(Class587_Sub44_Sub1 class587_sub44_sub1, float f, float f_63_, float f_64_, float f_65_) {
		int i = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i != -1) {
			if (((Class114_Sub2) this).aFloatArray10111[i] != f || ((Class114_Sub2) this).aFloatArray10113[i] != f_63_ || ((Class114_Sub2) this).aFloatArray10108[i] != f_64_ || ((Class114_Sub2) this).aFloatArray10114[i] != f_65_) {
				((Class114_Sub2) this).aFloatArray10111[i] = f;
				((Class114_Sub2) this).aFloatArray10113[i] = f_63_;
				((Class114_Sub2) this).aFloatArray10108[i] = f_64_;
				((Class114_Sub2) this).aFloatArray10114[i] = f_65_;
				if (class587_sub44_sub1.method17131(-1634387538) != Class51.aClass51_874)
					throw new IllegalArgumentException_Sub1(class587_sub44_sub1, "");
				OpenGL.glUniform4f(i, f, f_63_, f_64_, f_65_);
			}
		}
	}

	int method16347(int i, String string, String string_66_) {
		if (string == null)
			return 0;
		int i_67_ = OpenGL.glCreateShader(i);
		OpenGL.glShaderSource(i_67_, string);
		OpenGL.glCompileShader(i_67_);
		OpenGL.glGetShaderiv(i_67_, 35713, anIntArray10115, 0);
		if (anIntArray10115[0] == 0) {
			OpenGL.glDeleteShader(i_67_);
			i_67_ = 0;
		}
		return i_67_;
	}

	void method2719(int i, float[] fs, int i_68_) {
		OpenGL.glUniform4fv(i, i_68_, fs, 0);
	}

	void method2720(int i, float[] fs, int i_69_) {
		OpenGL.glUniform4fv(i, i_69_, fs, 0);
	}

	void method2704(int i, float[] fs, int i_70_) {
		OpenGL.glUniform4fv(i, i_70_, fs, 0);
	}

	void method2703(int i, Class288 class288) {
		OpenGL.glUniform3fv(i, 3, class288.method5773(aFloatArray10110), 0);
	}

	void method2707(Class587_Sub44_Sub1 class587_sub44_sub1, Class288 class288) {
		if (!$assertionsDisabled && (class587_sub44_sub1.method17131(-1823935274) != Class51.aClass51_814))
			throw new AssertionError();
		int i = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i != -1)
			OpenGL.glUniform2fv(i, 4, class288.method5775(aFloatArray10110), 0);
	}

	void method2708(int i, Class288 class288) {
		OpenGL.glUniform3fv(i, 3, class288.method5773(aFloatArray10110), 0);
	}

	void method2725(int i, Class288 class288) {
		OpenGL.glUniform2fv(i, 4, class288.method5775(aFloatArray10110), 0);
	}

	void method2726(int i, Class288 class288) {
		OpenGL.glUniform4fv(i, 4, class288.method5771(aFloatArray10110), 0);
	}

	void method2698(int i, int i_71_, Interface33 interface33) {
		((Class114_Sub2) this).aClass84_Sub1_Sub1_10102.method15025(i_71_);
		((Class114_Sub2) this).aClass84_Sub1_Sub1_10102.method14834(interface33);
		OpenGL.glUniform1i(i, i_71_);
	}

	int method16348(int i, String string, String string_72_) {
		if (string == null)
			return 0;
		int i_73_ = OpenGL.glCreateShader(i);
		OpenGL.glShaderSource(i_73_, string);
		OpenGL.glCompileShader(i_73_);
		OpenGL.glGetShaderiv(i_73_, 35713, anIntArray10115, 0);
		if (anIntArray10115[0] == 0) {
			OpenGL.glDeleteShader(i_73_);
			i_73_ = 0;
		}
		return i_73_;
	}

	int method16349(int i, String string, String string_74_) {
		if (string == null)
			return 0;
		int i_75_ = OpenGL.glCreateShader(i);
		OpenGL.glShaderSource(i_75_, string);
		OpenGL.glCompileShader(i_75_);
		OpenGL.glGetShaderiv(i_75_, 35713, anIntArray10115, 0);
		if (anIntArray10115[0] == 0) {
			OpenGL.glDeleteShader(i_75_);
			i_75_ = 0;
		}
		return i_75_;
	}

	void method2696(Class587_Sub44_Sub1 class587_sub44_sub1, int i, Interface33 interface33) {
		int i_76_ = ((Class587_Sub44_Sub1_Sub1) class587_sub44_sub1).method17200();
		if (i_76_ != -1) {
			if (interface33 == null)
				interface33 = (((Class114_Sub2) this).aClass84_Sub1_Sub1_10102.anInterface39_8886);
			if (i < ((Class114_Sub2) this).aClass84_Sub1_Sub1_10102.anInt9010) {
				((Class114_Sub2) this).aClass84_Sub1_Sub1_10102.method15025(i);
				((Class114_Sub2) this).aClass84_Sub1_Sub1_10102.method14834(interface33);
			} else {
				OpenGL.glActiveTexture(33984 + i);
				OpenGL.glBindTexture((((Class217) (Class217) interface33).anInt2596), (((Class217) (Class217) interface33).anInt2598));
			}
			if (((Class114_Sub2) this).anIntArray10103[i_76_] != i) {
				((Class114_Sub2) this).anIntArray10103[i_76_] = i;
				OpenGL.glUniform1i(i_76_, i);
			}
		}
	}
}
