mirror of
https://github.com/ppy/osu.git
synced 2024-11-06 07:47:25 +08:00
Merge pull request #1602 from smoogipoo/fix-mania-conversion
Fix possible invalid cast when generating mania patterns
This commit is contained in:
commit
5947af13b7
@ -138,8 +138,8 @@ namespace osu.Game.Rulesets.Mania.Beatmaps
|
||||
Pattern newPattern = conversion.Generate();
|
||||
lastPattern = newPattern;
|
||||
|
||||
var stairPatternGenerator = (HitObjectPatternGenerator)conversion;
|
||||
lastStair = stairPatternGenerator.StairType;
|
||||
var stairPatternGenerator = conversion as HitObjectPatternGenerator;
|
||||
lastStair = stairPatternGenerator?.StairType ?? lastStair;
|
||||
|
||||
return newPattern.HitObjects;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user