diff options
author | Eugene Sandulenko | 2005-10-13 23:20:41 +0000 |
---|---|---|
committer | Eugene Sandulenko | 2005-10-13 23:20:41 +0000 |
commit | bd4340f21abe19c05d6b5a3d8cd95fa6b0e3502a (patch) | |
tree | 634a859292f43fb68c4291c15d568992c544fc72 /scumm | |
parent | 7664cbcc7434ebd3e349b7ffc60b38381b7750d3 (diff) | |
download | scummvm-rg350-bd4340f21abe19c05d6b5a3d8cd95fa6b0e3502a.tar.gz scummvm-rg350-bd4340f21abe19c05d6b5a3d8cd95fa6b0e3502a.tar.bz2 scummvm-rg350-bd4340f21abe19c05d6b5a3d8cd95fa6b0e3502a.zip |
Add possibility to see exact md5s of your game and save when they don't
match. It's on debuglevel 1.
svn-id: r19069
Diffstat (limited to 'scumm')
-rw-r--r-- | scumm/saveload.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/scumm/saveload.cpp b/scumm/saveload.cpp index 3b426358c7..409b713a3f 100644 --- a/scumm/saveload.cpp +++ b/scumm/saveload.cpp @@ -926,7 +926,13 @@ void ScummEngine::saveOrLoad(Serializer *s, uint32 savegameVersion) { // MD5 Operations: Backup on load, compare, and reset. if (s->isLoading()) if (memcmp(md5Backup, _gameMD5, 16) != 0) { + char md5str1[32+1], md5str2[32+1]; + for (j = 0; j < 16; j++) { + sprintf(md5str1 + j*2, "%02x", (int)_gameMD5[j]); + sprintf(md5str2 + j*2, "%02x", (int)md5Backup[j]); + } warning("Game was saved with different gamedata - you may encounter problems."); + debug(1, "You have %s and save is %s.", md5str2, md5str1); memcpy(_gameMD5, md5Backup, 16); } |