diff options
Diffstat (limited to 'Penguloon/SoundManager.cs')
| -rw-r--r-- | Penguloon/SoundManager.cs | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/Penguloon/SoundManager.cs b/Penguloon/SoundManager.cs index 92ba973..ddc32fa 100644 --- a/Penguloon/SoundManager.cs +++ b/Penguloon/SoundManager.cs @@ -10,6 +10,8 @@ namespace Penguloon public static SoundEffectInstance BtnClick3 { get; set; } public static SoundEffectInstance PlaceObject { get; set; } public static SoundEffectInstance GameOver { get; set; } + public static SoundEffectInstance Upgrade { get; set; } + public static SoundEffectInstance Unavailable { get; set; } public static void StartBaseline() { @@ -85,6 +87,32 @@ namespace Penguloon GameOver.Play(); } + public static void PlayUpgradeSound() + { + if (Upgrade == null) + { + SoundEffect effect = ContentManager.GetSound("Sounds/upgrade"); + Upgrade = effect.CreateInstance(); + Upgrade.Volume = 1f; + Upgrade.IsLooped = false; + } + + Upgrade.Play(); + } + + public static void PlayUnavailableSound() + { + if (Unavailable == null) + { + SoundEffect effect = ContentManager.GetSound("Sounds/unavailable"); + Unavailable = effect.CreateInstance(); + Unavailable.Volume = 1f; + Unavailable.IsLooped = false; + } + + Unavailable.Play(); + } + public static void PlayBalloonPopSound() { SoundEffect popEffect = ContentManager.GetSound("Sounds/pop"); |
