mirror of
https://github.com/ppy/osu.git
synced 2025-01-18 10:53:21 +08:00
Fix incorrect lastPattern
value
In particular, mania-specific beatmaps that normally go via the "passthrough" generator should not adjust the stored pattern value. The "spinner" generator, which was previously intended to be used for non-mania-specific beatmaps, is now valid even for mania-specific beatmaps, and uses this value. In other words, another way of writing this would be: ```csharp if (conversion is SpinnerPatternGenerator || conversion is PassThroughPatternGenerator) ? lastPattern : newPattern; ```
This commit is contained in:
parent
12e5999700
commit
d597232c2a
@ -220,8 +220,11 @@ namespace osu.Game.Rulesets.Mania.Beatmaps
|
||||
|
||||
foreach (var newPattern in conversion.Generate())
|
||||
{
|
||||
lastPattern = conversion is SpinnerPatternGenerator ? lastPattern : newPattern;
|
||||
lastStair = (conversion as HitCirclePatternGenerator)?.StairType ?? lastStair;
|
||||
if (conversion is HitCirclePatternGenerator circleGenerator)
|
||||
lastStair = circleGenerator.StairType;
|
||||
|
||||
if (conversion is HitCirclePatternGenerator || conversion is SliderPatternGenerator)
|
||||
lastPattern = newPattern;
|
||||
|
||||
foreach (var obj in newPattern.HitObjects)
|
||||
yield return obj;
|
||||
|
Loading…
Reference in New Issue
Block a user