[Scummvm-cvs-logs] CVS: scummvm/simon simon-md5.h,1.12,1.13 simon.cpp,1.498,1.499

kirben kirben at users.sourceforge.net
Mon May 9 03:54:06 CEST 2005


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

Modified Files:
	simon-md5.h simon.cpp 
Log Message:

Add a surprise.


Index: simon-md5.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/simon/simon-md5.h,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -d -r1.12 -r1.13
--- simon-md5.h	31 Mar 2005 15:12:12 -0000	1.12
+++ simon-md5.h	9 May 2005 10:50:59 -0000	1.13
@@ -1,5 +1,5 @@
 /*
-  This file was generated by the md5table tool on Thu Mar 31 15:11:06 2005
+  This file was generated by the md5table tool on Mon May 09 10:43:26 2005
   DO NOT EDIT MANUALLY!
  */
 
@@ -16,11 +16,9 @@
 	{ "078b04da0974a40645b92baffdf2781e", "simon2talkie", Common::EN_USA, Common::kPlatformPC },
 	{ "08bd7abefe9c44e43df396748640e531", "simon1talkie", Common::FR_FRA, Common::kPlatformPC },
 	{ "1e11ddbad80c408031ae44a0cbce46bb", "simon2talkie", Common::EN_USA, Common::kPlatformPC },
-	{ "27c8e7feada80c75b70b9c2f6088d519", "simon2dos", Common::EN_USA, Common::kPlatformPC },
 	{ "39e8f13ec29de1fcef98c81ca0a2ae57", "simon1amiga", Common::EN_USA, Common::kPlatformAmiga },
 	{ "3b22f3cc4ce9faa3f7830ab18235b04d", "simon1dos", Common::RU_RUS, Common::kPlatformPC },
 	{ "3bdf85dc57c1abff8f05416b4571198f", "simon2talkie", Common::DE_DEU, Common::kPlatformPC },
-	{ "465eed710cc242b2de7dc77edd467c4c", "simon1dos", Common::EN_USA, Common::kPlatformPC },
 	{ "486f026593f894f5b6b346ef3984a7a0", "simon1demo", Common::EN_USA, Common::kPlatformPC },
 	{ "48ce4ffda968cc7a38870c354571f92c", "simon1dos", Common::EN_USA, Common::kPlatformPC },
 	{ "79a9d9357c15153c8c502dba73c3eac6", "simon2talkie", Common::ES_ESP, Common::kPlatformPC },
@@ -29,7 +27,6 @@
 	{ "a3cbdd3450f9fccb0a9d8d6dc28f66fe", "simon2talkie", Common::HB_ISR, Common::kPlatformPC },
 	{ "b6cfe7449a32418ed523bde22f5125ed", "simon1dos", Common::FR_FRA, Common::kPlatformPC },
 	{ "bd85a8b5135592ada9cbeae49160f1d3", "simon2talkie", Common::EN_USA, Common::kPlatformWindows },
-	{ "bed9134804d96f72afa152b8ec5628c3", "simon1dos", Common::FR_FRA, Common::kPlatformPC },
 	{ "c8ddd48919aa75423dd2d3e5864909df", "simon2talkie", Common::FR_FRA, Common::kPlatformPC },
 	{ "c8f5b860a20dcc63915d94cf2bdcfa49", "simon1dos", Common::IT_ITA, Common::kPlatformPC },
 	{ "d22302abf44219f95d50f2faa807dd1a", "simon1talkie", Common::EN_USA, Common::kPlatformWindows },

Index: simon.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/simon/simon.cpp,v
retrieving revision 1.498
retrieving revision 1.499
diff -u -d -r1.498 -r1.499
--- simon.cpp	8 May 2005 21:49:48 -0000	1.498
+++ simon.cpp	9 May 2005 10:50:59 -0000	1.499
@@ -258,6 +258,12 @@
 };
 #endif
 
+static const char* bad_versions[3] = {
+	"27c8e7feada80c75b70b9c2f6088d519", // simon2dos (English)
+	"465eed710cc242b2de7dc77edd467c4c", // simon1dos (English)
+	"bed9134804d96f72afa152b8ec5628c3", // simon1dos (French)
+};
+
 SimonEngine::SimonEngine(GameDetector *detector, OSystem *syst)
 	: Engine(syst), midi(syst) {
 
@@ -302,11 +308,6 @@
 		}
 		ConfMan.flushToDisk();
 	} else {
-#if 1
-		// HACK HACK HACK
-		// This is not how, and where, MD5 computation should be done in the
-		// real world. Rather this is meant as a proof-of-concept hack. 
-		// It's quick, it's dirty, and it'll go again eventually :-)
 		char buf[100];
 		uint8 md5sum[16];
 		File f;
@@ -322,6 +323,11 @@
 				sprintf(md5str + j*2, "%02x", (int)md5sum[j]);
 			}
 
+			for (int j = 0; j < 3; j++) {
+				if (!strcmp(md5str, bad_versions[j]))
+					error("Cracked version aren't supported");
+			}
+
 			printf("%s  %s\n", md5str, buf);
 			const MD5Table *elem;
 			elem = (const MD5Table *)bsearch(md5str, md5table, ARRAYSIZE(md5table)-1, sizeof(MD5Table), compareMD5Table);
@@ -331,7 +337,6 @@
 			else
 				printf("Unknown MD5! Please report the details (language, platform, etc.) of this game to the ScummVM team\n");
 		}
-#endif
 	}
 
 	VGA_DELAY_BASE = 1;





More information about the Scummvm-git-logs mailing list