gameServer2/src/server/handlers/inroom.rs
changeset 13431 f091f69d59e4
parent 13429 d8354cb98b98
child 13432 6f6a866c86a2
equal deleted inserted replaced
13430:50f852e7ad82 13431:f091f69d59e4
   260             if let (c, Some(r)) = server.client_and_room(client_id) {
   260             if let (c, Some(r)) = server.client_and_room(client_id) {
   261                 if c.is_in_game {
   261                 if c.is_in_game {
   262                     c.is_in_game = false;
   262                     c.is_in_game = false;
   263                     actions.push(ClientFlags("-g".to_string(), vec![c.nick.clone()]).
   263                     actions.push(ClientFlags("-g".to_string(), vec![c.nick.clone()]).
   264                         send_all().in_room(r.id).action());
   264                         send_all().in_room(r.id).action());
   265                     for team in r.client_teams(c.id) {
   265                     if r.game_info.is_some() {
   266                         actions.push(SendTeamRemovalMessage(team.name.clone()));
   266                         for team in r.client_teams(c.id) {
       
   267                             actions.push(SendTeamRemovalMessage(team.name.clone()));
       
   268                         }
   267                     }
   269                     }
   268                 }
   270                 }
   269             }
   271             }
   270             server.react(client_id, actions)
   272             server.react(client_id, actions)
   271         }
   273         }