forked from teamnwah/openmw-tes3coop
Fix streamMusic's path lookup
This commit is contained in:
parent
fc27d5cc19
commit
e48745b68e
2 changed files with 8 additions and 2 deletions
|
@ -155,7 +155,7 @@ namespace MWSound
|
||||||
mMusic.reset();
|
mMusic.reset();
|
||||||
}
|
}
|
||||||
|
|
||||||
void SoundManager::streamMusic(const std::string& filename)
|
void SoundManager::streamMusicFull(const std::string& filename)
|
||||||
{
|
{
|
||||||
std::cout <<"Playing "<<filename<< std::endl;
|
std::cout <<"Playing "<<filename<< std::endl;
|
||||||
try
|
try
|
||||||
|
@ -170,6 +170,11 @@ namespace MWSound
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void SoundManager::streamMusic(const std::string& filename)
|
||||||
|
{
|
||||||
|
streamMusicFull("Music/"+filename);
|
||||||
|
}
|
||||||
|
|
||||||
void SoundManager::startRandomTitle()
|
void SoundManager::startRandomTitle()
|
||||||
{
|
{
|
||||||
Ogre::StringVectorPtr filelist;
|
Ogre::StringVectorPtr filelist;
|
||||||
|
@ -179,7 +184,7 @@ namespace MWSound
|
||||||
return;
|
return;
|
||||||
|
|
||||||
int i = rand()%filelist->size();
|
int i = rand()%filelist->size();
|
||||||
streamMusic((*filelist)[i]);
|
streamMusicFull((*filelist)[i]);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool SoundManager::isMusicPlaying()
|
bool SoundManager::isMusicPlaying()
|
||||||
|
|
|
@ -58,6 +58,7 @@ namespace MWSound
|
||||||
MWWorld::Ptr ptr, const std::string &id,
|
MWWorld::Ptr ptr, const std::string &id,
|
||||||
float volume, float pitch, float min, float max,
|
float volume, float pitch, float min, float max,
|
||||||
bool loop, bool untracked=false);
|
bool loop, bool untracked=false);
|
||||||
|
void streamMusicFull(const std::string& filename);
|
||||||
bool isPlaying(MWWorld::Ptr ptr, const std::string &id) const;
|
bool isPlaying(MWWorld::Ptr ptr, const std::string &id) const;
|
||||||
void updateRegionSound(float duration);
|
void updateRegionSound(float duration);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue