# HG changeset patch # User nemo # Date 1508885719 14400 # Node ID df9d9d19406ae354631a1e2f5c725c01d04b5f68 # Parent 49c31d8cc740bc2ca582f5c5e2ec152bb11f051a w is in pixels, so presumably this needs to be *4 diff -r 49c31d8cc740 -r df9d9d19406a hedgewars/uLandObjects.pas --- a/hedgewars/uLandObjects.pas Tue Oct 24 18:28:59 2017 -0400 +++ b/hedgewars/uLandObjects.pas Tue Oct 24 18:55:19 2017 -0400 @@ -262,7 +262,7 @@ girSurf:= LoadDataImageAltPath(ptCurrTheme, ptGraphics, 'Girder', ifCritical or ifColorKey or ifIgnoreCaps); for y := 0 to girsurf^.h-1 do - syncedPixelDigest:= Adler32Update(syncedPixelDigest, @PByteArray(girsurf^.pixels)^[y*girsurf^.pitch], girsurf^.w); + syncedPixelDigest:= Adler32Update(syncedPixelDigest, @PByteArray(girsurf^.pixels)^[y*girsurf^.pitch], girsurf^.w*4); girderHeight:= girSurf^.h; @@ -699,7 +699,7 @@ if (Maxcnt < 1) or (Maxcnt > MAXTHEMEOBJECTS) then OutError('Object''s max count should be between 1 and '+ inttostr(MAXTHEMEOBJECTS) +' (it was '+ inttostr(Maxcnt) +').', true); for y := 0 to Surf^.h-1 do - syncedPixelDigest:= Adler32Update(syncedPixelDigest, @PByteArray(Surf^.pixels)^[y*Surf^.pitch], Surf^.w); + syncedPixelDigest:= Adler32Update(syncedPixelDigest, @PByteArray(Surf^.pixels)^[y*Surf^.pitch], Surf^.w*4); inrectcnt := 0; diff -r 49c31d8cc740 -r df9d9d19406a hedgewars/uStore.pas --- a/hedgewars/uStore.pas Tue Oct 24 18:28:59 2017 -0400 +++ b/hedgewars/uStore.pas Tue Oct 24 18:55:19 2017 -0400 @@ -473,7 +473,7 @@ {$ELSE} if checkSum then for y := 0 to tmpsurf^.h-1 do - syncedPixelDigest:= Adler32Update(syncedPixelDigest, @PByteArray(tmpsurf^.pixels)^[y*tmpsurf^.pitch], tmpsurf^.w); + syncedPixelDigest:= Adler32Update(syncedPixelDigest, @PByteArray(tmpsurf^.pixels)^[y*tmpsurf^.pitch], tmpsurf^.w*4); if saveSurf then Surface:= tmpsurf