mirror of
https://github.com/osukey/osukey.git
synced 2025-06-25 05:07:59 +09:00
Fix chat channel ids not being updated on room creation
This commit is contained in:
parent
00cdb3a44a
commit
ee076bbbe3
@ -124,6 +124,7 @@ namespace osu.Game.Online.Multiplayer
|
|||||||
if (other.Host.Value != null && Host.Value?.Id != other.Host.Value.Id)
|
if (other.Host.Value != null && Host.Value?.Id != other.Host.Value.Id)
|
||||||
Host.Value = other.Host.Value;
|
Host.Value = other.Host.Value;
|
||||||
|
|
||||||
|
ChannelId.Value = other.ChannelId.Value;
|
||||||
Status.Value = other.Status.Value;
|
Status.Value = other.Status.Value;
|
||||||
Availability.Value = other.Availability.Value;
|
Availability.Value = other.Availability.Value;
|
||||||
Type.Value = other.Type.Value;
|
Type.Value = other.Type.Value;
|
||||||
|
@ -28,13 +28,15 @@ namespace osu.Game.Screens.Multi.Match.Components
|
|||||||
{
|
{
|
||||||
base.LoadComplete();
|
base.LoadComplete();
|
||||||
|
|
||||||
roomId.BindValueChanged(_ => updateChannel(), true);
|
channelId.BindValueChanged(_ => updateChannel(), true);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void updateChannel()
|
private void updateChannel()
|
||||||
{
|
{
|
||||||
if (roomId.Value != null)
|
if (roomId.Value == null || channelId.Value == 0)
|
||||||
Channel.Value = channelManager?.JoinChannel(new Channel { Id = channelId.Value, Type = ChannelType.Multiplayer, Name = $"#mp_{roomId.Value}" });
|
return;
|
||||||
|
|
||||||
|
Channel.Value = channelManager?.JoinChannel(new Channel { Id = channelId.Value, Type = ChannelType.Multiplayer, Name = $"#lazermp_{roomId.Value}" });
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user