gameServer2/src/server/server.rs
changeset 13442 c6a3784ff2c1
parent 13426 f091f69d59e4
child 13445 d3c86ade3d4d
--- a/gameServer2/src/server/server.rs	Wed Jul 04 13:56:49 2018 +0300
+++ b/gameServer2/src/server/server.rs	Wed Jul 04 15:42:42 2018 +0300
@@ -58,7 +58,9 @@
 
     pub fn handle_msg(&mut self, client_id: ClientId, msg: HWProtocolMessage) {
         debug!("Handling message {:?} for client {}", msg, client_id);
-        handlers::handle(self, client_id, msg);
+        if self.clients.contains(client_id) {
+            handlers::handle(self, client_id, msg);
+        }
     }
 
     fn get_recipients(&self, client_id: ClientId, destination: Destination) -> Vec<ClientId> {