Change ComboColours type to IReadOnlyList<Color4>

Also exposes functions to modify the internal list (AddComboColours, ClearComboColours)
This commit is contained in:
iiSaLMaN
2019-11-07 15:54:30 +03:00
parent 41515e9e6c
commit 808543885f
8 changed files with 36 additions and 21 deletions

View File

@ -265,7 +265,7 @@ namespace osu.Game.Rulesets.Objects.Drawables
{
if (HitObject is IHasComboInformation combo)
{
var comboColours = CurrentSkin.GetConfig<GlobalSkinConfiguration, List<Color4>>(GlobalSkinConfiguration.ComboColours)?.Value;
var comboColours = CurrentSkin.GetConfig<GlobalSkinConfiguration, IReadOnlyList<Color4>>(GlobalSkinConfiguration.ComboColours)?.Value;
AccentColour.Value = comboColours?.Count > 0 ? comboColours[combo.ComboIndex % comboColours.Count] : Color4.White;
}
}