Save and restore music position when changing to a map with the same music defined. DONT_BUILD.

git-svn-id: https://svn.eduke32.com/eduke32@6123 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
terminx 2017-04-24 04:35:13 +00:00
parent 889a0e7fbc
commit 0acdeb93d1

View file

@ -1908,9 +1908,16 @@ int G_EnterLevel(int gameMode)
if (ud.recstat != 2)
{
int32_t const mpos = S_GetMusicPosition();
if (g_mapInfo[mii].musicfn != NULL)
S_PlayMusic(g_mapInfo[mii].musicfn);
if (g_mapInfo[g_musicIndex].musicfn != NULL && g_mapInfo[mii].musicfn != NULL
&& !Bstrcmp(g_mapInfo[g_musicIndex].musicfn, g_mapInfo[mii].musicfn))
S_SetMusicPosition(mpos);
g_musicIndex = mii;
if (g_mapInfo[g_musicIndex].musicfn != NULL)
S_PlayMusic(g_mapInfo[g_musicIndex].musicfn);
}
if (gameMode & (MODE_GAME|MODE_EOL))