hedgewars/uCollisions.pas
changeset 4684 1b2bbc86af5b
parent 4403 0dfe26f48ec1
child 4705 593ef1ad3cd3
equal deleted inserted replaced
4682:0fc1ff341482 4684:1b2bbc86af5b
   101 ga.Count:= 0;
   101 ga.Count:= 0;
   102 if Count = 0 then exit;
   102 if Count = 0 then exit;
   103 mx:= hwRound(Gear^.X);
   103 mx:= hwRound(Gear^.X);
   104 my:= hwRound(Gear^.Y);
   104 my:= hwRound(Gear^.Y);
   105 
   105 
   106 tr:= Gear^.Radius + 2;
   106 tr:= Gear^.Radius;
   107 
   107 
   108 for i:= 0 to Pred(Count) do
   108 for i:= 0 to Pred(Count) do
   109     with cinfos[i] do
   109     with cinfos[i] do
   110         if (Gear <> cGear) and
   110         if (Gear <> cGear) and
   111             (sqr(mx - x) + sqr(my - y) <= sqr(Radius + tr)) then
   111             (sqr(mx - x) + sqr(my - y) <= sqr(Radius + tr)) then