# HG changeset patch
# User unc0rr
# Date 1210282079 0
# Node ID fadfefc2ae4057f02f56a103d8091003944c2b7c
# Parent  c8cff180da576396c7bd69591c6ece446ec47462
It looks like fix for cluster bomb issue...

diff -r c8cff180da57 -r fadfefc2ae40 hedgewars/GSHandlers.inc
--- a/hedgewars/GSHandlers.inc	Thu May 08 20:54:04 2008 +0000
+++ b/hedgewars/GSHandlers.inc	Thu May 08 21:27:59 2008 +0000
@@ -111,6 +111,7 @@
 ////////////////////////////////////////////////////////////////////////////////
 procedure doStepBomb(Gear: PGear);
 var i: LongInt;
+    dX, dY: hwFloat;
 begin
 AllInactive:= false;
 doStepFallingGear(Gear);
@@ -122,7 +123,11 @@
       gtClusterBomb: begin
                      doMakeExplosion(hwRound(Gear^.X), hwRound(Gear^.Y), 20, EXPLAutoSound);
                      for i:= 0 to 4 do
-                         AddGear(hwRound(Gear^.X), hwRound(Gear^.Y), gtCluster, 0, rndSign(GetRandom * _0_1), (GetRandom - _3) * _0_08, 0);
+                         begin
+                         dX:= rndSign(GetRandom * _0_1);
+                         dY:= (GetRandom - _3) * _0_08;
+                         AddGear(hwRound(Gear^.X), hwRound(Gear^.Y), gtCluster, 0, dX, dY, 0);
+                         end
                      end
         end;
    DeleteGear(Gear);