[Scummvm-cvs-logs] SF.net SVN: scummvm:[45474] scummvm/trunk/engines/sci/gui/gui_picture.cpp

m_kiewitz at users.sourceforge.net m_kiewitz at users.sourceforge.net
Wed Oct 28 16:15:19 CET 2009


Revision: 45474
          http://scummvm.svn.sourceforge.net/scummvm/?rev=45474&view=rev
Author:   m_kiewitz
Date:     2009-10-28 15:15:18 +0000 (Wed, 28 Oct 2009)

Log Message:
-----------
SCI/newgui: another floodfill change, fixes sq3 this time (this is madness)

Modified Paths:
--------------
    scummvm/trunk/engines/sci/gui/gui_picture.cpp

Modified: scummvm/trunk/engines/sci/gui/gui_picture.cpp
===================================================================
--- scummvm/trunk/engines/sci/gui/gui_picture.cpp	2009-10-28 15:07:24 UTC (rev 45473)
+++ scummvm/trunk/engines/sci/gui/gui_picture.cpp	2009-10-28 15:15:18 UTC (rev 45474)
@@ -602,6 +602,23 @@
 	byte searchPriority = _screen->getPriority(p.x, p.y);
 	byte searchControl = _screen->getControl(p.x, p.y);
 
+	// This logic was taken directly from sierra sci, floodfill will get aborted on various occations
+	if (screenMask & SCI_SCREEN_MASK_VISUAL) {
+		if (_resMan->isVGA()) {
+			if ((color == 255) || (searchColor != 0))
+				return;
+		} else {
+			if ((color == 15) || (searchColor != 15))
+				return;
+		}
+	} else if (screenMask & SCI_SCREEN_MASK_PRIORITY) {
+		if ((priority == 0) || (searchPriority != 0))
+			return;
+	} else if (screenMask & SCI_SCREEN_MASK_CONTROL) {
+		if ((control == 0) || (searchControl != 0))
+			return;
+	}
+
 	// Now remove screens, that already got the right color/priority/control
 	if ((screenMask & SCI_SCREEN_MASK_VISUAL) && (searchColor == color))
 		screenMask ^= SCI_SCREEN_MASK_VISUAL;
@@ -614,23 +631,11 @@
 	if (!screenMask)
 		return;
 
-	// This logic was taken directly from sierra sci, floodfill will get aborted on various occations
 	if (screenMask & SCI_SCREEN_MASK_VISUAL) {
-		if (_resMan->isVGA()) {
-			if ((color == 255) || (searchColor != 0))
-				return;
-		} else {
-			if ((color == 15) || (searchColor != 15))
-				return;
-		}
 		matchMask = SCI_SCREEN_MASK_VISUAL;
 	} else if (screenMask & SCI_SCREEN_MASK_PRIORITY) {
-		if ((priority == 0) || (searchPriority != 0))
-			return;
 		matchMask = SCI_SCREEN_MASK_PRIORITY;
-	} else if (screenMask & SCI_SCREEN_MASK_CONTROL) {
-		if ((control == 0) || (searchControl != 0))
-			return;
+	} else {
 		matchMask = SCI_SCREEN_MASK_CONTROL;
 	}
 


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list