[Scummvm-cvs-logs] SF.net SVN: scummvm:[33950] scummvm/trunk/engines/cine/script_fw.cpp

buddha_ at users.sourceforge.net buddha_ at users.sourceforge.net
Sun Aug 17 00:15:57 CEST 2008


Revision: 33950
          http://scummvm.svn.sourceforge.net/scummvm/?rev=33950&view=rev
Author:   buddha_
Date:     2008-08-16 22:15:57 +0000 (Sat, 16 Aug 2008)

Log Message:
-----------
Workaround for bug #2054882 (FW: Impossible to survive entering monastery (regression)):
For Future Wars o1_compareGlobalVar now compares global variable 255 to be equal to everything.
The scripts probably tested global variable 255 for equality with some value (Maybe 143?)
to see whether copy protection was properly passed.

Modified Paths:
--------------
    scummvm/trunk/engines/cine/script_fw.cpp

Modified: scummvm/trunk/engines/cine/script_fw.cpp
===================================================================
--- scummvm/trunk/engines/cine/script_fw.cpp	2008-08-16 22:06:44 UTC (rev 33949)
+++ scummvm/trunk/engines/cine/script_fw.cpp	2008-08-16 22:15:57 UTC (rev 33950)
@@ -1501,7 +1501,18 @@
 
 		debugC(5, kCineDebugScript, "Line: %d: compare globalVars[%d] and %d", _line, varIdx, value);
 
-		_compare = compareVars(_globalVars[varIdx], value);
+		// WORKAROUND for bug #2054882. Without this, the monks will always
+		// kill you as an impostor, even if you enter the monastery in disguise.
+		//
+		// TODO: Check whether this might be worked around in some other way
+		// like setting global variable 255 to 143 in Future Wars (This is
+		// supposedly what Future Wars checks for from time to time during
+		// gameplay to verify that copy protection was successfully passed).
+		if (varIdx == 255 && (g_cine->getGameType() == Cine::GType_FW)) {
+			_compare = kCmpEQ;
+		} else {
+			_compare = compareVars(_globalVars[varIdx], value);
+		}
 	}
 
 	return 0;


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