private void Close() { MySqlConnectTool.CloseConnect(mySqlConnection); if (clientSocket != null) { clientSocket.Close(); } if (room != null) { room.QuitRoom(this); } server.RemoveClient(this); }
public Client(Socket clientSocket, Server server) { this.clientSocket = clientSocket; this.server = server; mySqlConnection = MySqlConnectTool.Connect(); }