[Scummvm-cvs-logs] CVS: scummvm/scumm script_v72he.cpp,2.251,2.252 script_v80he.cpp,2.90,2.91

kirben kirben at users.sourceforge.net
Tue Apr 12 00:52:40 CEST 2005


Update of /cvsroot/scummvm/scummvm/scumm
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6825/scumm

Modified Files:
	script_v72he.cpp script_v80he.cpp 
Log Message:

Cleanup


Index: script_v72he.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/script_v72he.cpp,v
retrieving revision 2.251
retrieving revision 2.252
diff -u -d -r2.251 -r2.252
--- script_v72he.cpp	12 Apr 2005 02:29:50 -0000	2.251
+++ script_v72he.cpp	12 Apr 2005 07:52:13 -0000	2.252
@@ -2093,7 +2093,7 @@
 	default:
 		error("o72_readINI: default type %d", type);
 	}
-	debug(1, "o72_readINI (%d) %s", type, option);
+	debug(0, "o72_readINI (%d) %s", type, option);
 }
 
 void ScummEngine_v72he::o72_writeINI() {

Index: script_v80he.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/script_v80he.cpp,v
retrieving revision 2.90
retrieving revision 2.91
diff -u -d -r2.90 -r2.91
--- script_v80he.cpp	12 Apr 2005 02:29:50 -0000	2.90
+++ script_v80he.cpp	12 Apr 2005 07:52:15 -0000	2.91
@@ -473,7 +473,7 @@
 	default:
 		error("o80_readConfigFile: default type %d", type);
 	}
-	debug(1, "o80_readConfigFile: Filename %s Section %s Name %s", filename, section, name);
+	debug(0, "o80_readConfigFile: Filename %s Section %s Name %s", filename, section, name);
 }
 
 void ScummEngine_v80he::o80_writeConfigFile() {
@@ -601,14 +601,8 @@
 void ScummEngine_v80he::unknownE0(int x1, int y1, int x, int unk1, int unk2, int type, int id) {
 	debug(0,"unknownE0: x1 %d y1 %d x %d unk1 %d, unk2 %d type %d id %d", x1, y1, x, unk1, unk2, type, id);	
 
-	int eax, ebx, ecx, y, edp, edx, esi;
-	int var_4, var_8, var_C;
-
-	// edx is never set?
-	edx = 0;
-
-	ebx = 0;
-	var_C = 0;
+	int eax, ebx, ecx, edx, esi;
+	int var_4, var_8, var_C, y;
 
 	if (unk2 < 0) {
 		unk2 = -unk2;
@@ -617,38 +611,17 @@
 		unk2 = 1;
 	}
 
-	eax = x;
-	ecx = x1;
-
-	esi = unk1;
-	y = y1;
-
-	eax -= ecx;
-	esi -= y;
-
-	var_8 = eax;
-	var_4 = esi;
-
-	edp = eax;
-	eax = esi;
-
-	edp ^= edx;
-	edp -= edx;
-
-	eax ^= edx;
-	eax -= edx;
-
-	esi = edp;
+	var_4 = unk1 - y1;
+	var_8 = x - x1;
 
-	y1 = eax;
+	x = x1;
+	y = var_4;
 
-	if (eax > edp) {
-		esi = eax;
+	esi = var_8;
+	if (var_4 > var_8) {
+		esi = var_4;
 	}
 
-	x = x1;
-	x1 = 0;
-
 	if (type == 2) {
 		Actor *a = derefActorSafe(id, "unknownE0");
 		a->drawActorToBackBuf(x1, y1);
@@ -664,10 +637,14 @@
 		unknownE0Helper(x1, y1, id);
 	}
 
+	x1 = 0;
+	ebx = 0;
+	edx = 0;
+	var_C = 0;
 	for (int i = 0; i <= esi; i++) {
 		ecx = x1;
-		eax = y1;	
-		ebx += edp;
+		eax = y;	
+		ebx += var_8;
 		ecx += eax;
 
 		eax ^= eax;
@@ -678,31 +655,27 @@
 			edx -= esi;
 
 			eax = 1;
-			int tmp = edx;
-			edx = x;
-			if (tmp >= 0) {
-				edx++;
+			if (edx >= 0) {
+				x++;
 			} else {
-				edx--;
+				x--;
 			}
-
-			x = edx;
 		}
+
 		if (ecx > esi) {
 			eax = var_4;
-			ecx -= esi;
+			x1 -= esi;
 
-			x1 = ecx;
 			if (eax >= 0) {
 				y++;
 			} else {
 				y--;
 			}
+		} else {
+			if (eax == 0)
+				continue;
 		}
 
-		if (eax == 0)
-			continue;
-
 		ecx = var_C;
 		eax = ecx;
 		eax /= unk2;





More information about the Scummvm-git-logs mailing list