summaryrefslogtreecommitdiff
path: root/src/sound.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/sound.cpp')
-rw-r--r--src/sound.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/sound.cpp b/src/sound.cpp
index cf77cfab..063195ae 100644
--- a/src/sound.cpp
+++ b/src/sound.cpp
@@ -126,7 +126,7 @@ void Sound::setSfxVolume(int volume)
Mix_Volume(-1, volume);
}
-void Sound::playMusic(const std::string &path, int loop)
+void Sound::playMusic(const std::string &filename, int loop)
{
if (!mInstalled) return;
@@ -134,6 +134,9 @@ void Sound::playMusic(const std::string &path, int loop)
stopMusic();
}
+ ResourceManager *resman = ResourceManager::getInstance();
+ std::string path = resman->getPath("music/" + filename);
+
logger->log("Sound::startMusic() Playing \"%s\" %i times", path.c_str(),
loop);