diff -r a3531b520efb -r a7810074c20d hedgewars/uLandGenTemplateBased.pas --- a/hedgewars/uLandGenTemplateBased.pas Fri Nov 23 16:20:55 2018 -0500 +++ b/hedgewars/uLandGenTemplateBased.pas Fri Nov 23 16:38:47 2018 -0500 @@ -367,7 +367,7 @@ hasBorder:= true; for y:= 0 to LAND_HEIGHT - 1 do for x:= 0 to LAND_WIDTH - 1 do - if (y < topY) or (x < leftX) or (x > rightX) then + if (y < LongWord(topY)) or (x < LongWord(leftX)) or (x > LongWord(rightX)) then Land[y, x]:= 0 else begin