コード例 #1
0
        private void SendRequest()
        {
            LogMessage("Sending request to get the leaderboard:");
            GetLeaderboardRequest request = new GetLeaderboardRequest("test_01", 3, 0);

            request.ToString(logBuilder);
            LogMessage(string.Empty);

            messenger.SendRequest(request);
        }
コード例 #2
0
 private void OnGetLeaderboardResponseReceived(HttpMessageHandle handle, GetLeaderboardRequest request, GetLeaderboardResponse response)
 {
     if (response != null)
     {
         logBuilder.AppendLine("Received get leaderboard response:");
         response.ToString(logBuilder);
         txtLog.text = logBuilder.ToString();
     }
     else if (handle.IsError)
     {
         LogMessage("An error occurred: " + handle.WebRequest.error);
     }
     else
     {
         LogMessage("The request did not complete successfully.");
     }
 }