From 20869dad6b806225f330f58452cff144e6e28674 Mon Sep 17 00:00:00 2001 From: Vectozavr <60608292+vectozavr@users.noreply.github.com> Date: Sun, 31 Oct 2021 01:35:46 +0700 Subject: [PATCH] add debug info in ResourceManager & SoundController & Time & Timeline --- engine/SoundController.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/engine/SoundController.cpp b/engine/SoundController.cpp index 16c330c..e01ffe2 100644 --- a/engine/SoundController.cpp +++ b/engine/SoundController.cpp @@ -70,11 +70,12 @@ sf::Sound::Status SoundController::getStatus(const SoundTag& soundTag) { void SoundController::free() { if(_validInstance) { for(auto& [soundTag, sound] : _instance->_sounds) { - stopSound(soundTag); + _instance->_sounds[soundTag].stop(); + Log::log("SoundController::stopSound(): sound '" + soundTag.str() + "' was stopped"); } + _instance->_sounds.clear(); } - _instance->_sounds.clear(); _validInstance = false; delete _instance;