Play different bounce sound for rubber duck
authorWuzzy <almikes@aol.com>
Mon, 10 Apr 2017 13:30:44 +0200
changeset 12213 9a4831b23cd1
parent 12212 2de020695c20
child 12214 7e6362c0ba96
Play different bounce sound for rubber duck
hedgewars/uGearsUtils.pas
--- a/hedgewars/uGearsUtils.pas	Sun Apr 09 20:54:33 2017 +0200
+++ b/hedgewars/uGearsUtils.pas	Mon Apr 10 13:30:44 2017 +0200
@@ -1606,7 +1606,10 @@
             Scale:= hwFloat2Float(Gear^.Density * hwAbs(Gear^.dY) + hwAbs(Gear^.dX)) / 1.5;
             State:= ord(sprBoing)
             end;
-    PlaySound(sndMelonImpact, true)
+    if Gear^.Kind = gtDuck then
+        PlaySound(sndDuckDrop, true);
+    else
+        PlaySound(sndMelonImpact, true)
 end;
 
 function IsHogLocal(HH: PHedgehog): boolean;