diff --git a/ZoFo/Content/Content.mgcb b/ZoFo/Content/Content.mgcb index b3a43e3..cee7455 100644 --- a/ZoFo/Content/Content.mgcb +++ b/ZoFo/Content/Content.mgcb @@ -56,6 +56,24 @@ #begin MapData/TileSets/TilesetNature.tsj /copy:MapData/TileSets/TilesetNature.tsj +#begin sounds/Background menu music.wav +/importer:WavImporter +/processor:SoundEffectProcessor +/processorParam:Quality=Best +/build:sounds/Background menu music.wav + +#begin sounds/Button click.wav +/importer:WavImporter +/processor:SoundEffectProcessor +/processorParam:Quality=Best +/build:sounds/Button click.wav + +#begin sounds/Craft sound.wav +/importer:WavImporter +/processor:SoundEffectProcessor +/processorParam:Quality=Best +/build:sounds/Craft sound.wav + #begin sounds/Loot.wav /importer:WavImporter /processor:SoundEffectProcessor diff --git a/ZoFo/Content/sounds/Background menu music.wav b/ZoFo/Content/sounds/Background menu music.wav new file mode 100644 index 0000000..ece5b88 Binary files /dev/null and b/ZoFo/Content/sounds/Background menu music.wav differ diff --git a/ZoFo/Content/sounds/Button click.wav b/ZoFo/Content/sounds/Button click.wav new file mode 100644 index 0000000..ee91234 Binary files /dev/null and b/ZoFo/Content/sounds/Button click.wav differ diff --git a/ZoFo/Content/sounds/Craft sound.wav b/ZoFo/Content/sounds/Craft sound.wav new file mode 100644 index 0000000..9ca7686 Binary files /dev/null and b/ZoFo/Content/sounds/Craft sound.wav differ diff --git a/ZoFo/GameCore/GUI/BaseGUI.cs b/ZoFo/GameCore/GUI/BaseGUI.cs index d46ac63..ed2b745 100644 --- a/ZoFo/GameCore/GUI/BaseGUI.cs +++ b/ZoFo/GameCore/GUI/BaseGUI.cs @@ -142,6 +142,7 @@ public class BaseGUI : AbstractGUI ItemDisplayButtonsList.Add(temp); temp.LeftButtonPressed += () => { + AppManager.Instance.SoundManager.StartAmbientSound("Craft sound"); AppManager.Instance.playerData.CraftItem(item.Key); AppManager.Instance.SetGUI(new BaseGUI()); }; @@ -163,7 +164,9 @@ public class BaseGUI : AbstractGUI textureName = "Textures\\GUI\\checkboxs_off" }; Elements.Add(bTExit); - bTExit.LeftButtonPressed += () => { AppManager.Instance.SetGUI(new MainMenuGUI()); }; + bTExit.LeftButtonPressed += () => { AppManager.Instance.SetGUI(new MainMenuGUI()); + AppManager.Instance.SoundManager.StartAmbientSound("Button click"); + }; } public override void Update(GameTime gameTime) diff --git a/ZoFo/GameCore/GUI/MainMenuGUI.cs b/ZoFo/GameCore/GUI/MainMenuGUI.cs index 645faf8..c0e1a38 100644 --- a/ZoFo/GameCore/GUI/MainMenuGUI.cs +++ b/ZoFo/GameCore/GUI/MainMenuGUI.cs @@ -40,7 +40,7 @@ public class MainMenuGUI : AbstractGUI }; playButton.LeftButtonPressed += () => { - AppManager.Instance.SoundManager.StartAmbientSound("Loot"); + AppManager.Instance.SoundManager.StartAmbientSound("Button click"); AppManager.Instance.SetGUI(new SelectModeMenu()); }; Elements.Add(playButton); @@ -55,6 +55,7 @@ public class MainMenuGUI : AbstractGUI }; baseButton.LeftButtonPressed += () => { + AppManager.Instance.SoundManager.StartAmbientSound("Button click"); AppManager.Instance.SetGUI(new BaseGUI()); }; Elements.Add(baseButton); @@ -69,7 +70,7 @@ public class MainMenuGUI : AbstractGUI }; optionButton.LeftButtonPressed += () => { - AppManager.Instance.SoundManager.StartAmbientSound("Loot"); + AppManager.Instance.SoundManager.StartAmbientSound("Button click"); AppManager.Instance.SetGUI(new OptionsGUI()); }; Elements.Add(optionButton); diff --git a/ZoFo/GameCore/GUI/OptionsGUI.cs b/ZoFo/GameCore/GUI/OptionsGUI.cs index 39db371..e0920d3 100644 --- a/ZoFo/GameCore/GUI/OptionsGUI.cs +++ b/ZoFo/GameCore/GUI/OptionsGUI.cs @@ -43,6 +43,7 @@ public class OptionsGUI : AbstractGUI label_OverallVolume_Percent.text = Math.Round(slider_OverallVolume.GetSliderValue * 100) + "%"; slider_OverallVolume.SliderChanged += (newVal) => { + label_OverallVolume_Percent.text = Math.Round(slider_OverallVolume.GetSliderValue * 100) + "%"; AppManager.Instance.SettingsManager.SetMainVolume(newVal); }; @@ -64,6 +65,7 @@ public class OptionsGUI : AbstractGUI label_MusicVolume_Percent.text = Math.Round(slider_MusicVolume.GetSliderValue * 100) + "%"; slider_MusicVolume.SliderChanged += (newVal) => { + label_MusicVolume_Percent.text = Math.Round(slider_MusicVolume.GetSliderValue * 100) + "%"; AppManager.Instance.SettingsManager.SetMusicVolume(newVal); }; @@ -85,6 +87,7 @@ public class OptionsGUI : AbstractGUI label_EffectsVolume_Percent.text = Math.Round(slider_EffectsVolume.GetSliderValue * 100) + "%"; slider_EffectsVolume.SliderChanged += (newVal) => { + label_EffectsVolume_Percent.text = Math.Round(slider_EffectsVolume.GetSliderValue * 100) + "%"; AppManager.Instance.SettingsManager.SetSoundEffectsVolume(newVal); }; @@ -109,6 +112,7 @@ public class OptionsGUI : AbstractGUI button_FullScreen.SetIsChecked(AppManager.Instance.SettingsManager.IsFullScreen); button_FullScreen.Checked += (newCheckState) => { + AppManager.Instance.SoundManager.StartAmbientSound("Button click"); AppManager.Instance.SettingsManager.SetIsFullScreen(newCheckState); }; Elements.Add(button_FullScreen); @@ -120,6 +124,7 @@ public class OptionsGUI : AbstractGUI Elements.Add(bTExit); bTExit.LeftButtonPressed += () => { + AppManager.Instance.SoundManager.StartAmbientSound("Button click"); AppManager.Instance.SetGUI(new MainMenuGUI()); }; diff --git a/ZoFo/GameCore/GUI/PauseGUI.cs b/ZoFo/GameCore/GUI/PauseGUI.cs index d316fb7..7356036 100644 --- a/ZoFo/GameCore/GUI/PauseGUI.cs +++ b/ZoFo/GameCore/GUI/PauseGUI.cs @@ -31,6 +31,7 @@ public class PauseGUI : AbstractGUI }; continueButton.LeftButtonPressed += () => { + AppManager.Instance.SoundManager.StartAmbientSound("Button click"); AppManager.Instance.SetGUI(new HUD()); }; Elements.Add(continueButton); @@ -45,6 +46,7 @@ public class PauseGUI : AbstractGUI }; exitButton.LeftButtonPressed += () => { + AppManager.Instance.SoundManager.StartAmbientSound("Button click"); AppManager.Instance.SetGUI(new MainMenuGUI()); }; Elements.Add(exitButton); diff --git a/ZoFo/GameCore/GUI/SelectModeMenu.cs b/ZoFo/GameCore/GUI/SelectModeMenu.cs index 5b1320b..efa15f6 100644 --- a/ZoFo/GameCore/GUI/SelectModeMenu.cs +++ b/ZoFo/GameCore/GUI/SelectModeMenu.cs @@ -38,6 +38,7 @@ public class SelectModeMenu : AbstractGUI }; singleButton.LeftButtonPressed += () => { + AppManager.Instance.SoundManager.StartAmbientSound("Button click"); // single Server server = new Server(); Client client = new Client(); @@ -68,6 +69,7 @@ public class SelectModeMenu : AbstractGUI }; optionButton.LeftButtonPressed += () => { + AppManager.Instance.SoundManager.StartAmbientSound("Button click"); AppManager.Instance.SetGUI(new SelectingServerGUI()); // multi @@ -80,6 +82,7 @@ public class SelectModeMenu : AbstractGUI Elements.Add(bTExit); bTExit.LeftButtonPressed += () => { + AppManager.Instance.SoundManager.StartAmbientSound("Button click"); AppManager.Instance.SetGUI(new MainMenuGUI()); }; }