Add sounds for blowtorch, invuln., f. saucer, lasersight, portal gun
authorWuzzy <almikes@aol.com>
Sat, 19 Nov 2016 06:43:44 +0100
changeset 11911 6145efcff302
parent 11910 245163aa3674
child 11912 d3a852554aa7
Add sounds for blowtorch, invuln., f. saucer, lasersight, portal gun
CREDITS
hedgewars/uGearsHandlersMess.pas
hedgewars/uGearsHedgehog.pas
hedgewars/uSound.pas
hedgewars/uTypes.pas
share/hedgewars/Data/Sounds/blowtorch.ogg
share/hedgewars/Data/Sounds/invulnerable.ogg
share/hedgewars/Data/Sounds/jetpackboost.ogg
share/hedgewars/Data/Sounds/lasersight.ogg
share/hedgewars/Data/Sounds/portalopen.ogg
share/hedgewars/Data/Sounds/portalshot.ogg
share/hedgewars/Data/Sounds/portalswitch.ogg
--- a/CREDITS	Thu Nov 17 15:29:16 2016 +0100
+++ b/CREDITS	Sat Nov 19 06:43:44 2016 +0100
@@ -81,5 +81,17 @@
      http://www.freesound.org/people/uair01/sounds/65291/
 - Air mine impact sound by Wuzzy (WTFPL), based on
      http://www.freesound.org/people/batchku/sounds/10479/
+- Laser Sight sound originally from drzhn (CC-0), remixed from
+     https://www.freesound.org/people/drzhnn/sounds/199938/
+- Flying Saucer boost sound originally by Jagadamba (CC-BY 3.0), remixed from
+     https://www.freesound.org/people/Jagadamba/sounds/257057/
+- Blowtorch sound originally by rombard (CC-0), remixed from
+     https://www.freesound.org/people/rombart/sounds/197800/
+- Portable Portal Device color switching sound by Wuzzy (WTFPL)
+- Portable Portal Device shot sound originally by bubaproducer (CC-BY 3.0), remixed from
+     https://www.freesound.org/people/bubaproducer/sounds/151026/ 
+- Portal opening sound by Wuzzy (WTFPL)
+- Invulnerable sound: remix based on a sound by pepingrillin (CC-0)
+     https://www.freesound.org/people/pepingrillin/sounds/252079/
 
 ALL OTHER CONTENT IS PROPERTY OF Andrey Korotaev <unC0Rr@gmail.com> UNLESS OTHERWISE SPECIFIED
--- a/hedgewars/uGearsHandlersMess.pas	Thu Nov 17 15:29:16 2016 +0100
+++ b/hedgewars/uGearsHandlersMess.pas	Sat Nov 19 06:43:44 2016 +0100
@@ -1594,6 +1594,7 @@
 
     if Gear^.Hedgehog^.Gear = nil then
         begin
+        StopSoundChan(Gear^.SoundChannel);
         DeleteGear(Gear);
         AfterAttack;
         exit
@@ -1671,6 +1672,7 @@
     if (TurnTimeLeft = 0) or (Gear^.Timer = 0)
     or ((HHGear^.Message and gmAttack) <> 0) then
         begin
+        StopSoundChan(Gear^.SoundChannel);
         HHGear^.Message := 0;
         HHGear^.State := HHGear^.State and (not gstNotKickable);
         DeleteGear(Gear);
@@ -1695,6 +1697,7 @@
         cHHStepTicks, cHHRadius * 2 + 7);
     HHGear^.Message := 0;
     HHGear^.State := HHGear^.State or gstNotKickable;
+    Gear^.SoundChannel := LoopSound(sndBlowTorch);
     Gear^.doStep := @doStepBlowTorchWork
 end;
 
@@ -3888,7 +3891,11 @@
                             bubble^.dY:= random(20)/10+0.1;
                         end
                     end
-                else HHGear^.dY := HHGear^.dY - move;
+                else
+                    begin
+                    PlaySound(sndJetpackBoost);
+                    HHGear^.dY := HHGear^.dY - move;
+                    end
                 end;
             dec(Gear^.Health, fuel);
             Gear^.MsgParam := Gear^.MsgParam or gmUp;
@@ -3914,7 +3921,8 @@
                         else bubble^.X := bubble^.X - 28;
                         end;
                     end
-                end;
+                end
+            else PlaySound(sndJetpackBoost);
             dec(Gear^.Health, fuel div 5);
             Gear^.MsgParam := Gear^.MsgParam or (HHGear^.Message and (gmLeft or gmRight));
             Gear^.Timer := GameTicks
@@ -3995,6 +4003,8 @@
     Gear^.doStep := @doStepJetpackWork;
 
     HHGear := Gear^.Hedgehog^.Gear;
+
+    PlaySound(sndJetpackLaunch);
     FollowGear := HHGear;
     AfterAttack;
     with HHGear^ do
@@ -4254,6 +4264,7 @@
             with CurrentHedgehog^ do
                 if (CurAmmoType = amPortalGun) then
                     begin
+                    PlaySound(sndPortalSwitch);
                     CurrentHedgehog^.Gear^.Message := CurrentHedgehog^.Gear^.Message and (not gmSwitch);
 
                     CurWeapon:= GetCurAmmoEntry(CurrentHedgehog^);
