hedgewars/uGearsHandlersRope.pas
changeset 7608 94d071054a23
parent 7607 0cae2a3e562c
child 7609 7663a5c614cb
equal deleted inserted replaced
7607:0cae2a3e562c 7608:94d071054a23
    87             end
    87             end
    88         until (i = 8) or not stuck;
    88         until (i = 8) or not stuck;
    89         HHGear^.Y:= HHGear^.Y-int2hwFloat(pred(i));
    89         HHGear^.Y:= HHGear^.Y-int2hwFloat(pred(i));
    90         // experiment in simulating something the shoppa players apparently expect
    90         // experiment in simulating something the shoppa players apparently expect
    91         if Gear^.Message and gmDown <> 0 then
    91         if Gear^.Message and gmDown <> 0 then
    92             HHGear^.dY.QWordValue:= _0_0002.QWordValue;
    92             HHGear^.dY:= HHGear^.dY / 8;
    93         if Gear^.Message and gmRight <> 0 then
    93         if Gear^.Message and gmRight <> 0 then
    94             HHGear^.dX.isNegative:= false
    94             HHGear^.dX.isNegative:= false
    95         else if Gear^.Message and gmLeft <> 0 then
    95         else if Gear^.Message and gmLeft <> 0 then
    96             HHGear^.dX.isNegative:= true
    96             HHGear^.dX.isNegative:= true
    97         end
    97         end
   104             stuck:= TestCollisionYwithGear(HHGear, i) <> 0
   104             stuck:= TestCollisionYwithGear(HHGear, i) <> 0
   105             end
   105             end
   106         until (i = -8) or not stuck;
   106         until (i = -8) or not stuck;
   107         HHGear^.Y:= HHGear^.Y-int2hwFloat(succ(i));
   107         HHGear^.Y:= HHGear^.Y-int2hwFloat(succ(i));
   108         if Gear^.Message and gmDown <> 0 then
   108         if Gear^.Message and gmDown <> 0 then
   109             HHGear^.dY.QWordValue:= _0_0002.QWordValue;
   109             HHGear^.dY:= HHGear^.dY / 8;
   110         if Gear^.Message and gmRight <> 0 then
   110         if Gear^.Message and gmRight <> 0 then
   111             HHGear^.dX.isNegative:= false
   111             HHGear^.dX.isNegative:= false
   112         else if Gear^.Message and gmLeft <> 0 then
   112         else if Gear^.Message and gmLeft <> 0 then
   113             HHGear^.dX.isNegative:= true
   113             HHGear^.dX.isNegative:= true
   114         end;
   114         end;