# HG changeset patch # User Wuzzy # Date 1560617464 -7200 # Node ID 490bd70dac6ef2d3106ce04d50a67a050066699d # Parent 84e98f0f7f7b38d446a5507256350954adffb07e Drawn maps: Fix off-by-one errors in land erasing code diff -r 84e98f0f7f7b -r 490bd70dac6e hedgewars/uLandPainted.pas --- a/hedgewars/uLandPainted.pas Sat Jun 15 18:15:32 2019 +0200 +++ b/hedgewars/uLandPainted.pas Sat Jun 15 18:51:04 2019 +0200 @@ -131,9 +131,9 @@ end; if (topY > 0) then - EraseLandRectRaw(0, 0, LAND_WIDTH, topY - 1); + EraseLandRectRaw(0, 0, LAND_WIDTH, topY); if (leftX > 0) then - EraseLandRectRaw(0, topY, leftX - 1, LAND_HEIGHT - topY); + EraseLandRectRaw(0, topY, leftX, LAND_HEIGHT - topY); if (rightX < (LAND_WIDTH - 1)) then EraseLandRectRaw(rightX + 1, topY, LAND_WIDTH - (rightX + 1), LAND_HEIGHT - topY); end;