diff --git a/Server/Client.cs b/Server/Client.cs index 78a1e02..07cd69d 100644 --- a/Server/Client.cs +++ b/Server/Client.cs @@ -115,6 +115,9 @@ namespace Server Console.WriteLine($"set resistance worked is " + worked); //set resistance on doctor GUI break; + case DataParser.MESSAGE: + //TODO send message to clients + break; default: Console.WriteLine($"Received json with identifier {identifier}:\n{Encoding.ASCII.GetString(payloadbytes)}"); break; diff --git a/Server/Communication.cs b/Server/Communication.cs index ab956c9..1169597 100644 --- a/Server/Communication.cs +++ b/Server/Communication.cs @@ -35,15 +35,6 @@ namespace Server var tcpClient = listener.EndAcceptTcpClient(ar); Console.WriteLine($"Client connected from {tcpClient.Client.RemoteEndPoint}"); clients.Add(new Client(this, tcpClient)); - /*if (doctor == null) - { - doctor = clients.ElementAt(0); - } - else - { - - doctor.sendMessage(DataParser.getNewConnectionJson("jan")); - }*/ listener.BeginAcceptTcpClient(new AsyncCallback(OnConnect), null); }