diff --git a/include/Core/Engine.h b/include/Core/Engine.h index a54d500..364e218 100755 --- a/include/Core/Engine.h +++ b/include/Core/Engine.h @@ -98,7 +98,7 @@ public: m_FrameStack->Width = 675; m_FrameStack->Height = 1080; - if (ResourceManager::Load("Config.ini")->GetValue("Debug.SkipStory") == 1) { + if (ResourceManager::Load("Config.ini")->GetValue("Debug.SkipStory", 0) == 1) { Events::GameStart e; m_EventBroker->Publish(e); auto hud = new GUI::HUD(m_FrameStack, "HUD"); diff --git a/include/Sound/SoundSystem.h b/include/Sound/SoundSystem.h index 8892577..950a020 100644 --- a/include/Sound/SoundSystem.h +++ b/include/Sound/SoundSystem.h @@ -8,6 +8,7 @@ #include "Core/World.h" #include "Core/EventBroker.h" #include "Core/ResourceManager.h" +#include "Core/ConfigFile.h" #include "Sound.h" #include "Sound/EPlaySound.h" #include "Sound/EStopSound.h" diff --git a/src/game/Sound/SoundSystem.cpp b/src/game/Sound/SoundSystem.cpp index c11d84e..b96f327 100644 --- a/src/game/Sound/SoundSystem.cpp +++ b/src/game/Sound/SoundSystem.cpp @@ -27,6 +27,9 @@ void dd::Systems::SoundSystem::Initialize() EVENT_SUBSCRIBE_MEMBER(m_EStopSound, &SoundSystem::OnStopSound); EVENT_SUBSCRIBE_MEMBER(m_EMasterVolume, &SoundSystem::OnMasterVolume); + m_SFXMasterVolume = ResourceManager::Load("Config.ini")->GetValue("Audio.SFXVolume", 1.f); + m_BGMMasterVolume = ResourceManager::Load("Config.ini")->GetValue("Audio.BGMVolume", 1.f); + //Todo: Move this { dd::Events::PlaySound e;