mirror of
https://github.com/ppy/osu.git
synced 2024-11-15 11:47:24 +08:00
Fix old looping samples not stopping when replacing a SkinnableSound
's Samples
Closes https://github.com/ppy/osu/issues/30365.
This commit is contained in:
parent
53a340938a
commit
1008d32ddb
@ -154,6 +154,9 @@ namespace osu.Game.Skinning
|
||||
{
|
||||
bool wasPlaying = IsPlaying;
|
||||
|
||||
if (wasPlaying && Looping)
|
||||
Stop();
|
||||
|
||||
// Remove all pooled samples (return them to the pool), and dispose the rest.
|
||||
samplesContainer.RemoveAll(s => s.IsInPool, false);
|
||||
samplesContainer.Clear();
|
||||
|
Loading…
Reference in New Issue
Block a user