public ClickGame(ClickGameConfiguration config, GameCreationPayload payload) { _config = config; IReadOnlyCollection <IPlayer> players = payload.PlayerToRole.Keys.ToArray(); _allPlayers = new MulticastGroup(players); }
public IGame Create(IGameConfiguration config, GameCreationPayload payload) { if (config is not ClickGameConfiguration correctConfig) { throw new ArgumentException("Provided invalid configuration"); } return(new ClickGame(correctConfig, payload)); }
public string?ValidateRolesWithConfig(IGameConfiguration config, GameCreationPayload payload) { return(null); }