Exemplo n.º 1
0
        public ReqGetAccessToken(string deviceid, string secretkey, Network.ResponseCallback response)
        {
            this.name = "gauth/accesstoken";
            this.body = "{";
            ReqGetAccessToken reqGetAccessToken1 = this;

            reqGetAccessToken1.body = reqGetAccessToken1.body + "\"ticket\":" + (object)Network.TicketID + ",";
            this.body += "\"access_token\":\"\",";
            this.body += "\"param\":{";
            ReqGetAccessToken reqGetAccessToken2 = this;

            reqGetAccessToken2.body = reqGetAccessToken2.body + "\"device_id\":\"" + deviceid + "\",";
            ReqGetAccessToken reqGetAccessToken3 = this;

            reqGetAccessToken3.body = reqGetAccessToken3.body + "\"secret_key\":\"" + secretkey + "\"";
            this.body    += "}";
            this.body    += "}";
            this.callback = response;
        }
Exemplo n.º 2
0
        public ReqGetAccessToken(string deviceid, string secretkey, Network.ResponseCallback response)
        {
            this.name = "gauth/accesstoken";
            this.body = "{";
            ReqGetAccessToken reqGetAccessToken1 = this;

            reqGetAccessToken1.body = reqGetAccessToken1.body + "\"ticket\":" + (object)Network.TicketID + ",";
            this.body += "\"access_token\":\"\",";
            this.body += "\"param\":{";
            ReqGetAccessToken reqGetAccessToken2 = this;

            reqGetAccessToken2.body = reqGetAccessToken2.body + "\"device_id\":\"" + deviceid + "\",";
            ReqGetAccessToken reqGetAccessToken3 = this;

            reqGetAccessToken3.body = reqGetAccessToken3.body + "\"secret_key\":\"" + secretkey + "\"";
            if (!string.IsNullOrEmpty(GameManager.GetIDFA))
            {
                ReqGetAccessToken reqGetAccessToken4 = this;
                reqGetAccessToken4.body = reqGetAccessToken4.body + ",\"idfa\":\"" + GameManager.GetIDFA + "\"";
            }
            this.body    += "}";
            this.body    += "}";
            this.callback = response;
        }