diff --git a/src/lua_maplib.c b/src/lua_maplib.c index ba255ee1..35542fdc 100644 --- a/src/lua_maplib.c +++ b/src/lua_maplib.c @@ -1491,9 +1491,7 @@ static int mapheaderinfo_get(lua_State *L) if (!header->interscreen[i]) break; lua_pushlstring(L, header->interscreen, i); - } else if (fastcmp(field,"musicinterfadeout")) - lua_pushinteger(L, header->musicinterfadeout); - else if (fastcmp(field,"runsoc")) + } else if (fastcmp(field,"runsoc")) lua_pushstring(L, header->runsoc); else if (fastcmp(field,"scriptname")) lua_pushstring(L, header->scriptname); diff --git a/src/p_user.c b/src/p_user.c index 0dcc654a..97ee04a2 100644 --- a/src/p_user.c +++ b/src/p_user.c @@ -8828,7 +8828,7 @@ void P_PlayerThink(player_t *player) // so we can fade music if (!exitfadestarted && player->exiting > 0 && player->exiting <= 1*TICRATE && - (!multiplayer || gametype == GT_COOP ? !mapheaderinfo[gamemap-1]->musicinterfadeout : true) && + (!multiplayer || gametype == GT_COOP ? !mapheaderinfo[gamemap-1]->musinterfadeout : true) && // don't fade if we're fading during intermission. follows Y_StartIntermission intertype = int_coop (gametype == GT_RACE || gametype == GT_COMPETITION ? countdown2 == 0 : true) && // don't fade on timeout player->lives > 0 && // don't fade on game over (competition) diff --git a/src/y_inter.c b/src/y_inter.c index 1b7796ef..ed4972d2 100644 --- a/src/y_inter.c +++ b/src/y_inter.c @@ -697,7 +697,12 @@ void Y_Ticker(void) if (!intertic) // first time only { - if (mapheaderinfo[gamemap-1]->musinterfadeout) + if (mapheaderinfo[gamemap-1]->musinterfadeout +#ifdef _WIN32 + // can't fade midi due to win32 volume hack + && S_MusicType() != MU_MID +#endif + ) S_FadeOutStopMusic(mapheaderinfo[gamemap-1]->musinterfadeout); else if (mapheaderinfo[gamemap-1]->musintername[0] && S_MusicExists(mapheaderinfo[gamemap-1]->musintername, !midi_disabled, !digital_disabled)) S_ChangeMusicInternal(mapheaderinfo[gamemap-1]->musintername, false); // don't loop it @@ -764,7 +769,12 @@ void Y_Ticker(void) if (!intertic) // first time only { - if (mapheaderinfo[gamemap-1]->musinterfadeout) + if (mapheaderinfo[gamemap-1]->musinterfadeout +#ifdef _WIN32 + // can't fade midi due to win32 volume hack + && S_MusicType() != MU_MID +#endif + ) S_FadeOutStopMusic(mapheaderinfo[gamemap-1]->musinterfadeout); else if (mapheaderinfo[gamemap-1]->musintername[0] && S_MusicExists(mapheaderinfo[gamemap-1]->musintername, !midi_disabled, !digital_disabled)) S_ChangeMusicInternal(mapheaderinfo[gamemap-1]->musintername, false); // don't loop it