[Scummvm-cvs-logs] CVS: scummvm/scumm script_v6.cpp,1.293.2.16,1.293.2.17 scummvm.cpp,2.577.2.24,2.577.2.25

Max Horn fingolfin at users.sourceforge.net
Sun Jul 18 15:30:00 CEST 2004


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

Modified Files:
      Tag: branch-0-6-0
	script_v6.cpp scummvm.cpp 
Log Message:
Move some tiny formatting changes to the 0.6.x tree, as well as one MISega fix

Index: script_v6.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/script_v6.cpp,v
retrieving revision 1.293.2.16
retrieving revision 1.293.2.17
diff -u -d -r1.293.2.16 -r1.293.2.17
--- script_v6.cpp	18 Jul 2004 22:15:52 -0000	1.293.2.16
+++ script_v6.cpp	18 Jul 2004 22:29:04 -0000	1.293.2.17
@@ -568,7 +568,7 @@
 		error("Too many items %d in stack list, max %d", num, maxnum);
 
 	i = num;
-	while (((int)--i) >= 0) {
+	while (i--) {
 		args[i] = pop();
 	}
 
@@ -855,10 +855,7 @@
 	int state = pop();
 	int obj = pop();
 
-	// FIXME: Why is the following here? Is it based on disassembly, or was
-	// it simply added to work around a bug (in ScummVM or scripts) ?
-	// In either case, the answer should be put into a comment (replacing this
-	// one, of course :-)
+	// This is based on disassembly
 	if (state == 0)
 		state = 1;
 
@@ -1826,19 +1823,13 @@
 		break;
 	case 95:		// SO_IGNORE_BOXES
 		a->ignoreBoxes = 1;
-		if (_version >= 7)
-			a->forceClip = 100;
-		else
-			a->forceClip = 0;
+		a->forceClip = (_version >= 7) ? 100 : 0;
 		if (a->isInCurrentRoom())
 			a->putActor(a->_pos.x, a->_pos.y, a->room);
 		break;
 	case 96:		// SO_FOLLOW_BOXES
 		a->ignoreBoxes = 0;
-		if (_version >= 7)
-			a->forceClip = 100;
-		else
-			a->forceClip = 0;
+		a->forceClip = (_version >= 7) ? 100 : 0;
 		if (a->isInCurrentRoom())
 			a->putActor(a->_pos.x, a->_pos.y, a->room);
 		break;
@@ -1990,6 +1981,7 @@
 	case 139:		// SO_VERB_IMAGE_IN_ROOM
 		b = pop();
 		a = pop();
+
 		if (slot && a != vs->imgindex) {
 			setVerbObject(b, a, slot);
 			vs->type = kImageVerbType;

Index: scummvm.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/Attic/scummvm.cpp,v
retrieving revision 2.577.2.24
retrieving revision 2.577.2.25
diff -u -d -r2.577.2.24 -r2.577.2.25
--- scummvm.cpp	18 Jul 2004 22:15:52 -0000	2.577.2.24
+++ scummvm.cpp	18 Jul 2004 22:29:04 -0000	2.577.2.25
@@ -1503,8 +1503,9 @@
 		processDrawQue();
 
 		// Full Throttle always redraws verbs and draws verbs before actors
-		if ((_gameId == GID_FT) || _verbRedraw)
+		if ((_gameId == GID_FT) || _verbRedraw) {
 			redrawVerbs();
+		}
 	
 		setActorRedrawFlags();
 		resetActorBgs();
@@ -1527,10 +1528,9 @@
 			clearClickedStatus();
 		}
 
-
-		if (!_verbRedraw && _cursor.state > 0) {
+		if (!_verbRedraw && _cursor.state > 0)
 			verbMouseOver(checkMouseOver(_mouse.x, _mouse.y));
-		}
+
 		_verbRedraw = false;
 
 		if (_version <= 2) {
@@ -1698,6 +1698,19 @@
 			_rightBtnPressed &= ~msDown;
 			break;
 	
+		// The following two cases enable dialog choices to be
+		// scrolled through in the SegaCD version of MI
+		// as nothing else uses the wheel don't bother
+		// checking the gameid
+			
+		case OSystem::EVENT_WHEELDOWN:
+			_keyPressed = 55;
+			break;
+
+		case OSystem::EVENT_WHEELUP:
+			_keyPressed = 54;
+			break;
+	
 		case OSystem::EVENT_QUIT:
 			if (_confirmExit)
 				confirmexitDialog();
@@ -2048,6 +2061,7 @@
 	}
 
 	initRoomSubBlocks();
+
 	if (_features & GF_OLD_BUNDLE)
 		loadRoomObjectsOldBundle();
 	else if (_features & GF_SMALL_HEADER)





More information about the Scummvm-git-logs mailing list