hedgewars/uLand.pas
changeset 13822 381e37c6d5d9
parent 13754 f1c66a34f2fe
child 14303 6015b74eea55
--- a/hedgewars/uLand.pas	Tue Sep 18 00:07:36 2018 +0200
+++ b/hedgewars/uLand.pas	Tue Sep 18 19:21:36 2018 -0400
@@ -984,12 +984,14 @@
 
 procedure chSendLandDigest(var s: shortstring);
 var i: LongInt;
+	landPixelDigest  : LongInt;	
 begin
+	landPixelDigest:= 1;
     for i:= 0 to LAND_HEIGHT-1 do
-        syncedPixelDigest:= Adler32Update(syncedPixelDigest, @Land[i,0], LAND_WIDTH*2);
-    s:= 'M' + IntToStr(syncedPixelDigest); // + cScriptName; script name is no longer needed. scripts are hashed
+        landPixelDigest:= Adler32Update(landPixelDigest, @Land[i,0], LAND_WIDTH*2);
+    s:= 'M' + IntToStr(syncedPixelDigest)+'|'+IntToStr(landPixelDigest);
 
-    ScriptSetString('LandDigest', s);
+    ScriptSetString('LandDigest',IntToStr(landPixelDigest));
 
     chLandCheck(s);
     if allOK then SendIPCRaw(@s[0], Length(s) + 1)