- Fixed: S_ChangeMusic() would not necessarily restart non-looping songs that had finished playing.

SVN r3462 (trunk)
This commit is contained in:
Randy Heit 2012-03-22 21:09:20 +00:00
parent c53c8f29e7
commit 78d28dedda
2 changed files with 8 additions and 0 deletions

View file

@ -2379,6 +2379,10 @@ bool S_ChangeMusic (const char *musicname, int order, bool looping, bool force)
mus_playing.baseorder = order;
}
}
else if (!mus_playing.handle->IsPlaying())
{
mus_playing.handle->Play(looping, order);
}
return true;
}

View file

@ -518,6 +518,10 @@ void MIDIStreamer::Stop()
bool MIDIStreamer::IsPlaying()
{
if (EndQueued != 0 && EndQueued < 4)
{
Stop();
}
return m_Status != STATE_Stopped;
}