Skip to content

Commit 20a9746

Browse files
committed
[修改]1. 修改连接到发现中心的链接器
1 parent 74e98c1 commit 20a9746

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

GameFrameX.Hotfix/StartUp/AppStartUpHotfixGameByMain.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ public override async Task StartAsync()
2222
{
2323
// 启动网络服务
2424
await StartServerAsync<ClientMessageDecoderHandler, ClientMessageEncoderHandler>(new DefaultMessageCompressHandler(), new DefaultMessageDecompressHandler());
25-
StartServer();
2625
// 启动Http服务
2726
// await HttpServer.Start(Setting.HttpPort, Setting.HttpsPort, HotfixManager.GetHttpHandler);
2827
await base.StartAsync();

GameFrameX.Launcher/StartUp/AppStartUpService.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ public override Task StartAsync()
3636
_discoveryCenterChannelHelper?.Start(Setting.DiscoveryCenterIp, Setting.DiscoveryCenterPort);
3737
}
3838

39+
GlobalSettings.IsAppRunning = true;
3940
return Task.CompletedTask;
4041
}
4142

@@ -63,8 +64,7 @@ protected ConnectChannelHelper DiscoveryCenterChannelHelper
6364

6465
protected async void StartServer()
6566
{
66-
// _discoveryCenterChannelHelper = new ConnectChannelHelper(Setting, MessageEncoderHandler, MessageDecoderHandler, DiscoveryCenterMessageHandler);
67-
GlobalSettings.IsAppRunning = true;
67+
_discoveryCenterChannelHelper = new ConnectChannelHelper(Setting, MessageEncoderHandler, MessageDecoderHandler, DiscoveryCenterMessageHandler);
6868
}
6969

7070
private void DiscoveryCenterMessageHandler(IMessage message)

0 commit comments

Comments
 (0)