From 3fb41a20b55aa7e2d5270195e1a182dec18ed80b Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Fri, 11 Dec 2020 13:27:52 +0900 Subject: [PATCH] Add room name to settings --- .../Online/RealtimeMultiplayer/MultiplayerRoomSettings.cs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/osu.Game/Online/RealtimeMultiplayer/MultiplayerRoomSettings.cs b/osu.Game/Online/RealtimeMultiplayer/MultiplayerRoomSettings.cs index 8f0f4febd1..a5dcafefcd 100644 --- a/osu.Game/Online/RealtimeMultiplayer/MultiplayerRoomSettings.cs +++ b/osu.Game/Online/RealtimeMultiplayer/MultiplayerRoomSettings.cs @@ -18,11 +18,13 @@ namespace osu.Game.Online.RealtimeMultiplayer public int? RulesetID { get; set; } + public string Name { get; set; } = "Unnamed room"; + [NotNull] public IEnumerable Mods { get; set; } = Enumerable.Empty(); - public bool Equals(MultiplayerRoomSettings other) => BeatmapID == other.BeatmapID && Mods.SequenceEqual(other.Mods) && RulesetID == other.RulesetID; + public bool Equals(MultiplayerRoomSettings other) => BeatmapID == other.BeatmapID && Mods.SequenceEqual(other.Mods) && RulesetID == other.RulesetID && Name.Equals(other.Name, StringComparison.Ordinal); - public override string ToString() => $"Beatmap:{BeatmapID} Mods:{string.Join(',', Mods)} Ruleset:{RulesetID}"; + public override string ToString() => $"Name:{Name} Beatmap:{BeatmapID} Mods:{string.Join(',', Mods)} Ruleset:{RulesetID}"; } }