hedgewars/uGearsHandlersMess.pas
changeset 11305 a20f416c91ec
parent 11286 9bd2acb1b577
child 11342 aa3f886c6298
equal deleted inserted replaced
11300:f9fa0d6dc69f 11305:a20f416c91ec
  1958     // TODO: do real calculation?
  1958     // TODO: do real calculation?
  1959     land:= TestCollisionXwithGear(Gear, 2);
  1959     land:= TestCollisionXwithGear(Gear, 2);
  1960     if land = 0 then land:= TestCollisionYwithGear(Gear,-2);
  1960     if land = 0 then land:= TestCollisionYwithGear(Gear,-2);
  1961     if land = 0 then land:= TestCollisionXwithGear(Gear,-2);
  1961     if land = 0 then land:= TestCollisionXwithGear(Gear,-2);
  1962     if land = 0 then land:= TestCollisionYwithGear(Gear, 2);
  1962     if land = 0 then land:= TestCollisionYwithGear(Gear, 2);
  1963     if (land <> 0) and (land and lfBouncy = 0) then
  1963     if (land <> 0) and ((land and lfBouncy = 0) or ((Gear^.State and gstMoving) = 0)) then
  1964         begin
  1964         begin
  1965         if ((Gear^.State and gstMoving) <> 0) or (not isZero(Gear^.dX)) or (not isZero(Gear^.dY)) then
  1965         if ((Gear^.State and gstMoving) <> 0) or (not isZero(Gear^.dX)) or (not isZero(Gear^.dY)) then
  1966             begin
  1966             begin
  1967             PlaySound(sndRopeAttach);
  1967             PlaySound(sndRopeAttach);
  1968             Gear^.dX:= _0;
  1968             Gear^.dX:= _0;