hedgewars/uGearsUtils.pas
changeset 10274 07adc8b6288c
parent 10272 31ee88c9b4d0
child 10354 56bd029245fc
--- a/hedgewars/uGearsUtils.pas	Tue Jun 10 22:35:44 2014 +0200
+++ b/hedgewars/uGearsUtils.pas	Wed Jun 11 00:35:23 2014 +0400
@@ -654,7 +654,9 @@
                 if (y - sy > Gear^.Radius * 2) and (y < cWaterLine)
                     and (((Gear^.Kind = gtExplosives)
                         and (ignoreNearObjects or NoGearsToAvoid(x, y - Gear^.Radius, 60, 60))
-                        and (isSteadyPosition(x, y+1, Gear^.Radius - 1, 3, $FFFF)))
+                        and (isSteadyPosition(x, y+1, Gear^.Radius - 1, 3, $FFFF)
+                         or (CountNonZeroz(x, y+1, Gear^.Radius - 1, Gear^.Radius+1, $FFFF) > Gear^.Radius)
+                            ))
                     or
                         ((Gear^.Kind <> gtExplosives)
                         and (ignoreNearObjects or NoGearsToAvoid(x, y - Gear^.Radius, 110, 110))