mirror of
https://github.com/TerryCavanagh/VVVVVV.git
synced 2026-01-29 09:28:15 +03:00
Only reset fade booleans when music is actually played
Otherwise, the block that fades existing music out if m_doFadeOutVol is true will never execute, because m_doFadeOutVol would always be false!
This commit is contained in:
@@ -202,9 +202,6 @@ void musicclass::play(int t)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
m_doFadeInVol = false;
|
|
||||||
m_doFadeOutVol = false;
|
|
||||||
|
|
||||||
if (currentsong == 0 || currentsong == 7 || (!map.custommode && (currentsong == 0+num_mmmmmm_tracks || currentsong == 7+num_mmmmmm_tracks)))
|
if (currentsong == 0 || currentsong == 7 || (!map.custommode && (currentsong == 0+num_mmmmmm_tracks || currentsong == 7+num_mmmmmm_tracks)))
|
||||||
{
|
{
|
||||||
// Level Complete theme, no fade in or repeat
|
// Level Complete theme, no fade in or repeat
|
||||||
@@ -214,6 +211,8 @@ void musicclass::play(int t)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
m_doFadeInVol = false;
|
||||||
|
m_doFadeOutVol = false;
|
||||||
musicVolume = MIX_MAX_VOLUME;
|
musicVolume = MIX_MAX_VOLUME;
|
||||||
Mix_VolumeMusic(musicVolume);
|
Mix_VolumeMusic(musicVolume);
|
||||||
}
|
}
|
||||||
@@ -242,6 +241,8 @@ void musicclass::play(int t)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
m_doFadeInVol = false;
|
||||||
|
m_doFadeOutVol = false;
|
||||||
fadeMusicVolumeIn(3000);
|
fadeMusicVolumeIn(3000);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user