# HG changeset patch # User nemo # Date 1362060505 18000 # Node ID 6bd1950de78bbdac8ee9165b2141a3b6a26af693 # Parent 9d21bab30893ed701bb3ad2700603b550173c312 aaagh. remove dead code. again. diff -r 9d21bab30893 -r 6bd1950de78b hedgewars/GSHandlers.inc --- a/hedgewars/GSHandlers.inc Wed Feb 27 21:30:33 2013 -0500 +++ b/hedgewars/GSHandlers.inc Thu Feb 28 09:08:25 2013 -0500 @@ -5091,70 +5091,6 @@ end; end; - -function isLandscapeEdge(weight:Longint):boolean; -begin - result := (weight < 8) and (weight >= 2); -end; - -function isLandscape(weight:Longint):boolean; -begin - result := weight < 2; -end; - -function isEmptySpace(weight:Longint):boolean; -begin - result := not isLandscape(weight) and not isLandscapeEdge(weight); -end; - - -function getPixelWeight(x, y:Longint): Longint; -var - i, j:Longint; -begin - result := 0; - for i := x - 1 to x + 1 do - for j := y - 1 to y + 1 do - begin - if (i < 0) or - (i > LAND_WIDTH - 1) or - (j < 0) or - (j > LAND_HEIGHT -1) or - ((Land[j, i] and $FF00) = 0) then - begin - result := result + 1; - end; - end; -end; - - -procedure drawIcePixel(x, y:Longint); -var - iceSurface: PSDL_Surface; - icePixels: PLongwordArray; - pictureX, pictureY: LongInt; - w, c: LongWord; -begin - if Land[y, x] and lfIce <> 0 then exit; -// So. 3 parameters here. Ice colour, Ice opacity, and a bias on the greyscaled pixel towards lightness - iceSurface:= SpritesData[sprIceTexture].Surface; - pictureX := x mod iceSurface^.w; - pictureY := y mod iceSurface^.h; - icePixels := iceSurface^.pixels; - w:= LandPixels[y, x]; - w:= round(((w shr RShift and $FF) * RGB_LUMINANCE_RED + - (w shr BShift and $FF) * RGB_LUMINANCE_GREEN + - (w shr GShift and $FF) * RGB_LUMINANCE_BLUE)); - if w < 128 then w:= w+128; - if w > 255 then w:= 255; - w:= (w shl RShift) or (w shl BShift) or (w shl GShift) or (LandPixels[y,x] and AMask); - //LandPixels[y, x]:= w; - LandPixels[y, x]:= addBgColor(w, IceColor); - LandPixels[y, x]:= addBgColor(LandPixels[y, x], icePixels^[iceSurface^.w * (y mod iceSurface^.h) + (x mod iceSurface^.w)]); - - Land[y, x] := Land[y, x] or lfIce; -end; - procedure DrawIce(x, y: Longint); const iceRadius :Longint = 32; var