hedgewars/HHHandlers.inc
changeset 1528 3fee15104c1d
parent 1519 7b6adbe5266a
child 1573 cf88e0ace609
equal deleted inserted replaced
1527:4a610e970b66 1528:3fee15104c1d
   353       if not (TestCollisionXwithXYShift(Gear, _0, -2, hwSign(Gear^.dX))
   353       if not (TestCollisionXwithXYShift(Gear, _0, -2, hwSign(Gear^.dX))
   354          or TestCollisionYwithGear(Gear, -1)) then Gear^.Y:= Gear^.Y - _1;
   354          or TestCollisionYwithGear(Gear, -1)) then Gear^.Y:= Gear^.Y - _1;
   355       if not (TestCollisionXwithXYShift(Gear, _0, -1, hwSign(Gear^.dX))
   355       if not (TestCollisionXwithXYShift(Gear, _0, -1, hwSign(Gear^.dX))
   356          or TestCollisionYwithGear(Gear, -1)) then Gear^.Y:= Gear^.Y - _1;
   356          or TestCollisionYwithGear(Gear, -1)) then Gear^.Y:= Gear^.Y - _1;
   357       end;
   357       end;
       
   358 
   358    if not TestCollisionXwithGear(Gear, hwSign(Gear^.dX)) then Gear^.X:= Gear^.X + SignAs(_1, Gear^.dX);
   359    if not TestCollisionXwithGear(Gear, hwSign(Gear^.dX)) then Gear^.X:= Gear^.X + SignAs(_1, Gear^.dX);
   359 
       
   360    SetAllHHToActive;
   360    SetAllHHToActive;
   361 
   361 
   362    if not TestCollisionYwithGear(Gear, 1) then
   362    if not TestCollisionYwithGear(Gear, 1) then
   363    begin
   363    begin
   364    Gear^.Y:= Gear^.Y + _1;
   364    Gear^.Y:= Gear^.Y + _1;