mirror of
https://github.com/OpenMW/openmw.git
synced 2025-06-24 11:11:34 +00:00
Stop trying to play non-existent music files started by scripts
This commit is contained in:
parent
ec6451e93a
commit
4a6464ea67
1 changed files with 10 additions and 1 deletions
|
@ -224,7 +224,16 @@ namespace MWSound
|
||||||
stopMusic();
|
stopMusic();
|
||||||
|
|
||||||
DecoderPtr decoder = getDecoder();
|
DecoderPtr decoder = getDecoder();
|
||||||
decoder->open(filename);
|
try
|
||||||
|
{
|
||||||
|
decoder->open(filename);
|
||||||
|
}
|
||||||
|
catch(std::exception &e)
|
||||||
|
{
|
||||||
|
Log(Debug::Error) << "Failed to load audio from " << filename << ": " << e.what();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
mMusic = getStreamRef();
|
mMusic = getStreamRef();
|
||||||
mMusic->init([&] {
|
mMusic->init([&] {
|
||||||
|
|
Loading…
Reference in a new issue