コード例 #1
0
        public IRestResponse DelConnect(string login, string session)
        {
            request = new RestRequest("connect", Method.DELETE);
            Request.UserAccount reqBody = new Request.UserAccount();
            reqBody.auth.login   = login;
            reqBody.auth.session = session;
            request.AddJsonBody(reqBody);

            response = client.Execute(request);
            return(response);
        }
コード例 #2
0
        public IRestResponse newGame(string login, string session)
        {
            request = new RestRequest("newGame", Method.POST);
            Request.UserAccount reqBody = new Request.UserAccount();
            reqBody.auth.login   = login;
            reqBody.auth.session = session;
            request.AddJsonBody(reqBody);

            response = client.Execute(request);
            return(response);
        }
コード例 #3
0
        public IRestResponse Connect(User user, int hero)
        {
            request = new RestRequest("connect", Method.POST);
            Request.UserAccount reqBody = new Request.UserAccount();
            reqBody.auth.login   = user.Login;
            reqBody.auth.session = user.Session;
            reqBody.game         = user.Game;
            reqBody.hero         = hero;
            request.AddJsonBody(reqBody);

            response = client.Execute(request);
            return(response);
        }