@@ -4665,6 +4676,7 @@
         if ((Gear^.LinkedGear = nil)
         or (hwRound(Distance(Gear^.X - Gear^.LinkedGear^.X,Gear^.Y-Gear^.LinkedGear^.Y)) >=Gear^.Radius*2)) then
             begin
+            PlaySound(sndPortalOpen);
             loadNewPortalBall(Gear, false);
             inc(Gear^.Tag);
             Gear^.doStep := @doStepPortal;
@@ -4707,6 +4719,8 @@
 
     newPortal^.LinkedGear := nil;
 
+    PlaySound(sndPortalShot);
+
     if CurrentHedgehog <> nil then
         with CurrentHedgehog^ do
             begin
--- a/hedgewars/uGearsHedgehog.pas	Thu Nov 17 15:29:16 2016 +0100
+++ b/hedgewars/uGearsHedgehog.pas	Sat Nov 19 06:43:44 2016 +0100
@@ -385,12 +385,18 @@
                                  PlaySound(sndHellishImpact4);
                                  cDamageModifier:= _1_5
                                  end;
-                 amInvulnerable: Effects[heInvulnerable]:= 1;
+                 amInvulnerable: begin
+                                 PlaySound(sndInvulnerable);
+                                 Effects[heInvulnerable]:= 1
+                                 end;
                     amExtraTime: begin
                                  PlaySound(sndExtraTime);
                                  TurnTimeLeft:= TurnTimeLeft + 30000
                                  end;
-                   amLaserSight: cLaserSighting:= true;
+                   amLaserSight: begin
+                                 PlaySound(sndLaserSight);
+                                 cLaserSighting:= true
+                                 end;
                      amVampiric: begin
                                  PlaySoundV(sndOw1, Team^.voicepack);
                                  cVampiric:= true;
--- a/hedgewars/uSound.pas	Thu Nov 17 15:29:16 2016 +0100
+++ b/hedgewars/uSound.pas	Sat Nov 19 06:43:44 2016 +0100
@@ -255,7 +255,15 @@
             (FileName:           'hog_freeze.ogg'; Path: ptSounds; AltPath: ptNone), // sndHogFreeze
             (FileName:       'airmine_impact.ogg'; Path: ptSounds; AltPath: ptNone),// sndAirMineImpact
             (FileName:         'knife_impact.ogg'; Path: ptSounds; AltPath: ptNone),// sndKnifeImpact
-            (FileName:            'extratime.ogg'; Path: ptSounds; AltPath: ptNone) // sndExtraTime
+            (FileName:            'extratime.ogg'; Path: ptSounds; AltPath: ptNone),// sndExtraTime
+            (FileName:           'lasersight.ogg'; Path: ptSounds; AltPath: ptNone),// sndLaserSight
+            (FileName:         'invulnerable.ogg'; Path: ptSounds; AltPath: ptNone),// sndInvulnerable
+            (FileName:                  'ufo.ogg'; Path: ptSounds; AltPath: ptNone),// sndJetpackLaunch
+            (FileName:         'jetpackboost.ogg'; Path: ptSounds; AltPath: ptNone),// sndJetpackBoost
+            (FileName:           'portalshot.ogg'; Path: ptSounds; AltPath: ptNone),// sndPortalShot
+            (FileName:         'portalswitch.ogg'; Path: ptSounds; AltPath: ptNone),// sndPortalSwitch
+            (FileName:           'portalopen.ogg'; Path: ptSounds; AltPath: ptNone),// sndPortalOpen
+            (FileName:            'blowtorch.ogg'; Path: ptSounds; AltPath: ptNone) // sndBlowTorch
             );
 
 
--- a/hedgewars/uTypes.pas	Thu Nov 17 15:29:16 2016 +0100
+++ b/hedgewars/uTypes.pas	Sat Nov 19 06:43:44 2016 +0100
@@ -145,7 +145,9 @@
             sndPiano0, sndPiano1, sndPiano2, sndPiano3, sndPiano4, sndPiano5, sndPiano6, sndPiano7,
             sndPiano8, sndSkip, sndSineGun, sndOoff1, sndOoff2, sndOoff3, sndWhack,
             sndComeonthen, sndParachute, sndBump, sndResurrector, sndPlane, sndTardis, sndFrozenHogImpact,
-            sndIceBeam, sndHogFreeze, sndAirMineImpact, sndKnifeImpact, sndExtraTime
+            sndIceBeam, sndHogFreeze, sndAirMineImpact, sndKnifeImpact, sndExtraTime, sndLaserSight,
+            sndInvulnerable, sndJetpackLaunch, sndJetpackBoost, sndPortalShot, sndPortalSwitch,
+            sndPortalOpen, sndBlowTorch
             );
 
     // Available ammo types to be used by hedgehogs
Binary file share/hedgewars/Data/Sounds/blowtorch.ogg has changed
Binary file share/hedgewars/Data/Sounds/invulnerable.ogg has changed
Binary file share/hedgewars/Data/Sounds/jetpackboost.ogg has changed
Binary file share/hedgewars/Data/Sounds/lasersight.ogg has changed
Binary file share/hedgewars/Data/Sounds/portalopen.ogg has changed
Binary file share/hedgewars/Data/Sounds/portalshot.ogg has changed
Binary file share/hedgewars/Data/Sounds/portalswitch.ogg has changed