Fix [music] ms_after= setting fade-out time of *previous* track
It's supposed to set the fade-out time of the track *itself*. For this, play_music() needs to look at the track which is *being faded out*, not the one that's *about to start playing*.
This commit is contained in:
parent
85c2928fde
commit
ac6895feaa
1 changed files with 1 additions and 1 deletions
|
@ -585,7 +585,7 @@ void play_music()
|
|||
music_start_time = 1; // immediate (same as effect as SDL_GetTicks())
|
||||
want_new_music = true;
|
||||
no_fading = false;
|
||||
fadingout_time = current_track->ms_after();
|
||||
fadingout_time = previous_track != nullptr ? previous_track->ms_after() : 0;
|
||||
}
|
||||
|
||||
void play_track(unsigned int i)
|
||||
|
|
Loading…
Add table
Reference in a new issue