Skip to content

Commit

Permalink
Disable #cncnet channel from dropdowon
Browse files Browse the repository at this point in the history
  • Loading branch information
GrantBartlett committed Jan 8, 2025
1 parent aea7126 commit 6b0365a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
4 changes: 3 additions & 1 deletion ClientCore/CnCNet5/GameCollection.cs
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,8 @@ public void Initialize()
};

// CnCNet chat.
CnCNetGame[] otherGames =
CnCNetGame[] otherGames = [];
/*
{
new()
{
Expand All @@ -208,6 +209,7 @@ public void Initialize()
Texture = AssetLoader.TextureFromImage(cncnetIcon)
}
};
*/

GameList.AddRange(defaultGames);
GameList.AddRange(GetCustomGames(defaultGames.Concat(otherGames).ToList()));
Expand Down
3 changes: 2 additions & 1 deletion DXMainClient/DXGUI/Multiplayer/CnCNet/CnCNetLobby.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1190,7 +1190,8 @@ private void ConnectionManager_WelcomeMessageReceived(object sender, EventArgs e
tbChatInput.Enabled = true;

Channel cncnetChannel = connectionManager.FindChannel("#cncnet");
cncnetChannel.Join();
if (cncnetChannel != null)
cncnetChannel.Join();

string localGameChatChannelName = gameCollection.GetGameChatChannelNameFromIdentifier(localGameID);
connectionManager.FindChannel(localGameChatChannelName).Join();
Expand Down

0 comments on commit 6b0365a

Please sign in to comment.