hedgewars/uAIMisc.pas
changeset 8810 b885b995aa95
parent 8777 cce79a042cfc
child 8833 c13ebed437cb
child 8845 8cf1ed3bae45
--- a/hedgewars/uAIMisc.pas	Thu Mar 28 18:34:30 2013 +0200
+++ b/hedgewars/uAIMisc.pas	Thu Mar 28 18:34:53 2013 +0200
@@ -266,7 +266,7 @@
         MeX:= hwRound(Me^.X);
         MeY:= hwRound(Me^.Y);
         // We are still inside the hog. Skip radius test
-        if ((((x-MeX)*(x-MeX)) + ((y-MeY)*(y-MeY))) < 256) and (Land[y, x] <= lfAllObjMask) then
+        if ((((x-MeX)*(x-MeX)) + ((y-MeY)*(y-MeY))) < 256) and (Land[y, x] <= lfAllObjMask) and ((Land[y, x] and lfObjMask) < 2) then
             exit(false);
     end;
     TestCollExcludingMe:= TestColl(x, y, r)