diff --git a/assets/Sounds/jap-story.wav b/assets/Sounds/jap-story.wav new file mode 100644 index 0000000..54fe420 Binary files /dev/null and b/assets/Sounds/jap-story.wav differ diff --git a/include/Game/GUI/LoadingFrame.h b/include/Game/GUI/LoadingFrame.h index 307ca63..98dced7 100644 --- a/include/Game/GUI/LoadingFrame.h +++ b/include/Game/GUI/LoadingFrame.h @@ -5,6 +5,7 @@ #include "GUI/Slider.h" #include "Core/ResourceManager.h" #include "Game/GUI/ELoadingFrameComplete.h" +#include "Sound/EPlaySound.h" namespace dd { @@ -56,6 +57,9 @@ public: e.FrameName = Name(); e.Frame = this; EventBroker->Publish(e); + Events::PlaySound se; + se.FilePath = "Sounds/jap-story.wav"; + EventBroker->Publish(se); } } } diff --git a/include/Sound/SoundSystem.h b/include/Sound/SoundSystem.h index a369ef2..56bd837 100644 --- a/include/Sound/SoundSystem.h +++ b/include/Sound/SoundSystem.h @@ -41,6 +41,7 @@ private: const std::string MENU_BGM = "Sounds/BGM/eastern-music.wav"; const std::string GAME_BGM = "Sounds/BGM/under-the-sea-n.wav"; const std::string WATER_BGM = "Sounds/BGM/water-flowing.wav"; + const std::string STORY_VOICE = "Sounds/jap-story.wav"; float m_BGMMasterVolume = 1.f; float m_SFXMasterVolume = 1.f; diff --git a/src/game/Sound/SoundSystem.cpp b/src/game/Sound/SoundSystem.cpp index fa1283b..afafec3 100644 --- a/src/game/Sound/SoundSystem.cpp +++ b/src/game/Sound/SoundSystem.cpp @@ -188,6 +188,11 @@ bool dd::Systems::SoundSystem::OnContact(const dd::Events::Contact &event) bool dd::Systems::SoundSystem::OnGameStart(const dd::Events::GameStart &event) { + { + dd::Events::StopSound e; + e.FilePath = STORY_VOICE; + EventBroker->Publish(e); + } { dd::Events::StopSound e; e.FilePath = MENU_BGM;