notifyKilled method

void notifyKilled(
  1. Socket client
)

Note: only notify users that the game was killed if the killing was manually done so that it doesn't kick clients out of the game at the end of the game

Implementation

void notifyKilled(IO.Socket client) {
  for (final client in _clients.values) {
    client?.emit(IOChannel.gamedeleted.string, true);
  }
  if (!_clients.values.contains(client)) {
    client.emit(IOChannel.gamedeleted.string, true);
  }
}