/// <summary> /// Creates all of the modifiers to be used on-screen /// </summary> private void CreateModifierOptions() { ModsList = new List <DrawableModifier>() { new DrawableModifierSpeed(this) { Alignment = Alignment.TopLeft }, new DrawableModifierBool(this, new ModMirror()) { Alignment = Alignment.TopLeft }, new DrawableModifierBool(this, new ModAutoplay()) { Alignment = Alignment.TopLeft, }, new DrawableModifierBool(this, new ModNoFail()) { Alignment = Alignment.TopLeft, }, new DrawableModifierBool(this, new ModNoSliderVelocities()) { Alignment = Alignment.TopLeft, }, new DrawableModifierModList(this, new IGameplayModifier[] { new ModNoLongNotes(), new ModInverse(), new ModFullLN() }, "Long Note Conversion", "Mix up the long notes.") { Alignment = Alignment.TopLeft, }, new DrawableModifierBool(this, new ModRandomize()) { Alignment = Alignment.TopLeft, }, }; for (var i = 0; i < ModsList.Count; i++) { var mod = ModsList[i]; ModifierContainer.AddContainedDrawable(mod); mod.Y = i * mod.Height; } var proposedHeight = ModsList.Count * ModsList.First().Height; if (proposedHeight > ModifierContainer.ContentContainer.Height) { ModifierContainer.ContentContainer.Height = proposedHeight; } }
/// <summary> /// Creates all of the modifiers to be used on-screen /// </summary> private void CreateModifierOptions() { ModsList = new List <DrawableModifier>() { new DrawableModifierSpeed(this) { Alignment = Alignment.TopLeft }, new DrawableModifierBool(this, new ModAutoplay()) { Alignment = Alignment.TopLeft, }, new DrawableModifierBool(this, new ModNoFail()) { Alignment = Alignment.TopLeft, }, new DrawableModifierBool(this, new ModNoSliderVelocities()) { Alignment = Alignment.TopLeft, }, new DrawableModifierBool(this, new ModNoLongNotes()) { Alignment = Alignment.TopLeft, }, }; for (var i = 0; i < ModsList.Count; i++) { var mod = ModsList[i]; ModifierContainer.AddContainedDrawable(mod); mod.Y = i * mod.Height; } var proposedHeight = ModsList.Count * ModsList.First().Height; if (proposedHeight > ModifierContainer.ContentContainer.Height) { ModifierContainer.ContentContainer.Height = proposedHeight; } }
/// <summary> /// Creates all of the modifiers to be used on-screen /// </summary> private void CreateModifierOptions() { ModsList = new List <DrawableModifier>() { new DrawableModifierSpeed(this) { Alignment = Alignment.TopLeft }, new DrawableModifierJudgementWindows(this, new ModJudgementWindows()) { Alignment = Alignment.TopLeft }, new DrawableModifierBool(this, new ModMirror()) { Alignment = Alignment.TopLeft }, new DrawableModifierBool(this, new ModAutoplay()) { Alignment = Alignment.TopLeft, }, new DrawableModifierBool(this, new ModNoFail()) { Alignment = Alignment.TopLeft, }, new DrawableModifierBool(this, new ModNoSliderVelocities()) { Alignment = Alignment.TopLeft, }, new DrawableModifierModList(this, new IGameplayModifier[] { new ModNoLongNotes(), new ModInverse(), new ModFullLN() }, "Long Note Conversion", "Mix up the long notes.") { Alignment = Alignment.TopLeft, }, new DrawableModifierBool(this, new ModRandomize()) { Alignment = Alignment.TopLeft, }, }; for (var i = ModsList.Count - 1; i >= 0; i--) { if (ModsList[i] is DrawableModifierBool mod) { if (!mod.Modifier.AllowedInMultiplayer && OnlineManager.CurrentGame != null) { ModsList.Remove(ModsList[i]); continue; } } if (ModsList[i] is DrawableModifierModList modList) { if (modList.Modifiers.Any(x => x.OnlyMultiplayerHostCanCanChange) && OnlineManager.CurrentGame != null && OnlineManager.CurrentGame.HostId != OnlineManager.Self.OnlineUser.Id) { ModsList.Remove(ModsList[i]); } } } for (var i = 0; i < ModsList.Count; i++) { var mod = ModsList[i]; ModifierContainer.AddContainedDrawable(mod); mod.Y = i * mod.Height; } var proposedHeight = ModsList.Count * ModsList.First().Height; if (proposedHeight > ModifierContainer.ContentContainer.Height) { ModifierContainer.ContentContainer.Height = proposedHeight; } }