File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -177,9 +177,12 @@ bool MusicMan::CyclePlayingSoundContainers(bool smoothFade) {
177
177
// Clone instead of just point to because we might wanna keep this around even if the DynamicSong is gone
178
178
m_CurrentSoundContainer = std::unique_ptr<SoundContainer>(dynamic_cast <SoundContainer*>(m_NextSoundContainer->Clone ()));
179
179
SelectNextSoundContainer ();
180
-
181
- double timeUntilNextShouldBePlayed = std::max (0 .0F , m_CurrentSoundContainer->GetMusicExitTime () - m_NextSoundContainer->GetMusicPreEntryTime ());
182
180
m_MusicTimer.Reset ();
181
+ float exitTime = m_CurrentSoundContainer->GetMusicExitTime ();
182
+ if (exitTime == 0 .0F ) {
183
+ exitTime = m_CurrentSoundContainer->GetLength (SoundContainer::LengthOfSoundType::NextPlayed);
184
+ }
185
+ double timeUntilNextShouldBePlayed = std::max (0 .0F , exitTime - m_NextSoundContainer->GetMusicPreEntryTime ());
183
186
m_MusicTimer.SetRealTimeLimitMS (timeUntilNextShouldBePlayed);
184
187
m_CurrentSoundContainer->Play ();
185
188
m_CurrentSongSectionType = m_NextSongSectionType;
You can’t perform that action at this time.
0 commit comments