mirror of
https://github.com/ppy/osu.git
synced 2024-12-15 06:52:56 +08:00
Merge pull request #10925 from peppy/fix-multiple-playback-on-skin-change
Fix skinnable sounds playing more than once on skin change
This commit is contained in:
commit
cdc7ef8c15
@ -102,7 +102,7 @@ namespace osu.Game.Skinning
|
||||
sampleContainer.Add(Sample = new DrawableSample(ch) { Looping = Looping });
|
||||
|
||||
// Start playback internally for the new sample if the previous one was playing beforehand.
|
||||
if (wasPlaying)
|
||||
if (wasPlaying && Looping)
|
||||
Play();
|
||||
}
|
||||
|
||||
|
@ -159,7 +159,7 @@ namespace osu.Game.Skinning
|
||||
samplesContainer.Add(sample);
|
||||
}
|
||||
|
||||
if (wasPlaying)
|
||||
if (wasPlaying && Looping)
|
||||
Play();
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user