fixed: websocket server wrong execution thread

This commit is contained in:
2022-12-25 03:13:01 -08:00
parent f34b05e6ff
commit e9418f4b22
10 changed files with 110 additions and 109 deletions
+2 -2
View File
@@ -37,7 +37,7 @@ public class Application : INetworkListener
if (configuration.ServerType == "websocket")
_server = new NativeWebSocketServer(_executor);
Debug.Assert(_server != null, $"Socket type not supported: {configuration.ServerType}. Supported: [enet, websocket]");
}
@@ -48,7 +48,7 @@ public class Application : INetworkListener
_executor.Execute();
_loop.Tick();
_server.Poll();
Thread.Sleep((int)1000.0f / _configuration.ServerTickRate);
}
}