[Scummvm-cvs-logs] CVS: scummvm/scumm script_v80he.cpp,2.112,2.113

Max Horn fingolfin at users.sourceforge.net
Tue May 10 07:09:37 CEST 2005


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

Modified Files:
	script_v80he.cpp 
Log Message:
Another fix, more cleanup

Index: script_v80he.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/script_v80he.cpp,v
retrieving revision 2.112
retrieving revision 2.113
diff -u -d -r2.112 -r2.113
--- script_v80he.cpp	10 May 2005 14:01:54 -0000	2.112
+++ script_v80he.cpp	10 May 2005 14:07:21 -0000	2.113
@@ -646,8 +646,6 @@
 	y = y1;
 	x = x1;
 
-	const int tmpA = absDY;
-	int tmbB = 0;
 
 	if (type == 2) {
 		Actor *a = derefActor(id, "drawLine");
@@ -665,24 +663,27 @@
 	}
 
 	int var_C = 0;
-	int ebx = 0;
+	int tmpX = 0;
+	int tmpY = 0;
 	for (int i = 0; i <= maxDist; i++) {
-		ebx += absDX;
-		tmbB += tmpA;
+		tmpX += absDX;
+		tmpY += absDY;
 
 		int eax = 0;
 
-		if (ebx > maxDist) {
+		if (tmpX > maxDist) {
 			eax = 1;
+			tmpX -= maxDist;
+
 			if (dx >= 0) {
 				x++;
 			} else {
 				x--;
 			}
 		}
-		if (tmbB > maxDist) {
+		if (tmpY > maxDist) {
 			eax = dy;
-			tmbB -= maxDist;
+			tmpY -= maxDist;
 
 			if (dy >= 0) {
 				y++;





More information about the Scummvm-git-logs mailing list