public HashSet <ulong> GetTeamFull(GameResult game, int teamNumber) { var cap = TeamCaptains.FirstOrDefault(x => x.GuildId == game.GuildId && x.ChannelId == game.LobbyId && x.GameNumber == game.GameId && x.TeamNumber == teamNumber); var players = TeamPlayers.Where(x => x.GuildId == game.GuildId && x.ChannelId == game.LobbyId && x.GameNumber == game.GameId && x.TeamNumber == teamNumber).Select(x => x.UserId).ToHashSet(); if (cap != null) { players.Add(cap.UserId); } return(players); }
public TeamCaptain GetTeamCaptain(ulong guildId, ulong channelId, int gameNumber, int teamId) { return(TeamCaptains.FirstOrDefault(x => x.GuildId == guildId && x.ChannelId == channelId && x.GameNumber == gameNumber && x.TeamNumber == teamId)); }
public TeamCaptain GetTeamCaptain(GameResult game, int teamId) { return(TeamCaptains.FirstOrDefault(x => x.GuildId == game.GuildId && x.ChannelId == game.LobbyId && x.GameNumber == game.GameId && x.TeamNumber == teamId)); }