hedgewars/uLandGraphics.pas
changeset 4640 bc30434ae156
parent 4635 62d0873459e5
child 4659 ce5897f53072
--- a/hedgewars/uLandGraphics.pas	Wed Dec 22 21:57:52 2010 -0500
+++ b/hedgewars/uLandGraphics.pas	Wed Dec 22 23:46:07 2010 -0500
@@ -198,7 +198,7 @@
            else
                LandPixels[t div 2, i div 2]:= LandBackPixel(i, t)
            end
-       else if not isMap then
+       else if not isMap or ((Land[t, i] and lfObject) <> 0) then
            begin
            if (cReducedQuality and rqBlurryLand) = 0 then
                LandPixels[t, i]:= 0
@@ -217,7 +217,7 @@
            else
                LandPixels[t div 2, i div 2]:= LandBackPixel(i, t)
            end
-       else if not isMap then
+       else if not isMap or ((Land[t, i] and lfObject) <> 0) then
            begin
            if (cReducedQuality and rqBlurryLand) = 0 then
                LandPixels[t, i]:= 0
@@ -236,12 +236,12 @@
            else
                LandPixels[t div 2, i div 2]:= LandBackPixel(i, t)
            end
-       else if not isMap then
+       else if not isMap or ((Land[t, i] and lfObject) <> 0) then
             begin
             if (cReducedQuality and rqBlurryLand) = 0 then
-          	LandPixels[t, i]:= 0
+          	    LandPixels[t, i]:= 0
             else
-           	LandPixels[t div 2, i div 2]:= 0
+           	    LandPixels[t div 2, i div 2]:= 0
             end;
 
 t:= y - dx;
@@ -255,7 +255,7 @@
            else
                LandPixels[t div 2, i div 2]:= LandBackPixel(i, t)
            end
-       else if not isMap then
+       else if not isMap or ((Land[t, i] and lfObject) <> 0) then
            begin
            if (cReducedQuality and rqBlurryLand) = 0 then
                LandPixels[t, i]:= 0
@@ -507,11 +507,10 @@
        ((Land[ty, tx] and (lfBasic or lfObject)) <> 0) then
         begin
         Land[ty, tx]:= Land[ty, tx] or lfDamaged;
-        if (cReducedQuality and rqBlurryLand) = 0 then
-	    LandPixels[ty, tx]:= cExplosionBorderColor
-	else
+        if (cReducedQuality and rqBlurryLand) = 0 then 
+            LandPixels[ty, tx]:= cExplosionBorderColor
+	    else
             LandPixels[ty div 2, tx div 2]:= cExplosionBorderColor
-
         end
     end;
     X:= nx;
@@ -529,9 +528,9 @@
                     LandPixels[ty, tx]:= LandBackPixel(tx, ty)
                 else
                     LandPixels[ty div 2, tx div 2]:= LandBackPixel(tx, ty)
-            else if not isMap then
+            else if not isMap or ((Land[ty, tx] and lfObject) <> 0) then
                 begin
-		if (cReducedQuality and rqBlurryLand) = 0 then
+                if (cReducedQuality and rqBlurryLand) = 0 then
                      LandPixels[ty, tx]:= 0
                 else
                      LandPixels[ty div 2, tx div 2]:= 0
@@ -693,13 +692,13 @@
             begin
             if (Land[Y, X] and lfBasic) <> 0 then
                 LandPixels[Y, X]:= LandBackPixel(X, Y)
-            else if not isMap then
+            else if not isMap or ((Land[Y, X] and lfObject) <> 0) then
                 LandPixels[Y, X]:= 0
             end
         else
             if (Land[Y, X] and lfBasic) <> 0 then
                 LandPixels[Y div 2, X div 2]:= LandBackPixel(X, Y)
-            else if not isMap then
+            else if not isMap or ((Land[Y, X] and lfObject) <> 0) then
                 LandPixels[Y div 2, X div 2]:= 0;
 
         Land[Y, X]:= 0;