Add dynamite impact sound
authorWuzzy <Wuzzy2@mail.ru>
Wed, 27 May 2020 06:52:13 +0200
changeset 15587 61f2ffcd5652
parent 15586 19c85b010144
child 15588 96a02e385d54
Add dynamite impact sound
CREDITS
ChangeLog.txt
hedgewars/uGearsHandlersMess.pas
hedgewars/uGearsList.pas
hedgewars/uSound.pas
hedgewars/uTypes.pas
share/hedgewars/Data/Sounds/dynamiteimpact.ogg
--- a/CREDITS	Wed May 27 01:58:27 2020 +0200
+++ b/CREDITS	Wed May 27 06:52:13 2020 +0200
@@ -103,6 +103,8 @@
      https://freesound.org/people/AslakHostaker/sounds/395039/
 - Dynamite fuse: Based off sound by apolloaiello (CC BY 3.0)
      https://freesound.org/people/apolloaiello/sounds/329045/
+- Dynamite bounce: Based off sound by kev_durr (CC BY 3.0)
+     https://freesound.org/people/kev_durr/sounds/426455/
 - Landspray sound originally by Benboncan (CC BY 3.0), remixed from
      https://freesound.org/people/Benboncan/sounds/82390/
 - Portable Portal Device color switching sound by Wuzzy (CC-0)
--- a/ChangeLog.txt	Wed May 27 01:58:27 2020 +0200
+++ b/ChangeLog.txt	Wed May 27 06:52:13 2020 +0200
@@ -1,7 +1,7 @@
 + features
 * bugfixes
 ==================== 1.0.1-dev =====================
- + Add dynamite fuse sound
+ + Add dynamite fuse and impact sounds
  + Various small HUD tweaks
  + Racer: Allow to set turn time in game scheme
  + Racer: Reset mines, air mines and sticky mines every turn
--- a/hedgewars/uGearsHandlersMess.pas	Wed May 27 01:58:27 2020 +0200
+++ b/hedgewars/uGearsHandlersMess.pas	Wed May 27 06:52:13 2020 +0200
@@ -564,7 +564,7 @@
         (((Gear^.Radius < 3) and (Gear^.dY < -_0_1)) or
             ((Gear^.Radius >= 3) and
                 ((Gear^.dX.QWordValue > _0_1.QWordValue) or (Gear^.dY.QWordValue > _0_1.QWordValue)))) then
-        PlaySound(TSound(ord(Gear^.ImpactSound) + LongInt(GetRandom(Gear^.nImpactSounds))), true);
+        PlaySound(TSound(ord(Gear^.ImpactSound) + LongInt(GetRandom(Gear^.nImpactSounds))), Gear^.Kind <> gtDynamite);
 end;
 
 ////////////////////////////////////////////////////////////////////////////////
--- a/hedgewars/uGearsList.pas	Wed May 27 01:58:27 2020 +0200
+++ b/hedgewars/uGearsList.pas	Wed May 27 06:52:13 2020 +0200
@@ -567,6 +567,8 @@
                 gear^.Health:= 50
                 end;
     gtDynamite: begin
+                gear^.ImpactSound:= sndDynamiteImpact;
+                gear^.nImpactSounds:= 1;
                 gear^.Radius:= 3;
                 gear^.Elasticity:= _0_55;
                 gear^.Friction:= _0_03;
--- a/hedgewars/uSound.pas	Wed May 27 01:58:27 2020 +0200
+++ b/hedgewars/uSound.pas	Wed May 27 06:52:13 2020 +0200
@@ -333,7 +333,8 @@
             (FileName:                 'Kiss.ogg'; Path: ptSounds; AltPath: ptNone),// sndKiss
             (FileName:              'Flyaway.ogg'; Path: ptVoices; AltPath: ptNone),// sndFlyAway
             (FileName:           'planewater.ogg'; Path: ptSounds; AltPath: ptNone),// sndPlaneWater
-            (FileName:         'dynamitefuse.ogg'; Path: ptSounds; AltPath: ptNone) // sndDynamiteFuse
+            (FileName:         'dynamitefuse.ogg'; Path: ptSounds; AltPath: ptNone),// sndDynamiteFuse
+            (FileName:       'dynamiteimpact.ogg'; Path: ptSounds; AltPath: ptNone) // sndDynamiteImpact
             );
 
 
--- a/hedgewars/uTypes.pas	Wed May 27 01:58:27 2020 +0200
+++ b/hedgewars/uTypes.pas	Wed May 27 06:52:13 2020 +0200
@@ -158,7 +158,8 @@
             sndLandGun, sndCaseImpact, sndExtraDamage, sndFirePunchHit, sndGrenade, sndThisOneIsMine,
             sndWhatThe, sndSoLong, sndOhDear, sndGonnaGetYou, sndDrat, sndBugger, sndAmazing,
             sndBrilliant, sndExcellent, sndFire, sndWatchThis, sndRunAway, sndRevenge, sndCutItOut,
-            sndLeaveMeAlone, sndOuch, sndHmm, sndKiss, sndFlyAway, sndPlaneWater, sndDynamiteFuse);
+            sndLeaveMeAlone, sndOuch, sndHmm, sndKiss, sndFlyAway, sndPlaneWater, sndDynamiteFuse,
+            sndDynamiteImpact);
 
     // Available ammo types to be used by hedgehogs
     TAmmoType  = (amNothing, amGrenade, amClusterBomb, amBazooka, amBee, amShotgun, amPickHammer, // 6
Binary file share/hedgewars/Data/Sounds/dynamiteimpact.ogg has changed