hedgewars/uGearsHandlersMess.pas
changeset 12196 d7ccd18ae7bf
parent 12194 ac9cf0cf40ee
child 12198 f770c8029f7c
equal deleted inserted replaced
12195:98b31009fc37 12196:d7ccd18ae7bf
  4393             end
  4393             end
  4394         else
  4394         else
  4395             if not ((Gear^.dX*ox + Gear^.dY*oy).isNegative) then
  4395             if not ((Gear^.dX*ox + Gear^.dY*oy).isNegative) then
  4396                 continue;
  4396                 continue;
  4397 
  4397 
       
  4398         if iterator^.Kind = gtDuck then
       
  4399             iterator^.Pos:= 0;
       
  4400 
  4398         isbullet:= (iterator^.Kind in [gtShotgunShot, gtDEagleShot, gtSniperRifleShot, gtSineGunShot]);
  4401         isbullet:= (iterator^.Kind in [gtShotgunShot, gtDEagleShot, gtSniperRifleShot, gtSineGunShot]);
  4399 
  4402 
  4400         r:= int2hwFloat(iterator^.Radius);
  4403         r:= int2hwFloat(iterator^.Radius);
  4401 
  4404 
  4402         if not (isbullet or iscake) then
  4405         if not (isbullet or iscake) then
  6372             begin
  6375             begin
  6373             PlaySound(sndDroplet2);
  6376             PlaySound(sndDroplet2);
  6374             if Gear^.dY > _0_4 then
  6377             if Gear^.dY > _0_4 then
  6375                 PlaySound(sndDuckWater);
  6378                 PlaySound(sndDuckWater);
  6376             Gear^.Pos:= 1;
  6379             Gear^.Pos:= 1;
  6377             Gear^.Timer:= Gear^.WDTimer;
       
  6378             Gear^.dY:= _0;
  6380             Gear^.dY:= _0;
  6379             Gear^.State:= Gear^.State or gstNoGravity;
       
  6380             end;
  6381             end;
  6381         end
  6382         end
  6382 
  6383 
  6383     // Manual speed handling when duck is on water (Pos <> 0)
  6384     // Manual speed handling when duck is on water (Pos <> 0)
  6384     else
  6385     else