/* 
 * Script decompiled by jagdecs2 v3.2
 * Decompiler opts:
 * --------------
 * t1LocalAnalyzer:true
 * t2LocalAnalyzer:true
 * beautifier:true
 * --------------
 * Made by mgi125 ;)
 */


void script_9829(int a0,int a1,int a2) {
	if (a0 == 5) {
		return;
	}
	int v0 = -1;
	int v1 = -1;
	int v2 = 0;
	if (cs2method_11038(a1, a2) == 1) {
		int v3 = cs2method_10487();
		if (v3 != -1 && cs2method_11089() > 0) {
			int v5 = cs2method_10480(v3);
			if (script_9225(v5, 0) == 1) {
				return;
			}
			switch (a0) {
				case 1:
					v2 = 1;
					break;
				case 2:
					v2 = 5;
					break;
				case 3:
					v2 = 10;
					break;
				case 4:
					v2 = client_configs['cfg111'];
					break;
				case 6:
					v2 = cs2method_10936(93, v3);
					break;
				case 8:
					if (script_9828(1, v3) == 1) {
						script_9214(v3, 93, a2, 49938560, a1);
					}
					return;
			}
			int v4 = cs2method_10872(v2, script_8886(a1, v3, 0));
			if (script_9830(v3, v4, a2, 49938647, a1) == 1) {
				script_9838();
			}
		}
	}
	return;
}
