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


void script_1656(int a0,int a1,int a2) {
	int v4;
	if (a0 == -1) {
		return;
	}
	int v0 = (int)idx17mapData('i', 'I', a0, 0);
	if (v0 == -1) {
		return;
	}
	int v3 = cs2method_10970(v0);
	int v5 = cs2method_10823(a1);
	int v2 = cs2method_10461(v5, 32);
	int v1 = 0;
	if (v3 > 0) {
		v4 = cs2method_10968(cs2method_10051(v2, v5), v3);
	} else {
		v4 = v2;
	}
	if (v4 < 10) {
		v4 = 10;
	}
	if (cs2method_11038(a1, 1) == 1) {
		cs2method_10013(16, v4, 0, 0);
		script_1540(a1, a0, a2, 1);
	}
	return;
}
