Esempio n. 1
0
        internal async Task <PlayerDescriptor> SelectOption(string optionCode)
        {
            Endpoint             e       = Endpoint.ChooseOption(CurrentMatchID, Player.Secret);
            ConnectorPayloadBase payload = new OptionPayload(Player.Name, optionCode);

            return(await _gameServer.PostJSON <PlayerDescriptor>(e, payload));
        }
Esempio n. 2
0
        internal async Task <PlayerDescriptor> QuitMatch(MatchDescriptor match)
        {
            Endpoint             e        = Endpoint.QuitMatch(match.MatchId, Player.Secret);
            ConnectorPayloadBase payload  = new OptionPayload(Player.Name);
            PlayerDescriptor     response = await _gameServer.PostJSON <PlayerDescriptor>(e, payload);

            return(response);
        }
Esempio n. 3
0
        internal async Task <MatchDescriptor> JoinMatch(MatchDescriptor selectedMatch)
        {
            Endpoint             e       = Endpoint.JoinMatch(selectedMatch.MatchId);
            ConnectorPayloadBase payload = new OptionPayload(Player.Name);

            CurrentMatchID = selectedMatch.MatchId;
            return(await _gameServer.PostJSON <MatchDescriptor>(e, payload));
        }