diff --git a/PokemonGo/RocketAPI/Client.cs b/PokemonGo/RocketAPI/Client.cs
index a34bb08..bf797cf 100644
--- a/PokemonGo/RocketAPI/Client.cs
+++ b/PokemonGo/RocketAPI/Client.cs
@@ -15,6 +15,7 @@ using Google.Protobuf;
using Google.Protobuf.Collections;
using Newtonsoft.Json;
using Newtonsoft.Json.Linq;
+using PokemonGo.RocketAPI.Enums;
using PokemonGo.RocketAPI.GeneratedCode;
using PokemonGo.RocketAPI.Helpers;
using PokemonGo.RocketAPI.Extensions;
@@ -24,25 +25,28 @@ namespace PokemonGo.RocketAPI
public class Client
{
private readonly HttpClient _httpClient;
+ private AuthType _authType = AuthType.Google;
+ private string _accessToken;
+ private string _apiUrl;
+ private Request.Types.UnknownAuth _unknownAuth;
public Client()
{
//Setup HttpClient and create default headers
HttpClientHandler handler = new HttpClientHandler()
{
- AutomaticDecompression = DecompressionMethods.GZip,
+ AutomaticDecompression = DecompressionMethods.GZip | DecompressionMethods.Deflate,
AllowAutoRedirect = false
};
- _httpClient = new HttpClient(handler);
- _httpClient.DefaultRequestHeaders.TryAddWithoutValidation("User-Agent", "Dalvik/2.1.0 (Linux; U; Android 5.1.1; SM-G900F Build/LMY48G)");
- _httpClient.DefaultRequestHeaders.AcceptEncoding.Add(new StringWithQualityHeaderValue("gzip"));
- _httpClient.DefaultRequestHeaders.Accept.Add(new MediaTypeWithQualityHeaderValue("application/json"));
+ _httpClient = new HttpClient(new RetryHandler(handler));
+ _httpClient.DefaultRequestHeaders.TryAddWithoutValidation("User-Agent", "Niantic App");//"Dalvik/2.1.0 (Linux; U; Android 5.1.1; SM-G900F Build/LMY48G)");
_httpClient.DefaultRequestHeaders.ExpectContinue = false;
+ _httpClient.DefaultRequestHeaders.TryAddWithoutValidation("Connection", "keep-alive");
+ _httpClient.DefaultRequestHeaders.TryAddWithoutValidation("Accept", "*/*");
_httpClient.DefaultRequestHeaders.TryAddWithoutValidation("Content-Type", "application/x-www-form-urlencoded");
}
- public async Task<string> GetGoogleAccessToken(string deviceId, string clientSig, string email,
- string token)
+ public async Task LoginGoogle(string deviceId, string email, string refreshToken)
{
var handler = new HttpClientHandler()
{
@@ -52,15 +56,13 @@ namespace PokemonGo.RocketAPI
using (var tempHttpClient = new HttpClient(handler))
{
- _httpClient.DefaultRequestHeaders.TryAddWithoutValidation("User-Agent",
+ tempHttpClient.DefaultRequestHeaders.TryAddWithoutValidation("User-Agent",
"GoogleAuth/1.4 (kltexx LMY48G); gzip");
- _httpClient.DefaultRequestHeaders.AcceptEncoding.Add(new StringWithQualityHeaderValue("gzip"));
+ tempHttpClient.DefaultRequestHeaders.AcceptEncoding.Add(new StringWithQualityHeaderValue("gzip"));
tempHttpClient.DefaultRequestHeaders.Add("device", deviceId);
tempHttpClient.DefaultRequestHeaders.Add("app", "com.nianticlabs.pokemongo");
- tempHttpClient.DefaultRequestHeaders.Add("device", deviceId);
- tempHttpClient.DefaultRequestHeaders.Add("device", deviceId);
- var response = await tempHttpClient.PostAsync(Resources.GOOGLE_GRANT_REFRESH_ACCESS_URL,
+ var response = await tempHttpClient.PostAsync(Resources.GoogleGrantRefreshAccessUrl,
new FormUrlEncodedContent(
new[]
{
@@ -69,37 +71,104 @@ namespace PokemonGo.RocketAPI
new KeyValuePair<string, string>("google_play_services_version", "9256238"),
new KeyValuePair<string, string>("sdk_version", "22"),
new KeyValuePair<string, string>("device_country", "nl"),
- new KeyValuePair<string, string>("client_sig", clientSig),
- new KeyValuePair<string, string>("caller_sig", clientSig),
+ new KeyValuePair<string, string>("client_sig", Settings.ClientSig),
+ new KeyValuePair<string, string>("caller_sig", Settings.ClientSig),
new KeyValuePair<string, string>("Email", email),
new KeyValuePair<string, string>("service", "audience:server:client_id:848232511240-7so421jotr2609rmqakceuu1luuq0ptb.apps.googleusercontent.com"),
new KeyValuePair<string, string>("app", "com.nianticlabs.pokemongo"),
new KeyValuePair<string, string>("check_email", "1"),
new KeyValuePair<string, string>("token_request_options", ""),
new KeyValuePair<string, string>("callerPkg", "com.nianticlabs.pokemongo"),
- new KeyValuePair<string, string>("Token", token)
+ new KeyValuePair<string, string>("Token", refreshToken)
}));
var content = await response.Content.ReadAsStringAsync();
- return content.Split(new[] {"Auth=", "issueAdvice"}, StringSplitOptions.RemoveEmptyEntries)[0];
+ _accessToken = content.Split(new[] {"Auth=", "issueAdvice"}, StringSplitOptions.RemoveEmptyEntries)[0];
+ _authType = AuthType.Google;
}
}
- public async Task<ProfileResponse> GetServer(Request profileRequest)
+ public async Task LoginPtc(string username, string password)
+ {
+ //Get session cookie
+ var sessionResp = await _httpClient.GetAsync(Resources.PtcLoginUrl);
+ var data = await sessionResp.Content.ReadAsStringAsync();
+ var lt = JsonHelper.GetValue(data, "lt");
+ var executionId = JsonHelper.GetValue(data, "execution");
+
+ //Login
+ var loginResp = await _httpClient.PostAsync(Resources.PtcLoginUrl,
+ new FormUrlEncodedContent(
+ new[]
+ {
+ new KeyValuePair<string, string>("lt", lt),
+ new KeyValuePair<string, string>("execution", executionId),
+ new KeyValuePair<string, string>("_eventId", "submit"),
+ new KeyValuePair<string, string>("username", username),
+ new KeyValuePair<string, string>("password", password),
+ }));
+
+ var ticketId = HttpUtility.ParseQueryString(loginResp.Headers.Location.Query)["ticket"];
+
+ //Get tokenvar
+ var tokenResp = await _httpClient.PostAsync(Resources.PtcLoginOauth,
+ new FormUrlEncodedContent(
+ new[]
+ {
+ new KeyValuePair<string, string>("client_id", "mobile-app_pokemon-go"),
+ new KeyValuePair<string, string>("redirect_uri", "https://www.nianticlabs.com/pokemongo/error"),
+ new KeyValuePair<string, string>("client_secret", "w8ScCUXJQc6kXKw8FiOhd8Fixzht18Dq3PEVkUCP5ZPxtgyWsbTvWHFLm2wNY0JR"),
+ new KeyValuePair<string, string>("grant_type", "grant_type"),
+ new KeyValuePair<string, string>("code", ticketId),
+ }));
+
+ var tokenData = await tokenResp.Content.ReadAsStringAsync();
+ _accessToken = HttpUtility.ParseQueryString(tokenData)["access_token"];
+ _authType = AuthType.Ptc;
+ }
+
+ public async Task<ProfileResponse> GetServer()
{
- return await _httpClient.PostProto<Request, ProfileResponse>(Resources.RPC_URL, profileRequest);
+ var serverRequest = RequestBuilder.GetInitialRequest(_accessToken, _authType, Settings.DefaultLatitude, Settings.DefaultLongitude, 30, RequestType.Profile, RequestType.Unknown126, RequestType.Time, RequestType.Unknown129, RequestType.Settings);
+ var serverResponse = await _httpClient.PostProto<Request, ProfileResponse>(Resources.RpcUrl, serverRequest);
+ _apiUrl = serverResponse.ApiUrl;
+ return serverResponse;
}
- public async Task<ProfileResponse> GetProfile(string apiUrl, Request profileRequest)
+
+ public async Task<ProfileResponse> GetProfile()
{
- return await _httpClient.PostProto<Request, ProfileResponse>($"https://{apiUrl}/rpc", profileRequest);
+ var profileRequest = RequestBuilder.GetInitialRequest(_accessToken, _authType, Settings.DefaultLatitude, Settings.DefaultLongitude, 30, new Request.Types.Requests() { Type = (int)RequestType.Profile });
+ var profileResponse = await _httpClient.PostProto<Request, ProfileResponse>($"https://{_apiUrl}/rpc", profileRequest);
+ _unknownAuth = new Request.Types.UnknownAuth()
+ {
+ Unknown71 = profileResponse.Auth.Unknown71,
+ Timestamp = profileResponse.Auth.Timestamp,
+ Unknown73 = profileResponse.Auth.Unknown73,
+ };
+ return profileResponse;
}
- public async Task<SettingsResponse> GetSettings(string apiUrl, Request settingsRequest)
+
+ public async Task<SettingsResponse> GetSettings()
{
- return await _httpClient.PostProto<Request, SettingsResponse>($"https://{apiUrl}/rpc", settingsRequest);
+ var settingsRequest = RequestBuilder.GetRequest(_unknownAuth, Settings.DefaultLatitude, Settings.DefaultLongitude, 30, RequestType.Settings);
+ return await _httpClient.PostProto<Request, SettingsResponse>($"https://{_apiUrl}/rpc", settingsRequest);
}
- public async Task<EncounterResponse> GetEncounters(string apiUrl, Request encounterRequest)
+ public async Task<EncounterResponse> GetEncounters()
{
- return await _httpClient.PostProto<Request, EncounterResponse>($"https://{apiUrl}/rpc", encounterRequest);
+ var customRequest = new EncounterRequest.Types.RequestsMessage()
+ {
+ CellIds =
+ ByteString.CopyFrom(
+ ProtoHelper.EncodeUlongList(S2Helper.GetNearbyCellIds(Settings.DefaultLongitude,
+ Settings.DefaultLatitude))),
+ Latitude = Utils.FloatAsUlong(Settings.DefaultLatitude),
+ Longitude = Utils.FloatAsUlong(Settings.DefaultLongitude),
+ Unknown14 = ByteString.CopyFromUtf8("\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0")
+ };
+
+ var encounterRequest = RequestBuilder.GetRequest(_unknownAuth, Settings.DefaultLatitude, Settings.DefaultLongitude, 30, new Request.Types.Requests() { Type = (int)RequestType.Encounters, Message = customRequest.ToByteString()});
+
+ return await _httpClient.PostProto<Request, EncounterResponse>($"https://{_apiUrl}/rpc", encounterRequest);
}
}
diff --git a/PokemonGo/RocketAPI/Console/Program.cs b/PokemonGo/RocketAPI/Console/Program.cs
index 7bf213c..c7b4541 100644
--- a/PokemonGo/RocketAPI/Console/Program.cs
+++ b/PokemonGo/RocketAPI/Console/Program.cs
@@ -3,7 +3,9 @@ using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
+using Google.Protobuf;
using PokemonGo.RocketAPI.Enums;
+using PokemonGo.RocketAPI.GeneratedCode;
using PokemonGo.RocketAPI.Helpers;
namespace PokemonGo.RocketAPI.Console
@@ -19,18 +21,13 @@ namespace PokemonGo.RocketAPI.Console
static async void Execute()
{
var client = new Client();
-
- var accessToken = await client.GetGoogleAccessToken(Settings.DeviceId, Settings.ClientSig, Settings.Email, Settings.LongDurationToken);
- var profileRequest = RequestBuilder.GetRequest(RequestType.Profile, accessToken, Settings.DefaultLatitude, Settings.DefaultLongitude, 30);
- var serverSettingsRequest = RequestBuilder.GetRequest(RequestType.Settings, accessToken, Settings.DefaultLatitude, Settings.DefaultLongitude, 30);
- var encountersRequest = RequestBuilder.GetRequest(RequestType.Encounters, accessToken, Settings.DefaultLatitude, Settings.DefaultLongitude, 30);
- var serverResponse = await client.GetServer(profileRequest);
- var profile = await client.GetProfile(serverResponse.ApiUrl, profileRequest);
-
- var serverSettings = await client.GetSettings(serverResponse.ApiUrl, serverSettingsRequest);
-
- var encounters = await client.GetEncounters(serverResponse.ApiUrl, encountersRequest);
+ await client.LoginPtc("Sekret-username", "Sekret-password");
+ //await client.LoginGoogle(Settings.DeviceId, Settings.Email, Settings.LongDurationToken);
+ var serverResponse = await client.GetServer();
+ var profile = await client.GetProfile();
+ var settings = await client.GetSettings();
+ var encounters = await client.GetEncounters();
}
}
}
diff --git a/PokemonGo/RocketAPI/Enums/AuthType.cs b/PokemonGo/RocketAPI/Enums/AuthType.cs
new file mode 100644
index 0000000..9ef6a42
--- /dev/null
+++ b/PokemonGo/RocketAPI/Enums/AuthType.cs
@@ -0,0 +1,14 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace PokemonGo.RocketAPI.Enums
+{
+ public enum AuthType
+ {
+ Google,
+ Ptc
+ }
+}
diff --git a/PokemonGo/RocketAPI/Enums/RequestType.cs b/PokemonGo/RocketAPI/Enums/RequestType.cs
index 11bbea3..e08fc87 100644
--- a/PokemonGo/RocketAPI/Enums/RequestType.cs
+++ b/PokemonGo/RocketAPI/Enums/RequestType.cs
@@ -9,7 +9,10 @@ namespace PokemonGo.RocketAPI.Enums
public enum RequestType
{
Profile = 2,
+ Time = 4,
Settings = 5,
- Encounters = 300
+ Encounters = 106,
+ Unknown126 = 126,
+ Unknown129 = 129
}
}
diff --git a/PokemonGo/RocketAPI/Extensions/DateTimeExtensions.cs b/PokemonGo/RocketAPI/Extensions/DateTimeExtensions.cs
new file mode 100644
index 0000000..b0d5c84
--- /dev/null
+++ b/PokemonGo/RocketAPI/Extensions/DateTimeExtensions.cs
@@ -0,0 +1,17 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace PokemonGo.RocketAPI.Extensions
+{
+ public static class DateTimeExtensions
+ {
+ public static long ToUnixTime(this DateTime date)
+ {
+ var epoch = new DateTime(1970, 1, 1, 0, 0, 0, DateTimeKind.Utc);
+ return Convert.ToInt64((date - epoch).TotalMilliseconds);
+ }
+ }
+}
diff --git a/PokemonGo/RocketAPI/Extensions/HttpClientExtensions.cs b/PokemonGo/RocketAPI/Extensions/HttpClientExtensions.cs
index 9570e55..7b3d240 100644
--- a/PokemonGo/RocketAPI/Extensions/HttpClientExtensions.cs
+++ b/PokemonGo/RocketAPI/Extensions/HttpClientExtensions.cs
@@ -15,8 +15,8 @@ namespace PokemonGo.RocketAPI.Extensions
public static async Task<V> PostProto<T, V>(this HttpClient client, string url, T request) where T : IMessage<T> where V : IMessage<V>, new()
{
//Encode message and send
- var data = request.ToByteArray();
- var result = await client.PostAsync(url, new ByteArrayContent(data));
+ var data = request.ToByteString();
+ var result = await client.PostAsync(url, new ByteArrayContent(data.ToByteArray()));
//Decode message
var responseData = await result.Content.ReadAsByteArrayAsync();
diff --git a/PokemonGo/RocketAPI/GeneratedCode/EncounterRequest.cs b/PokemonGo/RocketAPI/GeneratedCode/EncounterRequest.cs
new file mode 100644
index 0000000..b6c5cc3
--- /dev/null
+++ b/PokemonGo/RocketAPI/GeneratedCode/EncounterRequest.cs
@@ -0,0 +1,1425 @@
+// Generated by the protocol buffer compiler. DO NOT EDIT!
+// source: EncounterRequest.proto
+#pragma warning disable 1591, 0612, 3021
+#region Designer generated code
+
+using pb = global::Google.Protobuf;
+using pbc = global::Google.Protobuf.Collections;
+using pbr = global::Google.Protobuf.Reflection;
+using scg = global::System.Collections.Generic;
+namespace PokemonGo.RocketAPI.GeneratedCode {
+
+ /// <summary>Holder for reflection information generated from EncounterRequest.proto</summary>
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ public static partial class EncounterRequestReflection {
+
+ #region Descriptor
+ /// <summary>File descriptor for EncounterRequest.proto</summary>
+ public static pbr::FileDescriptor Descriptor {
+ get { return descriptor; }
+ }
+ private static pbr::FileDescriptor descriptor;
+
+ static EncounterRequestReflection() {
+ byte[] descriptorData = global::System.Convert.FromBase64String(
+ string.Concat(
+ "ChZFbmNvdW50ZXJSZXF1ZXN0LnByb3RvEiFQb2tlbW9uR28uUm9ja2V0QVBJ",
+ "LkdlbmVyYXRlZENvZGUilgYKEEVuY291bnRlclJlcXVlc3QSEAoIdW5rbm93",
+ "bjEYASABKAUSDgoGcnBjX2lkGAMgASgDEk4KCHJlcXVlc3RzGAQgAygLMjwu",
+ "UG9rZW1vbkdvLlJvY2tldEFQSS5HZW5lcmF0ZWRDb2RlLkVuY291bnRlclJl",
+ "cXVlc3QuUmVxdWVzdHMSTgoIdW5rbm93bjYYBiABKAsyPC5Qb2tlbW9uR28u",
+ "Um9ja2V0QVBJLkdlbmVyYXRlZENvZGUuRW5jb3VudGVyUmVxdWVzdC5Vbmtu",
+ "b3duNhIQCghsYXRpdHVkZRgHIAEoBhIRCglsb25naXR1ZGUYCCABKAYSEAoI",
+ "YWx0aXR1ZGUYCSABKAYSRgoEYXV0aBgLIAEoCzI4LlBva2Vtb25Hby5Sb2Nr",
+ "ZXRBUEkuR2VuZXJhdGVkQ29kZS5FbmNvdW50ZXJSZXF1ZXN0LkF1dGgSEQoJ",
+ "dW5rbm93bjEyGAwgASgDGikKCFJlcXVlc3RzEgwKBHR5cGUYASABKAUSDwoH",
+ "bWVzc2FnZRgCIAEoDBpaCg9SZXF1ZXN0c01lc3NhZ2USDwoHY2VsbElkcxgB",
+ "IAEoDBIRCgl1bmtub3duMTQYAiABKAwSEAoIbGF0aXR1ZGUYAyABKAYSEQoJ",
+ "bG9uZ2l0dWRlGAQgASgGGhwKDFNldHRpbmdzR3VpZBIMCgRndWlkGAEgASgM",
+ "GhQKBFRpbWUSDAoEdGltZRgBIAEoAxocCghVbmtub3duMxIQCgh1bmtub3du",
+ "NBgBIAEoCRqTAQoIVW5rbm93bjYSEAoIdW5rbm93bjEYASABKAUSVwoIdW5r",
+ "bm93bjIYAiABKAsyRS5Qb2tlbW9uR28uUm9ja2V0QVBJLkdlbmVyYXRlZENv",
+ "ZGUuRW5jb3VudGVyUmVxdWVzdC5Vbmtub3duNi5Vbmtub3duMhocCghVbmtu",
+ "b3duMhIQCgh1bmtub3duMRgBIAEoDBo/CgRBdXRoEhEKCXVua25vd243MRgB",
+ "IAEoDBIRCgl0aW1lc3RhbXAYAiABKAMSEQoJdW5rbm93bjczGAMgASgMYgZw",
+ "cm90bzM="));
+ descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData,
+ new pbr::FileDescriptor[] { },
+ new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] {
+ new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest), global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Parser, new[]{ "Unknown1", "RpcId", "Requests", "Unknown6", "Latitude", "Longitude", "Altitude", "Auth", "Unknown12" }, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Requests), global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Requests.Parser, new[]{ "Type", "Message" }, null, null, null),
+ new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.RequestsMessage), global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.RequestsMessage.Parser, new[]{ "CellIds", "Unknown14", "Latitude", "Longitude" }, null, null, null),
+ new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.SettingsGuid), global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.SettingsGuid.Parser, new[]{ "Guid" }, null, null, null),
+ new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Time), global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Time.Parser, new[]{ "Time_" }, null, null, null),
+ new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Unknown3), global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Unknown3.Parser, new[]{ "Unknown4" }, null, null, null),
+ new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Unknown6), global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Unknown6.Parser, new[]{ "Unknown1", "Unknown2" }, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Unknown6.Types.Unknown2), global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Unknown6.Types.Unknown2.Parser, new[]{ "Unknown1" }, null, null, null)}),
+ new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Auth), global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Auth.Parser, new[]{ "Unknown71", "Timestamp", "Unknown73" }, null, null, null)})
+ }));
+ }
+ #endregion
+
+ }
+ #region Messages
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ public sealed partial class EncounterRequest : pb::IMessage<EncounterRequest> {
+ private static readonly pb::MessageParser<EncounterRequest> _parser = new pb::MessageParser<EncounterRequest>(() => new EncounterRequest());
+ public static pb::MessageParser<EncounterRequest> Parser { get { return _parser; } }
+
+ public static pbr::MessageDescriptor Descriptor {
+ get { return global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequestReflection.Descriptor.MessageTypes[0]; }
+ }
+
+ pbr::MessageDescriptor pb::IMessage.Descriptor {
+ get { return Descriptor; }
+ }
+
+ public EncounterRequest() {
+ OnConstruction();
+ }
+
+ partial void OnConstruction();
+
+ public EncounterRequest(EncounterRequest other) : this() {
+ unknown1_ = other.unknown1_;
+ rpcId_ = other.rpcId_;
+ requests_ = other.requests_.Clone();
+ Unknown6 = other.unknown6_ != null ? other.Unknown6.Clone() : null;
+ latitude_ = other.latitude_;
+ longitude_ = other.longitude_;
+ altitude_ = other.altitude_;
+ Auth = other.auth_ != null ? other.Auth.Clone() : null;
+ unknown12_ = other.unknown12_;
+ }
+
+ public EncounterRequest Clone() {
+ return new EncounterRequest(this);
+ }
+
+ /// <summary>Field number for the "unknown1" field.</summary>
+ public const int Unknown1FieldNumber = 1;
+ private int unknown1_;
+ public int Unknown1 {
+ get { return unknown1_; }
+ set {
+ unknown1_ = value;
+ }
+ }
+
+ /// <summary>Field number for the "rpc_id" field.</summary>
+ public const int RpcIdFieldNumber = 3;
+ private long rpcId_;
+ public long RpcId {
+ get { return rpcId_; }
+ set {
+ rpcId_ = value;
+ }
+ }
+
+ /// <summary>Field number for the "requests" field.</summary>
+ public const int RequestsFieldNumber = 4;
+ private static readonly pb::FieldCodec<global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Requests> _repeated_requests_codec
+ = pb::FieldCodec.ForMessage(34, global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Requests.Parser);
+ private readonly pbc::RepeatedField<global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Requests> requests_ = new pbc::RepeatedField<global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Requests>();
+ public pbc::RepeatedField<global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Requests> Requests {
+ get { return requests_; }
+ }
+
+ /// <summary>Field number for the "unknown6" field.</summary>
+ public const int Unknown6FieldNumber = 6;
+ private global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Unknown6 unknown6_;
+ public global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Unknown6 Unknown6 {
+ get { return unknown6_; }
+ set {
+ unknown6_ = value;
+ }
+ }
+
+ /// <summary>Field number for the "latitude" field.</summary>
+ public const int LatitudeFieldNumber = 7;
+ private ulong latitude_;
+ public ulong Latitude {
+ get { return latitude_; }
+ set {
+ latitude_ = value;
+ }
+ }
+
+ /// <summary>Field number for the "longitude" field.</summary>
+ public const int LongitudeFieldNumber = 8;
+ private ulong longitude_;
+ public ulong Longitude {
+ get { return longitude_; }
+ set {
+ longitude_ = value;
+ }
+ }
+
+ /// <summary>Field number for the "altitude" field.</summary>
+ public const int AltitudeFieldNumber = 9;
+ private ulong altitude_;
+ public ulong Altitude {
+ get { return altitude_; }
+ set {
+ altitude_ = value;
+ }
+ }
+
+ /// <summary>Field number for the "auth" field.</summary>
+ public const int AuthFieldNumber = 11;
+ private global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Auth auth_;
+ /// <summary>
+ /// AuthInfo auth = 10;
+ /// </summary>
+ public global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Auth Auth {
+ get { return auth_; }
+ set {
+ auth_ = value;
+ }
+ }
+
+ /// <summary>Field number for the "unknown12" field.</summary>
+ public const int Unknown12FieldNumber = 12;
+ private long unknown12_;
+ public long Unknown12 {
+ get { return unknown12_; }
+ set {
+ unknown12_ = value;
+ }
+ }
+
+ public override bool Equals(object other) {
+ return Equals(other as EncounterRequest);
+ }
+
+ public bool Equals(EncounterRequest other) {
+ if (ReferenceEquals(other, null)) {
+ return false;
+ }
+ if (ReferenceEquals(other, this)) {
+ return true;
+ }
+ if (Unknown1 != other.Unknown1) return false;
+ if (RpcId != other.RpcId) return false;
+ if(!requests_.Equals(other.requests_)) return false;
+ if (!object.Equals(Unknown6, other.Unknown6)) return false;
+ if (Latitude != other.Latitude) return false;
+ if (Longitude != other.Longitude) return false;
+ if (Altitude != other.Altitude) return false;
+ if (!object.Equals(Auth, other.Auth)) return false;
+ if (Unknown12 != other.Unknown12) return false;
+ return true;
+ }
+
+ public override int GetHashCode() {
+ int hash = 1;
+ if (Unknown1 != 0) hash ^= Unknown1.GetHashCode();
+ if (RpcId != 0L) hash ^= RpcId.GetHashCode();
+ hash ^= requests_.GetHashCode();
+ if (unknown6_ != null) hash ^= Unknown6.GetHashCode();
+ if (Latitude != 0UL) hash ^= Latitude.GetHashCode();
+ if (Longitude != 0UL) hash ^= Longitude.GetHashCode();
+ if (Altitude != 0UL) hash ^= Altitude.GetHashCode();
+ if (auth_ != null) hash ^= Auth.GetHashCode();
+ if (Unknown12 != 0L) hash ^= Unknown12.GetHashCode();
+ return hash;
+ }
+
+ public override string ToString() {
+ return pb::JsonFormatter.ToDiagnosticString(this);
+ }
+
+ public void WriteTo(pb::CodedOutputStream output) {
+ if (Unknown1 != 0) {
+ output.WriteRawTag(8);
+ output.WriteInt32(Unknown1);
+ }
+ if (RpcId != 0L) {
+ output.WriteRawTag(24);
+ output.WriteInt64(RpcId);
+ }
+ requests_.WriteTo(output, _repeated_requests_codec);
+ if (unknown6_ != null) {
+ output.WriteRawTag(50);
+ output.WriteMessage(Unknown6);
+ }
+ if (Latitude != 0UL) {
+ output.WriteRawTag(57);
+ output.WriteFixed64(Latitude);
+ }
+ if (Longitude != 0UL) {
+ output.WriteRawTag(65);
+ output.WriteFixed64(Longitude);
+ }
+ if (Altitude != 0UL) {
+ output.WriteRawTag(73);
+ output.WriteFixed64(Altitude);
+ }
+ if (auth_ != null) {
+ output.WriteRawTag(90);
+ output.WriteMessage(Auth);
+ }
+ if (Unknown12 != 0L) {
+ output.WriteRawTag(96);
+ output.WriteInt64(Unknown12);
+ }
+ }
+
+ public int CalculateSize() {
+ int size = 0;
+ if (Unknown1 != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeInt32Size(Unknown1);
+ }
+ if (RpcId != 0L) {
+ size += 1 + pb::CodedOutputStream.ComputeInt64Size(RpcId);
+ }
+ size += requests_.CalculateSize(_repeated_requests_codec);
+ if (unknown6_ != null) {
+ size += 1 + pb::CodedOutputStream.ComputeMessageSize(Unknown6);
+ }
+ if (Latitude != 0UL) {
+ size += 1 + 8;
+ }
+ if (Longitude != 0UL) {
+ size += 1 + 8;
+ }
+ if (Altitude != 0UL) {
+ size += 1 + 8;
+ }
+ if (auth_ != null) {
+ size += 1 + pb::CodedOutputStream.ComputeMessageSize(Auth);
+ }
+ if (Unknown12 != 0L) {
+ size += 1 + pb::CodedOutputStream.ComputeInt64Size(Unknown12);
+ }
+ return size;
+ }
+
+ public void MergeFrom(EncounterRequest other) {
+ if (other == null) {
+ return;
+ }
+ if (other.Unknown1 != 0) {
+ Unknown1 = other.Unknown1;
+ }
+ if (other.RpcId != 0L) {
+ RpcId = other.RpcId;
+ }
+ requests_.Add(other.requests_);
+ if (other.unknown6_ != null) {
+ if (unknown6_ == null) {
+ unknown6_ = new global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Unknown6();
+ }
+ Unknown6.MergeFrom(other.Unknown6);
+ }
+ if (other.Latitude != 0UL) {
+ Latitude = other.Latitude;
+ }
+ if (other.Longitude != 0UL) {
+ Longitude = other.Longitude;
+ }
+ if (other.Altitude != 0UL) {
+ Altitude = other.Altitude;
+ }
+ if (other.auth_ != null) {
+ if (auth_ == null) {
+ auth_ = new global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Auth();
+ }
+ Auth.MergeFrom(other.Auth);
+ }
+ if (other.Unknown12 != 0L) {
+ Unknown12 = other.Unknown12;
+ }
+ }
+
+ public void MergeFrom(pb::CodedInputStream input) {
+ uint tag;
+ while ((tag = input.ReadTag()) != 0) {
+ switch(tag) {
+ default:
+ input.SkipLastField();
+ break;
+ case 8: {
+ Unknown1 = input.ReadInt32();
+ break;
+ }
+ case 24: {
+ RpcId = input.ReadInt64();
+ break;
+ }
+ case 34: {
+ requests_.AddEntriesFrom(input, _repeated_requests_codec);
+ break;
+ }
+ case 50: {
+ if (unknown6_ == null) {
+ unknown6_ = new global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Unknown6();
+ }
+ input.ReadMessage(unknown6_);
+ break;
+ }
+ case 57: {
+ Latitude = input.ReadFixed64();
+ break;
+ }
+ case 65: {
+ Longitude = input.ReadFixed64();
+ break;
+ }
+ case 73: {
+ Altitude = input.ReadFixed64();
+ break;
+ }
+ case 90: {
+ if (auth_ == null) {
+ auth_ = new global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Auth();
+ }
+ input.ReadMessage(auth_);
+ break;
+ }
+ case 96: {
+ Unknown12 = input.ReadInt64();
+ break;
+ }
+ }
+ }
+ }
+
+ #region Nested types
+ /// <summary>Container for nested types declared in the EncounterRequest message type.</summary>
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ public static partial class Types {
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ public sealed partial class Requests : pb::IMessage<Requests> {
+ private static readonly pb::MessageParser<Requests> _parser = new pb::MessageParser<Requests>(() => new Requests());
+ public static pb::MessageParser<Requests> Parser { get { return _parser; } }
+
+ public static pbr::MessageDescriptor Descriptor {
+ get { return global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Descriptor.NestedTypes[0]; }
+ }
+
+ pbr::MessageDescriptor pb::IMessage.Descriptor {
+ get { return Descriptor; }
+ }
+
+ public Requests() {
+ OnConstruction();
+ }
+
+ partial void OnConstruction();
+
+ public Requests(Requests other) : this() {
+ type_ = other.type_;
+ message_ = other.message_;
+ }
+
+ public Requests Clone() {
+ return new Requests(this);
+ }
+
+ /// <summary>Field number for the "type" field.</summary>
+ public const int TypeFieldNumber = 1;
+ private int type_;
+ public int Type {
+ get { return type_; }
+ set {
+ type_ = value;
+ }
+ }
+
+ /// <summary>Field number for the "message" field.</summary>
+ public const int MessageFieldNumber = 2;
+ private pb::ByteString message_ = pb::ByteString.Empty;
+ public pb::ByteString Message {
+ get { return message_; }
+ set {
+ message_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
+ }
+ }
+
+ public override bool Equals(object other) {
+ return Equals(other as Requests);
+ }
+
+ public bool Equals(Requests other) {
+ if (ReferenceEquals(other, null)) {
+ return false;
+ }
+ if (ReferenceEquals(other, this)) {
+ return true;
+ }
+ if (Type != other.Type) return false;
+ if (Message != other.Message) return false;
+ return true;
+ }
+
+ public override int GetHashCode() {
+ int hash = 1;
+ if (Type != 0) hash ^= Type.GetHashCode();
+ if (Message.Length != 0) hash ^= Message.GetHashCode();
+ return hash;
+ }
+
+ public override string ToString() {
+ return pb::JsonFormatter.ToDiagnosticString(this);
+ }
+
+ public void WriteTo(pb::CodedOutputStream output) {
+ if (Type != 0) {
+ output.WriteRawTag(8);
+ output.WriteInt32(Type);
+ }
+ if (Message.Length != 0) {
+ output.WriteRawTag(18);
+ output.WriteBytes(Message);
+ }
+ }
+
+ public int CalculateSize() {
+ int size = 0;
+ if (Type != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeInt32Size(Type);
+ }
+ if (Message.Length != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeBytesSize(Message);
+ }
+ return size;
+ }
+
+ public void MergeFrom(Requests other) {
+ if (other == null) {
+ return;
+ }
+ if (other.Type != 0) {
+ Type = other.Type;
+ }
+ if (other.Message.Length != 0) {
+ Message = other.Message;
+ }
+ }
+
+ public void MergeFrom(pb::CodedInputStream input) {
+ uint tag;
+ while ((tag = input.ReadTag()) != 0) {
+ switch(tag) {
+ default:
+ input.SkipLastField();
+ break;
+ case 8: {
+ Type = input.ReadInt32();
+ break;
+ }
+ case 18: {
+ Message = input.ReadBytes();
+ break;
+ }
+ }
+ }
+ }
+
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ public sealed partial class RequestsMessage : pb::IMessage<RequestsMessage> {
+ private static readonly pb::MessageParser<RequestsMessage> _parser = new pb::MessageParser<RequestsMessage>(() => new RequestsMessage());
+ public static pb::MessageParser<RequestsMessage> Parser { get { return _parser; } }
+
+ public static pbr::MessageDescriptor Descriptor {
+ get { return global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Descriptor.NestedTypes[1]; }
+ }
+
+ pbr::MessageDescriptor pb::IMessage.Descriptor {
+ get { return Descriptor; }
+ }
+
+ public RequestsMessage() {
+ OnConstruction();
+ }
+
+ partial void OnConstruction();
+
+ public RequestsMessage(RequestsMessage other) : this() {
+ cellIds_ = other.cellIds_;
+ unknown14_ = other.unknown14_;
+ latitude_ = other.latitude_;
+ longitude_ = other.longitude_;
+ }
+
+ public RequestsMessage Clone() {
+ return new RequestsMessage(this);
+ }
+
+ /// <summary>Field number for the "cellIds" field.</summary>
+ public const int CellIdsFieldNumber = 1;
+ private pb::ByteString cellIds_ = pb::ByteString.Empty;
+ public pb::ByteString CellIds {
+ get { return cellIds_; }
+ set {
+ cellIds_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
+ }
+ }
+
+ /// <summary>Field number for the "unknown14" field.</summary>
+ public const int Unknown14FieldNumber = 2;
+ private pb::ByteString unknown14_ = pb::ByteString.Empty;
+ public pb::ByteString Unknown14 {
+ get { return unknown14_; }
+ set {
+ unknown14_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
+ }
+ }
+
+ /// <summary>Field number for the "latitude" field.</summary>
+ public const int LatitudeFieldNumber = 3;
+ private ulong latitude_;
+ public ulong Latitude {
+ get { return latitude_; }
+ set {
+ latitude_ = value;
+ }
+ }
+
+ /// <summary>Field number for the "longitude" field.</summary>
+ public const int LongitudeFieldNumber = 4;
+ private ulong longitude_;
+ public ulong Longitude {
+ get { return longitude_; }
+ set {
+ longitude_ = value;
+ }
+ }
+
+ public override bool Equals(object other) {
+ return Equals(other as RequestsMessage);
+ }
+
+ public bool Equals(RequestsMessage other) {
+ if (ReferenceEquals(other, null)) {
+ return false;
+ }
+ if (ReferenceEquals(other, this)) {
+ return true;
+ }
+ if (CellIds != other.CellIds) return false;
+ if (Unknown14 != other.Unknown14) return false;
+ if (Latitude != other.Latitude) return false;
+ if (Longitude != other.Longitude) return false;
+ return true;
+ }
+
+ public override int GetHashCode() {
+ int hash = 1;
+ if (CellIds.Length != 0) hash ^= CellIds.GetHashCode();
+ if (Unknown14.Length != 0) hash ^= Unknown14.GetHashCode();
+ if (Latitude != 0UL) hash ^= Latitude.GetHashCode();
+ if (Longitude != 0UL) hash ^= Longitude.GetHashCode();
+ return hash;
+ }
+
+ public override string ToString() {
+ return pb::JsonFormatter.ToDiagnosticString(this);
+ }
+
+ public void WriteTo(pb::CodedOutputStream output) {
+ if (CellIds.Length != 0) {
+ output.WriteRawTag(10);
+ output.WriteBytes(CellIds);
+ }
+ if (Unknown14.Length != 0) {
+ output.WriteRawTag(18);
+ output.WriteBytes(Unknown14);
+ }
+ if (Latitude != 0UL) {
+ output.WriteRawTag(25);
+ output.WriteFixed64(Latitude);
+ }
+ if (Longitude != 0UL) {
+ output.WriteRawTag(33);
+ output.WriteFixed64(Longitude);
+ }
+ }
+
+ public int CalculateSize() {
+ int size = 0;
+ if (CellIds.Length != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeBytesSize(CellIds);
+ }
+ if (Unknown14.Length != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeBytesSize(Unknown14);
+ }
+ if (Latitude != 0UL) {
+ size += 1 + 8;
+ }
+ if (Longitude != 0UL) {
+ size += 1 + 8;
+ }
+ return size;
+ }
+
+ public void MergeFrom(RequestsMessage other) {
+ if (other == null) {
+ return;
+ }
+ if (other.CellIds.Length != 0) {
+ CellIds = other.CellIds;
+ }
+ if (other.Unknown14.Length != 0) {
+ Unknown14 = other.Unknown14;
+ }
+ if (other.Latitude != 0UL) {
+ Latitude = other.Latitude;
+ }
+ if (other.Longitude != 0UL) {
+ Longitude = other.Longitude;
+ }
+ }
+
+ public void MergeFrom(pb::CodedInputStream input) {
+ uint tag;
+ while ((tag = input.ReadTag()) != 0) {
+ switch(tag) {
+ default:
+ input.SkipLastField();
+ break;
+ case 10: {
+ CellIds = input.ReadBytes();
+ break;
+ }
+ case 18: {
+ Unknown14 = input.ReadBytes();
+ break;
+ }
+ case 25: {
+ Latitude = input.ReadFixed64();
+ break;
+ }
+ case 33: {
+ Longitude = input.ReadFixed64();
+ break;
+ }
+ }
+ }
+ }
+
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ public sealed partial class SettingsGuid : pb::IMessage<SettingsGuid> {
+ private static readonly pb::MessageParser<SettingsGuid> _parser = new pb::MessageParser<SettingsGuid>(() => new SettingsGuid());
+ public static pb::MessageParser<SettingsGuid> Parser { get { return _parser; } }
+
+ public static pbr::MessageDescriptor Descriptor {
+ get { return global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Descriptor.NestedTypes[2]; }
+ }
+
+ pbr::MessageDescriptor pb::IMessage.Descriptor {
+ get { return Descriptor; }
+ }
+
+ public SettingsGuid() {
+ OnConstruction();
+ }
+
+ partial void OnConstruction();
+
+ public SettingsGuid(SettingsGuid other) : this() {
+ guid_ = other.guid_;
+ }
+
+ public SettingsGuid Clone() {
+ return new SettingsGuid(this);
+ }
+
+ /// <summary>Field number for the "guid" field.</summary>
+ public const int GuidFieldNumber = 1;
+ private pb::ByteString guid_ = pb::ByteString.Empty;
+ public pb::ByteString Guid {
+ get { return guid_; }
+ set {
+ guid_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
+ }
+ }
+
+ public override bool Equals(object other) {
+ return Equals(other as SettingsGuid);
+ }
+
+ public bool Equals(SettingsGuid other) {
+ if (ReferenceEquals(other, null)) {
+ return false;
+ }
+ if (ReferenceEquals(other, this)) {
+ return true;
+ }
+ if (Guid != other.Guid) return false;
+ return true;
+ }
+
+ public override int GetHashCode() {
+ int hash = 1;
+ if (Guid.Length != 0) hash ^= Guid.GetHashCode();
+ return hash;
+ }
+
+ public override string ToString() {
+ return pb::JsonFormatter.ToDiagnosticString(this);
+ }
+
+ public void WriteTo(pb::CodedOutputStream output) {
+ if (Guid.Length != 0) {
+ output.WriteRawTag(10);
+ output.WriteBytes(Guid);
+ }
+ }
+
+ public int CalculateSize() {
+ int size = 0;
+ if (Guid.Length != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeBytesSize(Guid);
+ }
+ return size;
+ }
+
+ public void MergeFrom(SettingsGuid other) {
+ if (other == null) {
+ return;
+ }
+ if (other.Guid.Length != 0) {
+ Guid = other.Guid;
+ }
+ }
+
+ public void MergeFrom(pb::CodedInputStream input) {
+ uint tag;
+ while ((tag = input.ReadTag()) != 0) {
+ switch(tag) {
+ default:
+ input.SkipLastField();
+ break;
+ case 10: {
+ Guid = input.ReadBytes();
+ break;
+ }
+ }
+ }
+ }
+
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ public sealed partial class Time : pb::IMessage<Time> {
+ private static readonly pb::MessageParser<Time> _parser = new pb::MessageParser<Time>(() => new Time());
+ public static pb::MessageParser<Time> Parser { get { return _parser; } }
+
+ public static pbr::MessageDescriptor Descriptor {
+ get { return global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Descriptor.NestedTypes[3]; }
+ }
+
+ pbr::MessageDescriptor pb::IMessage.Descriptor {
+ get { return Descriptor; }
+ }
+
+ public Time() {
+ OnConstruction();
+ }
+
+ partial void OnConstruction();
+
+ public Time(Time other) : this() {
+ time_ = other.time_;
+ }
+
+ public Time Clone() {
+ return new Time(this);
+ }
+
+ /// <summary>Field number for the "time" field.</summary>
+ public const int Time_FieldNumber = 1;
+ private long time_;
+ public long Time_ {
+ get { return time_; }
+ set {
+ time_ = value;
+ }
+ }
+
+ public override bool Equals(object other) {
+ return Equals(other as Time);
+ }
+
+ public bool Equals(Time other) {
+ if (ReferenceEquals(other, null)) {
+ return false;
+ }
+ if (ReferenceEquals(other, this)) {
+ return true;
+ }
+ if (Time_ != other.Time_) return false;
+ return true;
+ }
+
+ public override int GetHashCode() {
+ int hash = 1;
+ if (Time_ != 0L) hash ^= Time_.GetHashCode();
+ return hash;
+ }
+
+ public override string ToString() {
+ return pb::JsonFormatter.ToDiagnosticString(this);
+ }
+
+ public void WriteTo(pb::CodedOutputStream output) {
+ if (Time_ != 0L) {
+ output.WriteRawTag(8);
+ output.WriteInt64(Time_);
+ }
+ }
+
+ public int CalculateSize() {
+ int size = 0;
+ if (Time_ != 0L) {
+ size += 1 + pb::CodedOutputStream.ComputeInt64Size(Time_);
+ }
+ return size;
+ }
+
+ public void MergeFrom(Time other) {
+ if (other == null) {
+ return;
+ }
+ if (other.Time_ != 0L) {
+ Time_ = other.Time_;
+ }
+ }
+
+ public void MergeFrom(pb::CodedInputStream input) {
+ uint tag;
+ while ((tag = input.ReadTag()) != 0) {
+ switch(tag) {
+ default:
+ input.SkipLastField();
+ break;
+ case 8: {
+ Time_ = input.ReadInt64();
+ break;
+ }
+ }
+ }
+ }
+
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ public sealed partial class Unknown3 : pb::IMessage<Unknown3> {
+ private static readonly pb::MessageParser<Unknown3> _parser = new pb::MessageParser<Unknown3>(() => new Unknown3());
+ public static pb::MessageParser<Unknown3> Parser { get { return _parser; } }
+
+ public static pbr::MessageDescriptor Descriptor {
+ get { return global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Descriptor.NestedTypes[4]; }
+ }
+
+ pbr::MessageDescriptor pb::IMessage.Descriptor {
+ get { return Descriptor; }
+ }
+
+ public Unknown3() {
+ OnConstruction();
+ }
+
+ partial void OnConstruction();
+
+ public Unknown3(Unknown3 other) : this() {
+ unknown4_ = other.unknown4_;
+ }
+
+ public Unknown3 Clone() {
+ return new Unknown3(this);
+ }
+
+ /// <summary>Field number for the "unknown4" field.</summary>
+ public const int Unknown4FieldNumber = 1;
+ private string unknown4_ = "";
+ public string Unknown4 {
+ get { return unknown4_; }
+ set {
+ unknown4_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
+ }
+ }
+
+ public override bool Equals(object other) {
+ return Equals(other as Unknown3);
+ }
+
+ public bool Equals(Unknown3 other) {
+ if (ReferenceEquals(other, null)) {
+ return false;
+ }
+ if (ReferenceEquals(other, this)) {
+ return true;
+ }
+ if (Unknown4 != other.Unknown4) return false;
+ return true;
+ }
+
+ public override int GetHashCode() {
+ int hash = 1;
+ if (Unknown4.Length != 0) hash ^= Unknown4.GetHashCode();
+ return hash;
+ }
+
+ public override string ToString() {
+ return pb::JsonFormatter.ToDiagnosticString(this);
+ }
+
+ public void WriteTo(pb::CodedOutputStream output) {
+ if (Unknown4.Length != 0) {
+ output.WriteRawTag(10);
+ output.WriteString(Unknown4);
+ }
+ }
+
+ public int CalculateSize() {
+ int size = 0;
+ if (Unknown4.Length != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeStringSize(Unknown4);
+ }
+ return size;
+ }
+
+ public void MergeFrom(Unknown3 other) {
+ if (other == null) {
+ return;
+ }
+ if (other.Unknown4.Length != 0) {
+ Unknown4 = other.Unknown4;
+ }
+ }
+
+ public void MergeFrom(pb::CodedInputStream input) {
+ uint tag;
+ while ((tag = input.ReadTag()) != 0) {
+ switch(tag) {
+ default:
+ input.SkipLastField();
+ break;
+ case 10: {
+ Unknown4 = input.ReadString();
+ break;
+ }
+ }
+ }
+ }
+
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ public sealed partial class Unknown6 : pb::IMessage<Unknown6> {
+ private static readonly pb::MessageParser<Unknown6> _parser = new pb::MessageParser<Unknown6>(() => new Unknown6());
+ public static pb::MessageParser<Unknown6> Parser { get { return _parser; } }
+
+ public static pbr::MessageDescriptor Descriptor {
+ get { return global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Descriptor.NestedTypes[5]; }
+ }
+
+ pbr::MessageDescriptor pb::IMessage.Descriptor {
+ get { return Descriptor; }
+ }
+
+ public Unknown6() {
+ OnConstruction();
+ }
+
+ partial void OnConstruction();
+
+ public Unknown6(Unknown6 other) : this() {
+ unknown1_ = other.unknown1_;
+ Unknown2 = other.unknown2_ != null ? other.Unknown2.Clone() : null;
+ }
+
+ public Unknown6 Clone() {
+ return new Unknown6(this);
+ }
+
+ /// <summary>Field number for the "unknown1" field.</summary>
+ public const int Unknown1FieldNumber = 1;
+ private int unknown1_;
+ public int Unknown1 {
+ get { return unknown1_; }
+ set {
+ unknown1_ = value;
+ }
+ }
+
+ /// <summary>Field number for the "unknown2" field.</summary>
+ public const int Unknown2FieldNumber = 2;
+ private global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Unknown6.Types.Unknown2 unknown2_;
+ public global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Unknown6.Types.Unknown2 Unknown2 {
+ get { return unknown2_; }
+ set {
+ unknown2_ = value;
+ }
+ }
+
+ public override bool Equals(object other) {
+ return Equals(other as Unknown6);
+ }
+
+ public bool Equals(Unknown6 other) {
+ if (ReferenceEquals(other, null)) {
+ return false;
+ }
+ if (ReferenceEquals(other, this)) {
+ return true;
+ }
+ if (Unknown1 != other.Unknown1) return false;
+ if (!object.Equals(Unknown2, other.Unknown2)) return false;
+ return true;
+ }
+
+ public override int GetHashCode() {
+ int hash = 1;
+ if (Unknown1 != 0) hash ^= Unknown1.GetHashCode();
+ if (unknown2_ != null) hash ^= Unknown2.GetHashCode();
+ return hash;
+ }
+
+ public override string ToString() {
+ return pb::JsonFormatter.ToDiagnosticString(this);
+ }
+
+ public void WriteTo(pb::CodedOutputStream output) {
+ if (Unknown1 != 0) {
+ output.WriteRawTag(8);
+ output.WriteInt32(Unknown1);
+ }
+ if (unknown2_ != null) {
+ output.WriteRawTag(18);
+ output.WriteMessage(Unknown2);
+ }
+ }
+
+ public int CalculateSize() {
+ int size = 0;
+ if (Unknown1 != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeInt32Size(Unknown1);
+ }
+ if (unknown2_ != null) {
+ size += 1 + pb::CodedOutputStream.ComputeMessageSize(Unknown2);
+ }
+ return size;
+ }
+
+ public void MergeFrom(Unknown6 other) {
+ if (other == null) {
+ return;
+ }
+ if (other.Unknown1 != 0) {
+ Unknown1 = other.Unknown1;
+ }
+ if (other.unknown2_ != null) {
+ if (unknown2_ == null) {
+ unknown2_ = new global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Unknown6.Types.Unknown2();
+ }
+ Unknown2.MergeFrom(other.Unknown2);
+ }
+ }
+
+ public void MergeFrom(pb::CodedInputStream input) {
+ uint tag;
+ while ((tag = input.ReadTag()) != 0) {
+ switch(tag) {
+ default:
+ input.SkipLastField();
+ break;
+ case 8: {
+ Unknown1 = input.ReadInt32();
+ break;
+ }
+ case 18: {
+ if (unknown2_ == null) {
+ unknown2_ = new global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Unknown6.Types.Unknown2();
+ }
+ input.ReadMessage(unknown2_);
+ break;
+ }
+ }
+ }
+ }
+
+ #region Nested types
+ /// <summary>Container for nested types declared in the Unknown6 message type.</summary>
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ public static partial class Types {
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ public sealed partial class Unknown2 : pb::IMessage<Unknown2> {
+ private static readonly pb::MessageParser<Unknown2> _parser = new pb::MessageParser<Unknown2>(() => new Unknown2());
+ public static pb::MessageParser<Unknown2> Parser { get { return _parser; } }
+
+ public static pbr::MessageDescriptor Descriptor {
+ get { return global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Types.Unknown6.Descriptor.NestedTypes[0]; }
+ }
+
+ pbr::MessageDescriptor pb::IMessage.Descriptor {
+ get { return Descriptor; }
+ }
+
+ public Unknown2() {
+ OnConstruction();
+ }
+
+ partial void OnConstruction();
+
+ public Unknown2(Unknown2 other) : this() {
+ unknown1_ = other.unknown1_;
+ }
+
+ public Unknown2 Clone() {
+ return new Unknown2(this);
+ }
+
+ /// <summary>Field number for the "unknown1" field.</summary>
+ public const int Unknown1FieldNumber = 1;
+ private pb::ByteString unknown1_ = pb::ByteString.Empty;
+ public pb::ByteString Unknown1 {
+ get { return unknown1_; }
+ set {
+ unknown1_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
+ }
+ }
+
+ public override bool Equals(object other) {
+ return Equals(other as Unknown2);
+ }
+
+ public bool Equals(Unknown2 other) {
+ if (ReferenceEquals(other, null)) {
+ return false;
+ }
+ if (ReferenceEquals(other, this)) {
+ return true;
+ }
+ if (Unknown1 != other.Unknown1) return false;
+ return true;
+ }
+
+ public override int GetHashCode() {
+ int hash = 1;
+ if (Unknown1.Length != 0) hash ^= Unknown1.GetHashCode();
+ return hash;
+ }
+
+ public override string ToString() {
+ return pb::JsonFormatter.ToDiagnosticString(this);
+ }
+
+ public void WriteTo(pb::CodedOutputStream output) {
+ if (Unknown1.Length != 0) {
+ output.WriteRawTag(10);
+ output.WriteBytes(Unknown1);
+ }
+ }
+
+ public int CalculateSize() {
+ int size = 0;
+ if (Unknown1.Length != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeBytesSize(Unknown1);
+ }
+ return size;
+ }
+
+ public void MergeFrom(Unknown2 other) {
+ if (other == null) {
+ return;
+ }
+ if (other.Unknown1.Length != 0) {
+ Unknown1 = other.Unknown1;
+ }
+ }
+
+ public void MergeFrom(pb::CodedInputStream input) {
+ uint tag;
+ while ((tag = input.ReadTag()) != 0) {
+ switch(tag) {
+ default:
+ input.SkipLastField();
+ break;
+ case 10: {
+ Unknown1 = input.ReadBytes();
+ break;
+ }
+ }
+ }
+ }
+
+ }
+
+ }
+ #endregion
+
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ public sealed partial class Auth : pb::IMessage<Auth> {
+ private static readonly pb::MessageParser<Auth> _parser = new pb::MessageParser<Auth>(() => new Auth());
+ public static pb::MessageParser<Auth> Parser { get { return _parser; } }
+
+ public static pbr::MessageDescriptor Descriptor {
+ get { return global::PokemonGo.RocketAPI.GeneratedCode.EncounterRequest.Descriptor.NestedTypes[6]; }
+ }
+
+ pbr::MessageDescriptor pb::IMessage.Descriptor {
+ get { return Descriptor; }
+ }
+
+ public Auth() {
+ OnConstruction();
+ }
+
+ partial void OnConstruction();
+
+ public Auth(Auth other) : this() {
+ unknown71_ = other.unknown71_;
+ timestamp_ = other.timestamp_;
+ unknown73_ = other.unknown73_;
+ }
+
+ public Auth Clone() {
+ return new Auth(this);
+ }
+
+ /// <summary>Field number for the "unknown71" field.</summary>
+ public const int Unknown71FieldNumber = 1;
+ private pb::ByteString unknown71_ = pb::ByteString.Empty;
+ public pb::ByteString Unknown71 {
+ get { return unknown71_; }
+ set {
+ unknown71_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
+ }
+ }
+
+ /// <summary>Field number for the "timestamp" field.</summary>
+ public const int TimestampFieldNumber = 2;
+ private long timestamp_;
+ public long Timestamp {
+ get { return timestamp_; }
+ set {
+ timestamp_ = value;
+ }
+ }
+
+ /// <summary>Field number for the "unknown73" field.</summary>
+ public const int Unknown73FieldNumber = 3;
+ private pb::ByteString unknown73_ = pb::ByteString.Empty;
+ public pb::ByteString Unknown73 {
+ get { return unknown73_; }
+ set {
+ unknown73_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
+ }
+ }
+
+ public override bool Equals(object other) {
+ return Equals(other as Auth);
+ }
+
+ public bool Equals(Auth other) {
+ if (ReferenceEquals(other, null)) {
+ return false;
+ }
+ if (ReferenceEquals(other, this)) {
+ return true;
+ }
+ if (Unknown71 != other.Unknown71) return false;
+ if (Timestamp != other.Timestamp) return false;
+ if (Unknown73 != other.Unknown73) return false;
+ return true;
+ }
+
+ public override int GetHashCode() {
+ int hash = 1;
+ if (Unknown71.Length != 0) hash ^= Unknown71.GetHashCode();
+ if (Timestamp != 0L) hash ^= Timestamp.GetHashCode();
+ if (Unknown73.Length != 0) hash ^= Unknown73.GetHashCode();
+ return hash;
+ }
+
+ public override string ToString() {
+ return pb::JsonFormatter.ToDiagnosticString(this);
+ }
+
+ public void WriteTo(pb::CodedOutputStream output) {
+ if (Unknown71.Length != 0) {
+ output.WriteRawTag(10);
+ output.WriteBytes(Unknown71);
+ }
+ if (Timestamp != 0L) {
+ output.WriteRawTag(16);
+ output.WriteInt64(Timestamp);
+ }
+ if (Unknown73.Length != 0) {
+ output.WriteRawTag(26);
+ output.WriteBytes(Unknown73);
+ }
+ }
+
+ public int CalculateSize() {
+ int size = 0;
+ if (Unknown71.Length != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeBytesSize(Unknown71);
+ }
+ if (Timestamp != 0L) {
+ size += 1 + pb::CodedOutputStream.ComputeInt64Size(Timestamp);
+ }
+ if (Unknown73.Length != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeBytesSize(Unknown73);
+ }
+ return size;
+ }
+
+ public void MergeFrom(Auth other) {
+ if (other == null) {
+ return;
+ }
+ if (other.Unknown71.Length != 0) {
+ Unknown71 = other.Unknown71;
+ }
+ if (other.Timestamp != 0L) {
+ Timestamp = other.Timestamp;
+ }
+ if (other.Unknown73.Length != 0) {
+ Unknown73 = other.Unknown73;
+ }
+ }
+
+ public void MergeFrom(pb::CodedInputStream input) {
+ uint tag;
+ while ((tag = input.ReadTag()) != 0) {
+ switch(tag) {
+ default:
+ input.SkipLastField();
+ break;
+ case 10: {
+ Unknown71 = input.ReadBytes();
+ break;
+ }
+ case 16: {
+ Timestamp = input.ReadInt64();
+ break;
+ }
+ case 26: {
+ Unknown73 = input.ReadBytes();
+ break;
+ }
+ }
+ }
+ }
+
+ }
+
+ }
+ #endregion
+
+ }
+
+ #endregion
+
+}
+
+#endregion Designer generated code
diff --git a/PokemonGo/RocketAPI/GeneratedCode/ProfileResponse.cs b/PokemonGo/RocketAPI/GeneratedCode/ProfileResponse.cs
index 2409e37..f196b94 100644
--- a/PokemonGo/RocketAPI/GeneratedCode/ProfileResponse.cs
+++ b/PokemonGo/RocketAPI/GeneratedCode/ProfileResponse.cs
@@ -24,76 +24,45 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
byte[] descriptorData = global::System.Convert.FromBase64String(
string.Concat(
"ChVQcm9maWxlUmVzcG9uc2UucHJvdG8SIVBva2Vtb25Hby5Sb2NrZXRBUEku",
- "R2VuZXJhdGVkQ29kZSLPEwoPUHJvZmlsZVJlc3BvbnNlEhAKCHVua25vd24x",
+ "R2VuZXJhdGVkQ29kZSLECgoPUHJvZmlsZVJlc3BvbnNlEhAKCHVua25vd24x",
"GAEgASgFEhAKCHVua25vd24yGAIgASgDEg8KB2FwaV91cm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TWV0ZXJzGAYgASgCEhgKEEdv",
- "b2dsZU1hcHNBcGlLZXkYByABKAkaUgoSTGV2ZWxTZXR0aW5nc1Byb3RvEhkK",
- "EVRyYWluZXJDcE1vZGlmaWVyGAIgASgBEiEKGVRyYWluZXJEaWZmaWN1bHR5",
- "TW9kaWZpZXIYAyABKAEafgoWSW52ZW50b3J5U2V0dGluZ3NQcm90bxISCgpN",
- "YXhQb2tlbW9uGAEgASgFEhMKC01heEJhZ0l0ZW1zGAIgASgFEhMKC0Jhc2VQ",
- "b2tlbW9uGAMgASgFEhQKDEJhc2VCYWdJdGVtcxgEIAEoBRIQCghCYXNlRWdn",
- "cxgFIAEoBWIGcHJvdG8z"));
+ "UHJvZmlsZS5EYWlseUJvbnVzEhEKCXVua25vd24xMhgMIAEoDBIRCgl1bmtu",
+ "b3duMTMYDSABKAwSXQoIY3VycmVuY3kYDiADKAsySy5Qb2tlbW9uR28uUm9j",
+ "a2V0QVBJLkdlbmVyYXRlZENvZGUuUHJvZmlsZVJlc3BvbnNlLlBheWxvYWQu",
+ "UHJvZmlsZS5DdXJyZW5jeRpYCg1BdmF0YXJEZXRhaWxzEhAKCHVua25vd24y",
+ "GAIgASgFEhAKCHVua25vd24zGAMgASgFEhAKCHVua25vd245GAkgASgFEhEK",
+ "CXVua25vd24xMBgKIAEoBRpZCgpEYWlseUJvbnVzEh4KFk5leHRDb2xsZWN0",
+ "VGltZXN0YW1wTXMYASABKAMSKwojTmV4dERlZmVuZGVyQm9udXNDb2xsZWN0",
+ "VGltZXN0YW1wTXMYAiABKAMaKAoIQ3VycmVuY3kSDAoEdHlwZRgBIAEoCRIO",
+ "CgZhbW91bnQYAiABKAViBnByb3RvMw=="));
descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData,
new pbr::FileDescriptor[] { },
new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] {
- new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse), global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Parser, new[]{ "Unknown1", "Unknown2", "ApiUrl", "Unknown6", "Unknown7", "Payload", "ErrorMessage" }, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Unknown6), global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Unknown6.Parser, new[]{ "Unknown1", "Unknown2" }, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Unknown6.Types.Unknown2), global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Unknown6.Types.Unknown2.Parser, new[]{ "Unknown1" }, null, null, null)}),
- new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Unknown7), global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Unknown7.Parser, new[]{ "Unknown71", "Unknown72", "Unknown73" }, null, null, null),
+ new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse), global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Parser, new[]{ "Unknown1", "Unknown2", "ApiUrl", "Unknown6", "Auth", "Payload", "ErrorMessage" }, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Unknown6), global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Unknown6.Parser, new[]{ "Unknown1", "Unknown2" }, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Unknown6.Types.Unknown2), global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Unknown6.Types.Unknown2.Parser, new[]{ "Unknown1" }, null, null, null)}),
+ new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Auth), global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Auth.Parser, new[]{ "Unknown71", "Timestamp", "Unknown73" }, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload), global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Parser, new[]{ "Unknown1", "Profile", "Setting" }, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.Profile), global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.Profile.Parser, new[]{ "CreationTime", "Username", "Team", "Tutorial", "Avatar", "PokeStorage", "ItemStorage", "DailyBonus", "Unknown12", "Unknown13", "Currency" }, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.Profile.Types.AvatarDetails), global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.Profile.Types.AvatarDetails.Parser, new[]{ "Unknown2", "Unknown3", "Unknown9", "Unknown10" }, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.Profile.Types.DailyBonus), global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.Profile.Types.DailyBonus.Parser, new[]{ "NextCollectTimestampMs", "NextDefenderBonusCollectTimestampMs" }, null, null, null),
- new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.Profile.Types.Currency), global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.Profile.Types.Currency.Parser, new[]{ "Type", "Amount" }, null, null, null)}),
- new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.GlobalSettingsProto), global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.GlobalSettingsProto.Parser, new[]{ "FortSettings", "MapSettings", "LevelSettings", "InventorySettings", "MinimumClientVersion" }, null, null, null),
- new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.FortSettingsProto), global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.FortSettingsProto.Parser, new[]{ "InteractionRangeMeters", "MaxTotalDeployedPokemon", "MaxPlayerDeployedPokemon", "DeployStaminaMultiplier", "DeployAttackMultiplier", "FarInteractionRangeMeters" }, null, null, null),
- new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.MapSettingsProto), global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.MapSettingsProto.Parser, new[]{ "PokemonVisibleRange", "PokeNavRangeMeters", "EncounterRangeMeters", "GetMapObjectsMinRefreshSeconds", "GetMapObjectsMaxRefreshSeconds", "GetMapObjectsMinDistanceMeters", "GoogleMapsApiKey" }, null, null, null),
- new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.LevelSettingsProto), global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.LevelSettingsProto.Parser, new[]{ "TrainerCpModifier", "TrainerDifficultyModifier" }, null, null, null),
- new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.InventorySettingsProto), global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.InventorySettingsProto.Parser, new[]{ "MaxPokemon", "MaxBagItems", "BasePokemon", "BaseBagItems", "BaseEggs" }, null, null, null)})})
+ new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.Profile.Types.Currency), global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.Profile.Types.Currency.Parser, new[]{ "Type", "Amount" }, null, null, null)})})})
}));
}
#endregion
@@ -124,7 +93,7 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
unknown2_ = other.unknown2_;
apiUrl_ = other.apiUrl_;
Unknown6 = other.unknown6_ != null ? other.Unknown6.Clone() : null;
- Unknown7 = other.unknown7_ != null ? other.Unknown7.Clone() : null;
+ Auth = other.auth_ != null ? other.Auth.Clone() : null;
payload_ = other.payload_.Clone();
errorMessage_ = other.errorMessage_;
}
@@ -173,13 +142,13 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
}
}
- /// <summary>Field number for the "unknown7" field.</summary>
- public const int Unknown7FieldNumber = 7;
- private global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Unknown7 unknown7_;
- public global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Unknown7 Unknown7 {
- get { return unknown7_; }
+ /// <summary>Field number for the "auth" field.</summary>
+ public const int AuthFieldNumber = 7;
+ private global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Auth auth_;
+ public global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Auth Auth {
+ get { return auth_; }
set {
- unknown7_ = value;
+ auth_ = value;
}
}
@@ -220,7 +189,7 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
if (Unknown2 != other.Unknown2) return false;
if (ApiUrl != other.ApiUrl) return false;
if (!object.Equals(Unknown6, other.Unknown6)) return false;
- if (!object.Equals(Unknown7, other.Unknown7)) return false;
+ if (!object.Equals(Auth, other.Auth)) return false;
if(!payload_.Equals(other.payload_)) return false;
if (ErrorMessage != other.ErrorMessage) return false;
return true;
@@ -232,7 +201,7 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
if (Unknown2 != 0L) hash ^= Unknown2.GetHashCode();
if (ApiUrl.Length != 0) hash ^= ApiUrl.GetHashCode();
if (unknown6_ != null) hash ^= Unknown6.GetHashCode();
- if (unknown7_ != null) hash ^= Unknown7.GetHashCode();
+ if (auth_ != null) hash ^= Auth.GetHashCode();
hash ^= payload_.GetHashCode();
if (ErrorMessage.Length != 0) hash ^= ErrorMessage.GetHashCode();
return hash;
@@ -259,9 +228,9 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
output.WriteRawTag(50);
output.WriteMessage(Unknown6);
}
- if (unknown7_ != null) {
+ if (auth_ != null) {
output.WriteRawTag(58);
- output.WriteMessage(Unknown7);
+ output.WriteMessage(Auth);
}
payload_.WriteTo(output, _repeated_payload_codec);
if (ErrorMessage.Length != 0) {
@@ -284,8 +253,8 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
if (unknown6_ != null) {
size += 1 + pb::CodedOutputStream.ComputeMessageSize(Unknown6);
}
- if (unknown7_ != null) {
- size += 1 + pb::CodedOutputStream.ComputeMessageSize(Unknown7);
+ if (auth_ != null) {
+ size += 1 + pb::CodedOutputStream.ComputeMessageSize(Auth);
}
size += payload_.CalculateSize(_repeated_payload_codec);
if (ErrorMessage.Length != 0) {
@@ -313,11 +282,11 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
}
Unknown6.MergeFrom(other.Unknown6);
}
- if (other.unknown7_ != null) {
- if (unknown7_ == null) {
- unknown7_ = new global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Unknown7();
+ if (other.auth_ != null) {
+ if (auth_ == null) {
+ auth_ = new global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Auth();
}
- Unknown7.MergeFrom(other.Unknown7);
+ Auth.MergeFrom(other.Auth);
}
payload_.Add(other.payload_);
if (other.ErrorMessage.Length != 0) {
@@ -352,10 +321,10 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
break;
}
case 58: {
- if (unknown7_ == null) {
- unknown7_ = new global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Unknown7();
+ if (auth_ == null) {
+ auth_ = new global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Auth();
}
- input.ReadMessage(unknown7_);
+ input.ReadMessage(auth_);
break;
}
case 802: {
@@ -621,9 +590,9 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
- public sealed partial class Unknown7 : pb::IMessage<Unknown7> {
- private static readonly pb::MessageParser<Unknown7> _parser = new pb::MessageParser<Unknown7>(() => new Unknown7());
- public static pb::MessageParser<Unknown7> Parser { get { return _parser; } }
+ public sealed partial class Auth : pb::IMessage<Auth> {
+ private static readonly pb::MessageParser<Auth> _parser = new pb::MessageParser<Auth>(() => new Auth());
+ public static pb::MessageParser<Auth> Parser { get { return _parser; } }
public static pbr::MessageDescriptor Descriptor {
get { return global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Descriptor.NestedTypes[1]; }
@@ -633,20 +602,20 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
get { return Descriptor; }
}
- public Unknown7() {
+ public Auth() {
OnConstruction();
}
partial void OnConstruction();
- public Unknown7(Unknown7 other) : this() {
+ public Auth(Auth other) : this() {
unknown71_ = other.unknown71_;
- unknown72_ = other.unknown72_;
+ timestamp_ = other.timestamp_;
unknown73_ = other.unknown73_;
}
- public Unknown7 Clone() {
- return new Unknown7(this);
+ public Auth Clone() {
+ return new Auth(this);
}
/// <summary>Field number for the "unknown71" field.</summary>
@@ -659,13 +628,13 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
}
}
- /// <summary>Field number for the "unknown72" field.</summary>
- public const int Unknown72FieldNumber = 2;
- private long unknown72_;
- public long Unknown72 {
- get { return unknown72_; }
+ /// <summary>Field number for the "timestamp" field.</summary>
+ public const int TimestampFieldNumber = 2;
+ private long timestamp_;
+ public long Timestamp {
+ get { return timestamp_; }
set {
- unknown72_ = value;
+ timestamp_ = value;
}
}
@@ -680,10 +649,10 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
}
public override bool Equals(object other) {
- return Equals(other as Unknown7);
+ return Equals(other as Auth);
}
- public bool Equals(Unknown7 other) {
+ public bool Equals(Auth other) {
if (ReferenceEquals(other, null)) {
return false;
}
@@ -691,7 +660,7 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
return true;
}
if (Unknown71 != other.Unknown71) return false;
- if (Unknown72 != other.Unknown72) return false;
+ if (Timestamp != other.Timestamp) return false;
if (Unknown73 != other.Unknown73) return false;
return true;
}
@@ -699,7 +668,7 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
public override int GetHashCode() {
int hash = 1;
if (Unknown71.Length != 0) hash ^= Unknown71.GetHashCode();
- if (Unknown72 != 0L) hash ^= Unknown72.GetHashCode();
+ if (Timestamp != 0L) hash ^= Timestamp.GetHashCode();
if (Unknown73.Length != 0) hash ^= Unknown73.GetHashCode();
return hash;
}
@@ -713,9 +682,9 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
output.WriteRawTag(10);
output.WriteBytes(Unknown71);
}
- if (Unknown72 != 0L) {
+ if (Timestamp != 0L) {
output.WriteRawTag(16);
- output.WriteInt64(Unknown72);
+ output.WriteInt64(Timestamp);
}
if (Unknown73.Length != 0) {
output.WriteRawTag(26);
@@ -728,8 +697,8 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
if (Unknown71.Length != 0) {
size += 1 + pb::CodedOutputStream.ComputeBytesSize(Unknown71);
}
- if (Unknown72 != 0L) {
- size += 1 + pb::CodedOutputStream.ComputeInt64Size(Unknown72);
+ if (Timestamp != 0L) {
+ size += 1 + pb::CodedOutputStream.ComputeInt64Size(Timestamp);
}
if (Unknown73.Length != 0) {
size += 1 + pb::CodedOutputStream.ComputeBytesSize(Unknown73);
@@ -737,15 +706,15 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
return size;
}
- public void MergeFrom(Unknown7 other) {
+ public void MergeFrom(Auth other) {
if (other == null) {
return;
}
if (other.Unknown71.Length != 0) {
Unknown71 = other.Unknown71;
}
- if (other.Unknown72 != 0L) {
- Unknown72 = other.Unknown72;
+ if (other.Timestamp != 0L) {
+ Timestamp = other.Timestamp;
}
if (other.Unknown73.Length != 0) {
Unknown73 = other.Unknown73;
@@ -764,7 +733,7 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
break;
}
case 16: {
- Unknown72 = input.ReadInt64();
+ Timestamp = input.ReadInt64();
break;
}
case 26: {
@@ -1770,1085 +1739,6 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
}
- [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
- public sealed partial class GlobalSettingsProto : pb::IMessage<GlobalSettingsProto> {
- private static readonly pb::MessageParser<GlobalSettingsProto> _parser = new pb::MessageParser<GlobalSettingsProto>(() => new GlobalSettingsProto());
- public static pb::MessageParser<GlobalSettingsProto> Parser { get { return _parser; } }
-
- public static pbr::MessageDescriptor Descriptor {
- get { return global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Descriptor.NestedTypes[1]; }
- }
-
- pbr::MessageDescriptor pb::IMessage.Descriptor {
- get { return Descriptor; }
- }
-
- public GlobalSettingsProto() {
- OnConstruction();
- }
-
- partial void OnConstruction();
-
- public GlobalSettingsProto(GlobalSettingsProto other) : this() {
- FortSettings = other.fortSettings_ != null ? other.FortSettings.Clone() : null;
- MapSettings = other.mapSettings_ != null ? other.MapSettings.Clone() : null;
- LevelSettings = other.levelSettings_ != null ? other.LevelSettings.Clone() : null;
- InventorySettings = other.inventorySettings_ != null ? other.InventorySettings.Clone() : null;
- minimumClientVersion_ = other.minimumClientVersion_;
- }
-
- public GlobalSettingsProto Clone() {
- return new GlobalSettingsProto(this);
- }
-
- /// <summary>Field number for the "FortSettings" field.</summary>
- public const int FortSettingsFieldNumber = 2;
- private global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.FortSettingsProto fortSettings_;
- public global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.FortSettingsProto FortSettings {
- get { return fortSettings_; }
- set {
- fortSettings_ = value;
- }
- }
-
- /// <summary>Field number for the "MapSettings" field.</summary>
- public const int MapSettingsFieldNumber = 3;
- private global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.MapSettingsProto mapSettings_;
- public global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.MapSettingsProto MapSettings {
- get { return mapSettings_; }
- set {
- mapSettings_ = value;
- }
- }
-
- /// <summary>Field number for the "LevelSettings" field.</summary>
- public const int LevelSettingsFieldNumber = 4;
- private global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.LevelSettingsProto levelSettings_;
- public global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.LevelSettingsProto LevelSettings {
- get { return levelSettings_; }
- set {
- levelSettings_ = value;
- }
- }
-
- /// <summary>Field number for the "InventorySettings" field.</summary>
- public const int InventorySettingsFieldNumber = 5;
- private global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.InventorySettingsProto inventorySettings_;
- public global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.InventorySettingsProto InventorySettings {
- get { return inventorySettings_; }
- set {
- inventorySettings_ = value;
- }
- }
-
- /// <summary>Field number for the "MinimumClientVersion" field.</summary>
- public const int MinimumClientVersionFieldNumber = 6;
- private string minimumClientVersion_ = "";
- public string MinimumClientVersion {
- get { return minimumClientVersion_; }
- set {
- minimumClientVersion_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
- }
- }
-
- public override bool Equals(object other) {
- return Equals(other as GlobalSettingsProto);
- }
-
- public bool Equals(GlobalSettingsProto other) {
- if (ReferenceEquals(other, null)) {
- return false;
- }
- if (ReferenceEquals(other, this)) {
- return true;
- }
- if (!object.Equals(FortSettings, other.FortSettings)) return false;
- if (!object.Equals(MapSettings, other.MapSettings)) return false;
- if (!object.Equals(LevelSettings, other.LevelSettings)) return false;
- if (!object.Equals(InventorySettings, other.InventorySettings)) return false;
- if (MinimumClientVersion != other.MinimumClientVersion) return false;
- return true;
- }
-
- public override int GetHashCode() {
- int hash = 1;
- if (fortSettings_ != null) hash ^= FortSettings.GetHashCode();
- if (mapSettings_ != null) hash ^= MapSettings.GetHashCode();
- if (levelSettings_ != null) hash ^= LevelSettings.GetHashCode();
- if (inventorySettings_ != null) hash ^= InventorySettings.GetHashCode();
- if (MinimumClientVersion.Length != 0) hash ^= MinimumClientVersion.GetHashCode();
- return hash;
- }
-
- public override string ToString() {
- return pb::JsonFormatter.ToDiagnosticString(this);
- }
-
- public void WriteTo(pb::CodedOutputStream output) {
- if (fortSettings_ != null) {
- output.WriteRawTag(18);
- output.WriteMessage(FortSettings);
- }
- if (mapSettings_ != null) {
- output.WriteRawTag(26);
- output.WriteMessage(MapSettings);
- }
- if (levelSettings_ != null) {
- output.WriteRawTag(34);
- output.WriteMessage(LevelSettings);
- }
- if (inventorySettings_ != null) {
- output.WriteRawTag(42);
- output.WriteMessage(InventorySettings);
- }
- if (MinimumClientVersion.Length != 0) {
- output.WriteRawTag(50);
- output.WriteString(MinimumClientVersion);
- }
- }
-
- public int CalculateSize() {
- int size = 0;
- if (fortSettings_ != null) {
- size += 1 + pb::CodedOutputStream.ComputeMessageSize(FortSettings);
- }
- if (mapSettings_ != null) {
- size += 1 + pb::CodedOutputStream.ComputeMessageSize(MapSettings);
- }
- if (levelSettings_ != null) {
- size += 1 + pb::CodedOutputStream.ComputeMessageSize(LevelSettings);
- }
- if (inventorySettings_ != null) {
- size += 1 + pb::CodedOutputStream.ComputeMessageSize(InventorySettings);
- }
- if (MinimumClientVersion.Length != 0) {
- size += 1 + pb::CodedOutputStream.ComputeStringSize(MinimumClientVersion);
- }
- return size;
- }
-
- public void MergeFrom(GlobalSettingsProto other) {
- if (other == null) {
- return;
- }
- if (other.fortSettings_ != null) {
- if (fortSettings_ == null) {
- fortSettings_ = new global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.FortSettingsProto();
- }
- FortSettings.MergeFrom(other.FortSettings);
- }
- if (other.mapSettings_ != null) {
- if (mapSettings_ == null) {
- mapSettings_ = new global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.MapSettingsProto();
- }
- MapSettings.MergeFrom(other.MapSettings);
- }
- if (other.levelSettings_ != null) {
- if (levelSettings_ == null) {
- levelSettings_ = new global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.LevelSettingsProto();
- }
- LevelSettings.MergeFrom(other.LevelSettings);
- }
- if (other.inventorySettings_ != null) {
- if (inventorySettings_ == null) {
- inventorySettings_ = new global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.InventorySettingsProto();
- }
- InventorySettings.MergeFrom(other.InventorySettings);
- }
- if (other.MinimumClientVersion.Length != 0) {
- MinimumClientVersion = other.MinimumClientVersion;
- }
- }
-
- public void MergeFrom(pb::CodedInputStream input) {
- uint tag;
- while ((tag = input.ReadTag()) != 0) {
- switch(tag) {
- default:
- input.SkipLastField();
- break;
- case 18: {
- if (fortSettings_ == null) {
- fortSettings_ = new global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.FortSettingsProto();
- }
- input.ReadMessage(fortSettings_);
- break;
- }
- case 26: {
- if (mapSettings_ == null) {
- mapSettings_ = new global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.MapSettingsProto();
- }
- input.ReadMessage(mapSettings_);
- break;
- }
- case 34: {
- if (levelSettings_ == null) {
- levelSettings_ = new global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.LevelSettingsProto();
- }
- input.ReadMessage(levelSettings_);
- break;
- }
- case 42: {
- if (inventorySettings_ == null) {
- inventorySettings_ = new global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Types.InventorySettingsProto();
- }
- input.ReadMessage(inventorySettings_);
- break;
- }
- case 50: {
- MinimumClientVersion = input.ReadString();
- break;
- }
- }
- }
- }
-
- }
-
- [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
- public sealed partial class FortSettingsProto : pb::IMessage<FortSettingsProto> {
- private static readonly pb::MessageParser<FortSettingsProto> _parser = new pb::MessageParser<FortSettingsProto>(() => new FortSettingsProto());
- public static pb::MessageParser<FortSettingsProto> Parser { get { return _parser; } }
-
- public static pbr::MessageDescriptor Descriptor {
- get { return global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Descriptor.NestedTypes[2]; }
- }
-
- pbr::MessageDescriptor pb::IMessage.Descriptor {
- get { return Descriptor; }
- }
-
- public FortSettingsProto() {
- OnConstruction();
- }
-
- partial void OnConstruction();
-
- public FortSettingsProto(FortSettingsProto other) : this() {
- interactionRangeMeters_ = other.interactionRangeMeters_;
- maxTotalDeployedPokemon_ = other.maxTotalDeployedPokemon_;
- maxPlayerDeployedPokemon_ = other.maxPlayerDeployedPokemon_;
- deployStaminaMultiplier_ = other.deployStaminaMultiplier_;
- deployAttackMultiplier_ = other.deployAttackMultiplier_;
- farInteractionRangeMeters_ = other.farInteractionRangeMeters_;
- }
-
- public FortSettingsProto Clone() {
- return new FortSettingsProto(this);
- }
-
- /// <summary>Field number for the "InteractionRangeMeters" field.</summary>
- public const int InteractionRangeMetersFieldNumber = 1;
- private double interactionRangeMeters_;
- public double InteractionRangeMeters {
- get { return interactionRangeMeters_; }
- set {
- interactionRangeMeters_ = value;
- }
- }
-
- /// <summary>Field number for the "MaxTotalDeployedPokemon" field.</summary>
- public const int MaxTotalDeployedPokemonFieldNumber = 2;
- private int maxTotalDeployedPokemon_;
- public int MaxTotalDeployedPokemon {
- get { return maxTotalDeployedPokemon_; }
- set {
- maxTotalDeployedPokemon_ = value;
- }
- }
-
- /// <summary>Field number for the "MaxPlayerDeployedPokemon" field.</summary>
- public const int MaxPlayerDeployedPokemonFieldNumber = 3;
- private int maxPlayerDeployedPokemon_;
- public int MaxPlayerDeployedPokemon {
- get { return maxPlayerDeployedPokemon_; }
- set {
- maxPlayerDeployedPokemon_ = value;
- }
- }
-
- /// <summary>Field number for the "DeployStaminaMultiplier" field.</summary>
- public const int DeployStaminaMultiplierFieldNumber = 4;
- private double deployStaminaMultiplier_;
- public double DeployStaminaMultiplier {
- get { return deployStaminaMultiplier_; }
- set {
- deployStaminaMultiplier_ = value;
- }
- }
-
- /// <summary>Field number for the "DeployAttackMultiplier" field.</summary>
- public const int DeployAttackMultiplierFieldNumber = 5;
- private double deployAttackMultiplier_;
- public double DeployAttackMultiplier {
- get { return deployAttackMultiplier_; }
- set {
- deployAttackMultiplier_ = value;
- }
- }
-
- /// <summary>Field number for the "FarInteractionRangeMeters" field.</summary>
- public const int FarInteractionRangeMetersFieldNumber = 6;
- private double farInteractionRangeMeters_;
- public double FarInteractionRangeMeters {
- get { return farInteractionRangeMeters_; }
- set {
- farInteractionRangeMeters_ = value;
- }
- }
-
- public override bool Equals(object other) {
- return Equals(other as FortSettingsProto);
- }
-
- public bool Equals(FortSettingsProto other) {
- if (ReferenceEquals(other, null)) {
- return false;
- }
- if (ReferenceEquals(other, this)) {
- return true;
- }
- if (InteractionRangeMeters != other.InteractionRangeMeters) return false;
- if (MaxTotalDeployedPokemon != other.MaxTotalDeployedPokemon) return false;
- if (MaxPlayerDeployedPokemon != other.MaxPlayerDeployedPokemon) return false;
- if (DeployStaminaMultiplier != other.DeployStaminaMultiplier) return false;
- if (DeployAttackMultiplier != other.DeployAttackMultiplier) return false;
- if (FarInteractionRangeMeters != other.FarInteractionRangeMeters) return false;
- return true;
- }
-
- public override int GetHashCode() {
- int hash = 1;
- if (InteractionRangeMeters != 0D) hash ^= InteractionRangeMeters.GetHashCode();
- if (MaxTotalDeployedPokemon != 0) hash ^= MaxTotalDeployedPokemon.GetHashCode();
- if (MaxPlayerDeployedPokemon != 0) hash ^= MaxPlayerDeployedPokemon.GetHashCode();
- if (DeployStaminaMultiplier != 0D) hash ^= DeployStaminaMultiplier.GetHashCode();
- if (DeployAttackMultiplier != 0D) hash ^= DeployAttackMultiplier.GetHashCode();
- if (FarInteractionRangeMeters != 0D) hash ^= FarInteractionRangeMeters.GetHashCode();
- return hash;
- }
-
- public override string ToString() {
- return pb::JsonFormatter.ToDiagnosticString(this);
- }
-
- public void WriteTo(pb::CodedOutputStream output) {
- if (InteractionRangeMeters != 0D) {
- output.WriteRawTag(9);
- output.WriteDouble(InteractionRangeMeters);
- }
- if (MaxTotalDeployedPokemon != 0) {
- output.WriteRawTag(16);
- output.WriteInt32(MaxTotalDeployedPokemon);
- }
- if (MaxPlayerDeployedPokemon != 0) {
- output.WriteRawTag(24);
- output.WriteInt32(MaxPlayerDeployedPokemon);
- }
- if (DeployStaminaMultiplier != 0D) {
- output.WriteRawTag(33);
- output.WriteDouble(DeployStaminaMultiplier);
- }
- if (DeployAttackMultiplier != 0D) {
- output.WriteRawTag(41);
- output.WriteDouble(DeployAttackMultiplier);
- }
- if (FarInteractionRangeMeters != 0D) {
- output.WriteRawTag(49);
- output.WriteDouble(FarInteractionRangeMeters);
- }
- }
-
- public int CalculateSize() {
- int size = 0;
- if (InteractionRangeMeters != 0D) {
- size += 1 + 8;
- }
- if (MaxTotalDeployedPokemon != 0) {
- size += 1 + pb::CodedOutputStream.ComputeInt32Size(MaxTotalDeployedPokemon);
- }
- if (MaxPlayerDeployedPokemon != 0) {
- size += 1 + pb::CodedOutputStream.ComputeInt32Size(MaxPlayerDeployedPokemon);
- }
- if (DeployStaminaMultiplier != 0D) {
- size += 1 + 8;
- }
- if (DeployAttackMultiplier != 0D) {
- size += 1 + 8;
- }
- if (FarInteractionRangeMeters != 0D) {
- size += 1 + 8;
- }
- return size;
- }
-
- public void MergeFrom(FortSettingsProto other) {
- if (other == null) {
- return;
- }
- if (other.InteractionRangeMeters != 0D) {
- InteractionRangeMeters = other.InteractionRangeMeters;
- }
- if (other.MaxTotalDeployedPokemon != 0) {
- MaxTotalDeployedPokemon = other.MaxTotalDeployedPokemon;
- }
- if (other.MaxPlayerDeployedPokemon != 0) {
- MaxPlayerDeployedPokemon = other.MaxPlayerDeployedPokemon;
- }
- if (other.DeployStaminaMultiplier != 0D) {
- DeployStaminaMultiplier = other.DeployStaminaMultiplier;
- }
- if (other.DeployAttackMultiplier != 0D) {
- DeployAttackMultiplier = other.DeployAttackMultiplier;
- }
- if (other.FarInteractionRangeMeters != 0D) {
- FarInteractionRangeMeters = other.FarInteractionRangeMeters;
- }
- }
-
- public void MergeFrom(pb::CodedInputStream input) {
- uint tag;
- while ((tag = input.ReadTag()) != 0) {
- switch(tag) {
- default:
- input.SkipLastField();
- break;
- case 9: {
- InteractionRangeMeters = input.ReadDouble();
- break;
- }
- case 16: {
- MaxTotalDeployedPokemon = input.ReadInt32();
- break;
- }
- case 24: {
- MaxPlayerDeployedPokemon = input.ReadInt32();
- break;
- }
- case 33: {
- DeployStaminaMultiplier = input.ReadDouble();
- break;
- }
- case 41: {
- DeployAttackMultiplier = input.ReadDouble();
- break;
- }
- case 49: {
- FarInteractionRangeMeters = input.ReadDouble();
- break;
- }
- }
- }
- }
-
- }
-
- [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
- public sealed partial class MapSettingsProto : pb::IMessage<MapSettingsProto> {
- private static readonly pb::MessageParser<MapSettingsProto> _parser = new pb::MessageParser<MapSettingsProto>(() => new MapSettingsProto());
- public static pb::MessageParser<MapSettingsProto> Parser { get { return _parser; } }
-
- public static pbr::MessageDescriptor Descriptor {
- get { return global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Descriptor.NestedTypes[3]; }
- }
-
- pbr::MessageDescriptor pb::IMessage.Descriptor {
- get { return Descriptor; }
- }
-
- public MapSettingsProto() {
- OnConstruction();
- }
-
- partial void OnConstruction();
-
- public MapSettingsProto(MapSettingsProto other) : this() {
- pokemonVisibleRange_ = other.pokemonVisibleRange_;
- pokeNavRangeMeters_ = other.pokeNavRangeMeters_;
- encounterRangeMeters_ = other.encounterRangeMeters_;
- getMapObjectsMinRefreshSeconds_ = other.getMapObjectsMinRefreshSeconds_;
- getMapObjectsMaxRefreshSeconds_ = other.getMapObjectsMaxRefreshSeconds_;
- getMapObjectsMinDistanceMeters_ = other.getMapObjectsMinDistanceMeters_;
- googleMapsApiKey_ = other.googleMapsApiKey_;
- }
-
- public MapSettingsProto Clone() {
- return new MapSettingsProto(this);
- }
-
- /// <summary>Field number for the "PokemonVisibleRange" field.</summary>
- public const int PokemonVisibleRangeFieldNumber = 1;
- private double pokemonVisibleRange_;
- public double PokemonVisibleRange {
- get { return pokemonVisibleRange_; }
- set {
- pokemonVisibleRange_ = value;
- }
- }
-
- /// <summary>Field number for the "PokeNavRangeMeters" field.</summary>
- public const int PokeNavRangeMetersFieldNumber = 2;
- private double pokeNavRangeMeters_;
- public double PokeNavRangeMeters {
- get { return pokeNavRangeMeters_; }
- set {
- pokeNavRangeMeters_ = value;
- }
- }
-
- /// <summary>Field number for the "EncounterRangeMeters" field.</summary>
- public const int EncounterRangeMetersFieldNumber = 3;
- private double encounterRangeMeters_;
- public double EncounterRangeMeters {
- get { return encounterRangeMeters_; }
- set {
- encounterRangeMeters_ = value;
- }
- }
-
- /// <summary>Field number for the "GetMapObjectsMinRefreshSeconds" field.</summary>
- public const int GetMapObjectsMinRefreshSecondsFieldNumber = 4;
- private float getMapObjectsMinRefreshSeconds_;
- public float GetMapObjectsMinRefreshSeconds {
- get { return getMapObjectsMinRefreshSeconds_; }
- set {
- getMapObjectsMinRefreshSeconds_ = value;
- }
- }
-
- /// <summary>Field number for the "GetMapObjectsMaxRefreshSeconds" field.</summary>
- public const int GetMapObjectsMaxRefreshSecondsFieldNumber = 5;
- private float getMapObjectsMaxRefreshSeconds_;
- public float GetMapObjectsMaxRefreshSeconds {
- get { return getMapObjectsMaxRefreshSeconds_; }
- set {
- getMapObjectsMaxRefreshSeconds_ = value;
- }
- }
-
- /// <summary>Field number for the "GetMapObjectsMinDistanceMeters" field.</summary>
- public const int GetMapObjectsMinDistanceMetersFieldNumber = 6;
- private float getMapObjectsMinDistanceMeters_;
- public float GetMapObjectsMinDistanceMeters {
- get { return getMapObjectsMinDistanceMeters_; }
- set {
- getMapObjectsMinDistanceMeters_ = value;
- }
- }
-
- /// <summary>Field number for the "GoogleMapsApiKey" field.</summary>
- public const int GoogleMapsApiKeyFieldNumber = 7;
- private string googleMapsApiKey_ = "";
- public string GoogleMapsApiKey {
- get { return googleMapsApiKey_; }
- set {
- googleMapsApiKey_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
- }
- }
-
- public override bool Equals(object other) {
- return Equals(other as MapSettingsProto);
- }
-
- public bool Equals(MapSettingsProto other) {
- if (ReferenceEquals(other, null)) {
- return false;
- }
- if (ReferenceEquals(other, this)) {
- return true;
- }
- if (PokemonVisibleRange != other.PokemonVisibleRange) return false;
- if (PokeNavRangeMeters != other.PokeNavRangeMeters) return false;
- if (EncounterRangeMeters != other.EncounterRangeMeters) return false;
- if (GetMapObjectsMinRefreshSeconds != other.GetMapObjectsMinRefreshSeconds) return false;
- if (GetMapObjectsMaxRefreshSeconds != other.GetMapObjectsMaxRefreshSeconds) return false;
- if (GetMapObjectsMinDistanceMeters != other.GetMapObjectsMinDistanceMeters) return false;
- if (GoogleMapsApiKey != other.GoogleMapsApiKey) return false;
- return true;
- }
-
- public override int GetHashCode() {
- int hash = 1;
- if (PokemonVisibleRange != 0D) hash ^= PokemonVisibleRange.GetHashCode();
- if (PokeNavRangeMeters != 0D) hash ^= PokeNavRangeMeters.GetHashCode();
- if (EncounterRangeMeters != 0D) hash ^= EncounterRangeMeters.GetHashCode();
- if (GetMapObjectsMinRefreshSeconds != 0F) hash ^= GetMapObjectsMinRefreshSeconds.GetHashCode();
- if (GetMapObjectsMaxRefreshSeconds != 0F) hash ^= GetMapObjectsMaxRefreshSeconds.GetHashCode();
- if (GetMapObjectsMinDistanceMeters != 0F) hash ^= GetMapObjectsMinDistanceMeters.GetHashCode();
- if (GoogleMapsApiKey.Length != 0) hash ^= GoogleMapsApiKey.GetHashCode();
- return hash;
- }
-
- public override string ToString() {
- return pb::JsonFormatter.ToDiagnosticString(this);
- }
-
- public void WriteTo(pb::CodedOutputStream output) {
- if (PokemonVisibleRange != 0D) {
- output.WriteRawTag(9);
- output.WriteDouble(PokemonVisibleRange);
- }
- if (PokeNavRangeMeters != 0D) {
- output.WriteRawTag(17);
- output.WriteDouble(PokeNavRangeMeters);
- }
- if (EncounterRangeMeters != 0D) {
- output.WriteRawTag(25);
- output.WriteDouble(EncounterRangeMeters);
- }
- if (GetMapObjectsMinRefreshSeconds != 0F) {
- output.WriteRawTag(37);
- output.WriteFloat(GetMapObjectsMinRefreshSeconds);
- }
- if (GetMapObjectsMaxRefreshSeconds != 0F) {
- output.WriteRawTag(45);
- output.WriteFloat(GetMapObjectsMaxRefreshSeconds);
- }
- if (GetMapObjectsMinDistanceMeters != 0F) {
- output.WriteRawTag(53);
- output.WriteFloat(GetMapObjectsMinDistanceMeters);
- }
- if (GoogleMapsApiKey.Length != 0) {
- output.WriteRawTag(58);
- output.WriteString(GoogleMapsApiKey);
- }
- }
-
- public int CalculateSize() {
- int size = 0;
- if (PokemonVisibleRange != 0D) {
- size += 1 + 8;
- }
- if (PokeNavRangeMeters != 0D) {
- size += 1 + 8;
- }
- if (EncounterRangeMeters != 0D) {
- size += 1 + 8;
- }
- if (GetMapObjectsMinRefreshSeconds != 0F) {
- size += 1 + 4;
- }
- if (GetMapObjectsMaxRefreshSeconds != 0F) {
- size += 1 + 4;
- }
- if (GetMapObjectsMinDistanceMeters != 0F) {
- size += 1 + 4;
- }
- if (GoogleMapsApiKey.Length != 0) {
- size += 1 + pb::CodedOutputStream.ComputeStringSize(GoogleMapsApiKey);
- }
- return size;
- }
-
- public void MergeFrom(MapSettingsProto other) {
- if (other == null) {
- return;
- }
- if (other.PokemonVisibleRange != 0D) {
- PokemonVisibleRange = other.PokemonVisibleRange;
- }
- if (other.PokeNavRangeMeters != 0D) {
- PokeNavRangeMeters = other.PokeNavRangeMeters;
- }
- if (other.EncounterRangeMeters != 0D) {
- EncounterRangeMeters = other.EncounterRangeMeters;
- }
- if (other.GetMapObjectsMinRefreshSeconds != 0F) {
- GetMapObjectsMinRefreshSeconds = other.GetMapObjectsMinRefreshSeconds;
- }
- if (other.GetMapObjectsMaxRefreshSeconds != 0F) {
- GetMapObjectsMaxRefreshSeconds = other.GetMapObjectsMaxRefreshSeconds;
- }
- if (other.GetMapObjectsMinDistanceMeters != 0F) {
- GetMapObjectsMinDistanceMeters = other.GetMapObjectsMinDistanceMeters;
- }
- if (other.GoogleMapsApiKey.Length != 0) {
- GoogleMapsApiKey = other.GoogleMapsApiKey;
- }
- }
-
- public void MergeFrom(pb::CodedInputStream input) {
- uint tag;
- while ((tag = input.ReadTag()) != 0) {
- switch(tag) {
- default:
- input.SkipLastField();
- break;
- case 9: {
- PokemonVisibleRange = input.ReadDouble();
- break;
- }
- case 17: {
- PokeNavRangeMeters = input.ReadDouble();
- break;
- }
- case 25: {
- EncounterRangeMeters = input.ReadDouble();
- break;
- }
- case 37: {
- GetMapObjectsMinRefreshSeconds = input.ReadFloat();
- break;
- }
- case 45: {
- GetMapObjectsMaxRefreshSeconds = input.ReadFloat();
- break;
- }
- case 53: {
- GetMapObjectsMinDistanceMeters = input.ReadFloat();
- break;
- }
- case 58: {
- GoogleMapsApiKey = input.ReadString();
- break;
- }
- }
- }
- }
-
- }
-
- [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
- public sealed partial class LevelSettingsProto : pb::IMessage<LevelSettingsProto> {
- private static readonly pb::MessageParser<LevelSettingsProto> _parser = new pb::MessageParser<LevelSettingsProto>(() => new LevelSettingsProto());
- public static pb::MessageParser<LevelSettingsProto> Parser { get { return _parser; } }
-
- public static pbr::MessageDescriptor Descriptor {
- get { return global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Descriptor.NestedTypes[4]; }
- }
-
- pbr::MessageDescriptor pb::IMessage.Descriptor {
- get { return Descriptor; }
- }
-
- public LevelSettingsProto() {
- OnConstruction();
- }
-
- partial void OnConstruction();
-
- public LevelSettingsProto(LevelSettingsProto other) : this() {
- trainerCpModifier_ = other.trainerCpModifier_;
- trainerDifficultyModifier_ = other.trainerDifficultyModifier_;
- }
-
- public LevelSettingsProto Clone() {
- return new LevelSettingsProto(this);
- }
-
- /// <summary>Field number for the "TrainerCpModifier" field.</summary>
- public const int TrainerCpModifierFieldNumber = 2;
- private double trainerCpModifier_;
- public double TrainerCpModifier {
- get { return trainerCpModifier_; }
- set {
- trainerCpModifier_ = value;
- }
- }
-
- /// <summary>Field number for the "TrainerDifficultyModifier" field.</summary>
- public const int TrainerDifficultyModifierFieldNumber = 3;
- private double trainerDifficultyModifier_;
- public double TrainerDifficultyModifier {
- get { return trainerDifficultyModifier_; }
- set {
- trainerDifficultyModifier_ = value;
- }
- }
-
- public override bool Equals(object other) {
- return Equals(other as LevelSettingsProto);
- }
-
- public bool Equals(LevelSettingsProto other) {
- if (ReferenceEquals(other, null)) {
- return false;
- }
- if (ReferenceEquals(other, this)) {
- return true;
- }
- if (TrainerCpModifier != other.TrainerCpModifier) return false;
- if (TrainerDifficultyModifier != other.TrainerDifficultyModifier) return false;
- return true;
- }
-
- public override int GetHashCode() {
- int hash = 1;
- if (TrainerCpModifier != 0D) hash ^= TrainerCpModifier.GetHashCode();
- if (TrainerDifficultyModifier != 0D) hash ^= TrainerDifficultyModifier.GetHashCode();
- return hash;
- }
-
- public override string ToString() {
- return pb::JsonFormatter.ToDiagnosticString(this);
- }
-
- public void WriteTo(pb::CodedOutputStream output) {
- if (TrainerCpModifier != 0D) {
- output.WriteRawTag(17);
- output.WriteDouble(TrainerCpModifier);
- }
- if (TrainerDifficultyModifier != 0D) {
- output.WriteRawTag(25);
- output.WriteDouble(TrainerDifficultyModifier);
- }
- }
-
- public int CalculateSize() {
- int size = 0;
- if (TrainerCpModifier != 0D) {
- size += 1 + 8;
- }
- if (TrainerDifficultyModifier != 0D) {
- size += 1 + 8;
- }
- return size;
- }
-
- public void MergeFrom(LevelSettingsProto other) {
- if (other == null) {
- return;
- }
- if (other.TrainerCpModifier != 0D) {
- TrainerCpModifier = other.TrainerCpModifier;
- }
- if (other.TrainerDifficultyModifier != 0D) {
- TrainerDifficultyModifier = other.TrainerDifficultyModifier;
- }
- }
-
- public void MergeFrom(pb::CodedInputStream input) {
- uint tag;
- while ((tag = input.ReadTag()) != 0) {
- switch(tag) {
- default:
- input.SkipLastField();
- break;
- case 17: {
- TrainerCpModifier = input.ReadDouble();
- break;
- }
- case 25: {
- TrainerDifficultyModifier = input.ReadDouble();
- break;
- }
- }
- }
- }
-
- }
-
- [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
- public sealed partial class InventorySettingsProto : pb::IMessage<InventorySettingsProto> {
- private static readonly pb::MessageParser<InventorySettingsProto> _parser = new pb::MessageParser<InventorySettingsProto>(() => new InventorySettingsProto());
- public static pb::MessageParser<InventorySettingsProto> Parser { get { return _parser; } }
-
- public static pbr::MessageDescriptor Descriptor {
- get { return global::PokemonGo.RocketAPI.GeneratedCode.ProfileResponse.Types.Payload.Descriptor.NestedTypes[5]; }
- }
-
- pbr::MessageDescriptor pb::IMessage.Descriptor {
- get { return Descriptor; }
- }
-
- public InventorySettingsProto() {
- OnConstruction();
- }
-
- partial void OnConstruction();
-
- public InventorySettingsProto(InventorySettingsProto other) : this() {
- maxPokemon_ = other.maxPokemon_;
- maxBagItems_ = other.maxBagItems_;
- basePokemon_ = other.basePokemon_;
- baseBagItems_ = other.baseBagItems_;
- baseEggs_ = other.baseEggs_;
- }
-
- public InventorySettingsProto Clone() {
- return new InventorySettingsProto(this);
- }
-
- /// <summary>Field number for the "MaxPokemon" field.</summary>
- public const int MaxPokemonFieldNumber = 1;
- private int maxPokemon_;
- public int MaxPokemon {
- get { return maxPokemon_; }
- set {
- maxPokemon_ = value;
- }
- }
-
- /// <summary>Field number for the "MaxBagItems" field.</summary>
- public const int MaxBagItemsFieldNumber = 2;
- private int maxBagItems_;
- public int MaxBagItems {
- get { return maxBagItems_; }
- set {
- maxBagItems_ = value;
- }
- }
-
- /// <summary>Field number for the "BasePokemon" field.</summary>
- public const int BasePokemonFieldNumber = 3;
- private int basePokemon_;
- public int BasePokemon {
- get { return basePokemon_; }
- set {
- basePokemon_ = value;
- }
- }
-
- /// <summary>Field number for the "BaseBagItems" field.</summary>
- public const int BaseBagItemsFieldNumber = 4;
- private int baseBagItems_;
- public int BaseBagItems {
- get { return baseBagItems_; }
- set {
- baseBagItems_ = value;
- }
- }
-
- /// <summary>Field number for the "BaseEggs" field.</summary>
- public const int BaseEggsFieldNumber = 5;
- private int baseEggs_;
- public int BaseEggs {
- get { return baseEggs_; }
- set {
- baseEggs_ = value;
- }
- }
-
- public override bool Equals(object other) {
- return Equals(other as InventorySettingsProto);
- }
-
- public bool Equals(InventorySettingsProto other) {
- if (ReferenceEquals(other, null)) {
- return false;
- }
- if (ReferenceEquals(other, this)) {
- return true;
- }
- if (MaxPokemon != other.MaxPokemon) return false;
- if (MaxBagItems != other.MaxBagItems) return false;
- if (BasePokemon != other.BasePokemon) return false;
- if (BaseBagItems != other.BaseBagItems) return false;
- if (BaseEggs != other.BaseEggs) return false;
- return true;
- }
-
- public override int GetHashCode() {
- int hash = 1;
- if (MaxPokemon != 0) hash ^= MaxPokemon.GetHashCode();
- if (MaxBagItems != 0) hash ^= MaxBagItems.GetHashCode();
- if (BasePokemon != 0) hash ^= BasePokemon.GetHashCode();
- if (BaseBagItems != 0) hash ^= BaseBagItems.GetHashCode();
- if (BaseEggs != 0) hash ^= BaseEggs.GetHashCode();
- return hash;
- }
-
- public override string ToString() {
- return pb::JsonFormatter.ToDiagnosticString(this);
- }
-
- public void WriteTo(pb::CodedOutputStream output) {
- if (MaxPokemon != 0) {
- output.WriteRawTag(8);
- output.WriteInt32(MaxPokemon);
- }
- if (MaxBagItems != 0) {
- output.WriteRawTag(16);
- output.WriteInt32(MaxBagItems);
- }
- if (BasePokemon != 0) {
- output.WriteRawTag(24);
- output.WriteInt32(BasePokemon);
- }
- if (BaseBagItems != 0) {
- output.WriteRawTag(32);
- output.WriteInt32(BaseBagItems);
- }
- if (BaseEggs != 0) {
- output.WriteRawTag(40);
- output.WriteInt32(BaseEggs);
- }
- }
-
- public int CalculateSize() {
- int size = 0;
- if (MaxPokemon != 0) {
- size += 1 + pb::CodedOutputStream.ComputeInt32Size(MaxPokemon);
- }
- if (MaxBagItems != 0) {
- size += 1 + pb::CodedOutputStream.ComputeInt32Size(MaxBagItems);
- }
- if (BasePokemon != 0) {
- size += 1 + pb::CodedOutputStream.ComputeInt32Size(BasePokemon);
- }
- if (BaseBagItems != 0) {
- size += 1 + pb::CodedOutputStream.ComputeInt32Size(BaseBagItems);
- }
- if (BaseEggs != 0) {
- size += 1 + pb::CodedOutputStream.ComputeInt32Size(BaseEggs);
- }
- return size;
- }
-
- public void MergeFrom(InventorySettingsProto other) {
- if (other == null) {
- return;
- }
- if (other.MaxPokemon != 0) {
- MaxPokemon = other.MaxPokemon;
- }
- if (other.MaxBagItems != 0) {
- MaxBagItems = other.MaxBagItems;
- }
- if (other.BasePokemon != 0) {
- BasePokemon = other.BasePokemon;
- }
- if (other.BaseBagItems != 0) {
- BaseBagItems = other.BaseBagItems;
- }
- if (other.BaseEggs != 0) {
- BaseEggs = other.BaseEggs;
- }
- }
-
- public void MergeFrom(pb::CodedInputStream input) {
- uint tag;
- while ((tag = input.ReadTag()) != 0) {
- switch(tag) {
- default:
- input.SkipLastField();
- break;
- case 8: {
- MaxPokemon = input.ReadInt32();
- break;
- }
- case 16: {
- MaxBagItems = input.ReadInt32();
- break;
- }
- case 24: {
- BasePokemon = input.ReadInt32();
- break;
- }
- case 32: {
- BaseBagItems = input.ReadInt32();
- break;
- }
- case 40: {
- BaseEggs = input.ReadInt32();
- break;
- }
- }
- }
- }
-
- }
-
}
#endregion
diff --git a/PokemonGo/RocketAPI/GeneratedCode/Request.cs b/PokemonGo/RocketAPI/GeneratedCode/Request.cs
index 0e0641e..790cd0d 100644
--- a/PokemonGo/RocketAPI/GeneratedCode/Request.cs
+++ b/PokemonGo/RocketAPI/GeneratedCode/Request.cs
@@ -24,27 +24,30 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
byte[] descriptorData = global::System.Convert.FromBase64String(
string.Concat(
"Cg1SZXF1ZXN0LnByb3RvEiFQb2tlbW9uR28uUm9ja2V0QVBJLkdlbmVyYXRl",
- "ZENvZGUi5AUKB1JlcXVlc3QSEAoIdW5rbm93bjEYASABKAUSDgoGcnBjX2lk",
+ "ZENvZGUixAYKB1JlcXVlc3QSEAoIdW5rbm93bjEYASABKAUSDgoGcnBjX2lk",
"GAMgASgDEkUKCHJlcXVlc3RzGAQgAygLMjMuUG9rZW1vbkdvLlJvY2tldEFQ",
"SS5HZW5lcmF0ZWRDb2RlLlJlcXVlc3QuUmVxdWVzdHMSRQoIdW5rbm93bjYY",
"BiABKAsyMy5Qb2tlbW9uR28uUm9ja2V0QVBJLkdlbmVyYXRlZENvZGUuUmVx",
- "dWVzdC5Vbmtub3duNhIQCghsYXRpdHVkZRgHIAEoARIRCglsb25naXR1ZGUY",
- "CCABKAESEAoIYWx0aXR1ZGUYCSABKAESQQoEYXV0aBgKIAEoCzIzLlBva2Vt",
+ "dWVzdC5Vbmtub3duNhIQCghsYXRpdHVkZRgHIAEoBhIRCglsb25naXR1ZGUY",
+ "CCABKAYSEAoIYWx0aXR1ZGUYCSABKAYSQQoEYXV0aBgKIAEoCzIzLlBva2Vt",
"b25Hby5Sb2NrZXRBUEkuR2VuZXJhdGVkQ29kZS5SZXF1ZXN0LkF1dGhJbmZv",
- "EhEKCXVua25vd24xMhgMIAEoAxpeCghSZXF1ZXN0cxIMCgR0eXBlGAEgASgF",
- "EkQKB21lc3NhZ2UYAiABKAsyMy5Qb2tlbW9uR28uUm9ja2V0QVBJLkdlbmVy",
- "Y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IYASABKAkSRgoFdG9rZW4YAiABKAsyNy5Qb2tlbW9uR28uUm9ja2V0QVBJ",
+ "LkdlbmVyYXRlZENvZGUuUmVxdWVzdC5BdXRoSW5mby5KV1QaKgoDSldUEhAK",
+ "CGNvbnRlbnRzGAEgASgJEhEKCXVua25vd24xMxgCIAEoBWIGcHJvdG8z"));
descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData,
new pbr::FileDescriptor[] { },
new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] {
- new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.Request), global::PokemonGo.RocketAPI.GeneratedCode.Request.Parser, new[]{ "Unknown1", "RpcId", "Requests", "Unknown6", "Latitude", "Longitude", "Altitude", "Auth", "Unknown12" }, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.Request.Types.Requests), global::PokemonGo.RocketAPI.GeneratedCode.Request.Types.Requests.Parser, new[]{ "Type", "Message" }, null, null, null),
+ new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.Request), global::PokemonGo.RocketAPI.GeneratedCode.Request.Parser, new[]{ "Unknown1", "RpcId", "Requests", "Unknown6", "Latitude", "Longitude", "Altitude", "Auth", "Unknownauth", "Unknown12" }, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.Request.Types.UnknownAuth), global::PokemonGo.RocketAPI.GeneratedCode.Request.Types.UnknownAuth.Parser, new[]{ "Unknown71", "Timestamp", "Unknown73" }, null, null, null),
+ new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.Request.Types.Requests), global::PokemonGo.RocketAPI.GeneratedCode.Request.Types.Requests.Parser, new[]{ "Type", "Message" }, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.Request.Types.Unknown3), global::PokemonGo.RocketAPI.GeneratedCode.Request.Types.Unknown3.Parser, new[]{ "Unknown4" }, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.Request.Types.Unknown6), global::PokemonGo.RocketAPI.GeneratedCode.Request.Types.Unknown6.Parser, new[]{ "Unknown1", "Unknown2" }, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.Request.Types.Unknown6.Types.Unknown2), global::PokemonGo.RocketAPI.GeneratedCode.Request.Types.Unknown6.Types.Unknown2.Parser, new[]{ "Unknown1" }, null, null, null)}),
new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.Request.Types.AuthInfo), global::PokemonGo.RocketAPI.GeneratedCode.Request.Types.AuthInfo.Parser, new[]{ "Provider", "Token" }, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.Request.Types.AuthInfo.Types.JWT), global::PokemonGo.RocketAPI.GeneratedCode.Request.Types.AuthInfo.Types.JWT.Parser, new[]{ "Contents", "Unknown13" }, null, null, null)})})
@@ -82,6 +85,7 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
longitude_ = other.longitude_;
altitude_ = other.altitude_;
Auth = other.auth_ != null ? other.Auth.Clone() : null;
+ Unknownauth = other.unknownauth_ != null ? other.Unknownauth.Clone() : null;
unknown12_ = other.unknown12_;
}
@@ -130,8 +134,8 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
/// <summary>Field number for the "latitude" field.</summary>
public const int LatitudeFieldNumber = 7;
- private double latitude_;
- public double Latitude {
+ private ulong latitude_;
+ public ulong Latitude {
get { return latitude_; }
set {
latitude_ = value;
@@ -140,8 +144,8 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
/// <summary>Field number for the "longitude" field.</summary>
public const int LongitudeFieldNumber = 8;
- private double longitude_;
- public double Longitude {
+ private ulong longitude_;
+ public ulong Longitude {
get { return longitude_; }
set {
longitude_ = value;
@@ -150,8 +154,8 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
/// <summary>Field number for the "altitude" field.</summary>
public const int AltitudeFieldNumber = 9;
- private double altitude_;
- public double Altitude {
+ private ulong altitude_;
+ public ulong Altitude {
get { return altitude_; }
set {
altitude_ = value;
@@ -168,6 +172,16 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
}
}
+ /// <summary>Field number for the "unknownauth" field.</summary>
+ public const int UnknownauthFieldNumber = 11;
+ private global::PokemonGo.RocketAPI.GeneratedCode.Request.Types.UnknownAuth unknownauth_;
+ public global::PokemonGo.RocketAPI.GeneratedCode.Request.Types.UnknownAuth Unknownauth {
+ get { return unknownauth_; }
+ set {
+ unknownauth_ = value;
+ }
+ }
+
/// <summary>Field number for the "unknown12" field.</summary>
public const int Unknown12FieldNumber = 12;
private long unknown12_;
@@ -197,6 +211,7 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
if (Longitude != other.Longitude) return false;
if (Altitude != other.Altitude) return false;
if (!object.Equals(Auth, other.Auth)) return false;
+ if (!object.Equals(Unknownauth, other.Unknownauth)) return false;
if (Unknown12 != other.Unknown12) return false;
return true;
}
@@ -207,10 +222,11 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
if (RpcId != 0L) hash ^= RpcId.GetHashCode();
hash ^= requests_.GetHashCode();
if (unknown6_ != null) hash ^= Unknown6.GetHashCode();
- if (Latitude != 0D) hash ^= Latitude.GetHashCode();
- if (Longitude != 0D) hash ^= Longitude.GetHashCode();
- if (Altitude != 0D) hash ^= Altitude.GetHashCode();
+ if (Latitude != 0UL) hash ^= Latitude.GetHashCode();
+ if (Longitude != 0UL) hash ^= Longitude.GetHashCode();
+ if (Altitude != 0UL) hash ^= Altitude.GetHashCode();
if (auth_ != null) hash ^= Auth.GetHashCode();
+ if (unknownauth_ != null) hash ^= Unknownauth.GetHashCode();
if (Unknown12 != 0L) hash ^= Unknown12.GetHashCode();
return hash;
}
@@ -233,22 +249,26 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
output.WriteRawTag(50);
output.WriteMessage(Unknown6);
}
- if (Latitude != 0D) {
+ if (Latitude != 0UL) {
output.WriteRawTag(57);
- output.WriteDouble(Latitude);
+ output.WriteFixed64(Latitude);
}
- if (Longitude != 0D) {
+ if (Longitude != 0UL) {
output.WriteRawTag(65);
- output.WriteDouble(Longitude);
+ output.WriteFixed64(Longitude);
}
- if (Altitude != 0D) {
+ if (Altitude != 0UL) {
output.WriteRawTag(73);
- output.WriteDouble(Altitude);
+ output.WriteFixed64(Altitude);
}
if (auth_ != null) {
output.WriteRawTag(82);
output.WriteMessage(Auth);
}
+ if (unknownauth_ != null) {
+ output.WriteRawTag(90);
+ output.WriteMessage(Unknownauth);
+ }
if (Unknown12 != 0L) {
output.WriteRawTag(96);
output.WriteInt64(Unknown12);
@@ -267,18 +287,21 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
if (unknown6_ != null) {
size += 1 + pb::CodedOutputStream.ComputeMessageSize(Unknown6);
}
- if (Latitude != 0D) {
+ if (Latitude != 0UL) {
size += 1 + 8;
}
- if (Longitude != 0D) {
+ if (Longitude != 0UL) {
size += 1 + 8;
}
- if (Altitude != 0D) {
+ if (Altitude != 0UL) {
size += 1 + 8;
}
if (auth_ != null) {
size += 1 + pb::CodedOutputStream.ComputeMessageSize(Auth);
}
+ if (unknownauth_ != null) {
+ size += 1 + pb::CodedOutputStream.ComputeMessageSize(Unknownauth);
+ }
if (Unknown12 != 0L) {
size += 1 + pb::CodedOutputStream.ComputeInt64Size(Unknown12);
}
@@ -302,13 +325,13 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
}
Unknown6.MergeFrom(other.Unknown6);
}
- if (other.Latitude != 0D) {
+ if (other.Latitude != 0UL) {
Latitude = other.Latitude;
}
- if (other.Longitude != 0D) {
+ if (other.Longitude != 0UL) {
Longitude = other.Longitude;
}
- if (other.Altitude != 0D) {
+ if (other.Altitude != 0UL) {
Altitude = other.Altitude;
}
if (other.auth_ != null) {
@@ -317,6 +340,12 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
}
Auth.MergeFrom(other.Auth);
}
+ if (other.unknownauth_ != null) {
+ if (unknownauth_ == null) {
+ unknownauth_ = new global::PokemonGo.RocketAPI.GeneratedCode.Request.Types.UnknownAuth();
+ }
+ Unknownauth.MergeFrom(other.Unknownauth);
+ }
if (other.Unknown12 != 0L) {
Unknown12 = other.Unknown12;
}
@@ -349,15 +378,15 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
break;
}
case 57: {
- Latitude = input.ReadDouble();
+ Latitude = input.ReadFixed64();
break;
}
case 65: {
- Longitude = input.ReadDouble();
+ Longitude = input.ReadFixed64();
break;
}
case 73: {
- Altitude = input.ReadDouble();
+ Altitude = input.ReadFixed64();
break;
}
case 82: {
@@ -367,6 +396,13 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
input.ReadMessage(auth_);
break;
}
+ case 90: {
+ if (unknownauth_ == null) {
+ unknownauth_ = new global::PokemonGo.RocketAPI.GeneratedCode.Request.Types.UnknownAuth();
+ }
+ input.ReadMessage(unknownauth_);
+ break;
+ }
case 96: {
Unknown12 = input.ReadInt64();
break;
@@ -379,13 +415,170 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
/// <summary>Container for nested types declared in the Request message type.</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Types {
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ public sealed partial class UnknownAuth : pb::IMessage<UnknownAuth> {
+ private static readonly pb::MessageParser<UnknownAuth> _parser = new pb::MessageParser<UnknownAuth>(() => new UnknownAuth());
+ public static pb::MessageParser<UnknownAuth> Parser { get { return _parser; } }
+
+ public static pbr::MessageDescriptor Descriptor {
+ get { return global::PokemonGo.RocketAPI.GeneratedCode.Request.Descriptor.NestedTypes[0]; }
+ }
+
+ pbr::MessageDescriptor pb::IMessage.Descriptor {
+ get { return Descriptor; }
+ }
+
+ public UnknownAuth() {
+ OnConstruction();
+ }
+
+ partial void OnConstruction();
+
+ public UnknownAuth(UnknownAuth other) : this() {
+ unknown71_ = other.unknown71_;
+ timestamp_ = other.timestamp_;
+ unknown73_ = other.unknown73_;
+ }
+
+ public UnknownAuth Clone() {
+ return new UnknownAuth(this);
+ }
+
+ /// <summary>Field number for the "unknown71" field.</summary>
+ public const int Unknown71FieldNumber = 1;
+ private pb::ByteString unknown71_ = pb::ByteString.Empty;
+ public pb::ByteString Unknown71 {
+ get { return unknown71_; }
+ set {
+ unknown71_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
+ }
+ }
+
+ /// <summary>Field number for the "timestamp" field.</summary>
+ public const int TimestampFieldNumber = 2;
+ private long timestamp_;
+ public long Timestamp {
+ get { return timestamp_; }
+ set {
+ timestamp_ = value;
+ }
+ }
+
+ /// <summary>Field number for the "unknown73" field.</summary>
+ public const int Unknown73FieldNumber = 3;
+ private pb::ByteString unknown73_ = pb::ByteString.Empty;
+ public pb::ByteString Unknown73 {
+ get { return unknown73_; }
+ set {
+ unknown73_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
+ }
+ }
+
+ public override bool Equals(object other) {
+ return Equals(other as UnknownAuth);
+ }
+
+ public bool Equals(UnknownAuth other) {
+ if (ReferenceEquals(other, null)) {
+ return false;
+ }
+ if (ReferenceEquals(other, this)) {
+ return true;
+ }
+ if (Unknown71 != other.Unknown71) return false;
+ if (Timestamp != other.Timestamp) return false;
+ if (Unknown73 != other.Unknown73) return false;
+ return true;
+ }
+
+ public override int GetHashCode() {
+ int hash = 1;
+ if (Unknown71.Length != 0) hash ^= Unknown71.GetHashCode();
+ if (Timestamp != 0L) hash ^= Timestamp.GetHashCode();
+ if (Unknown73.Length != 0) hash ^= Unknown73.GetHashCode();
+ return hash;
+ }
+
+ public override string ToString() {
+ return pb::JsonFormatter.ToDiagnosticString(this);
+ }
+
+ public void WriteTo(pb::CodedOutputStream output) {
+ if (Unknown71.Length != 0) {
+ output.WriteRawTag(10);
+ output.WriteBytes(Unknown71);
+ }
+ if (Timestamp != 0L) {
+ output.WriteRawTag(16);
+ output.WriteInt64(Timestamp);
+ }
+ if (Unknown73.Length != 0) {
+ output.WriteRawTag(26);
+ output.WriteBytes(Unknown73);
+ }
+ }
+
+ public int CalculateSize() {
+ int size = 0;
+ if (Unknown71.Length != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeBytesSize(Unknown71);
+ }
+ if (Timestamp != 0L) {
+ size += 1 + pb::CodedOutputStream.ComputeInt64Size(Timestamp);
+ }
+ if (Unknown73.Length != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeBytesSize(Unknown73);
+ }
+ return size;
+ }
+
+ public void MergeFrom(UnknownAuth other) {
+ if (other == null) {
+ return;
+ }
+ if (other.Unknown71.Length != 0) {
+ Unknown71 = other.Unknown71;
+ }
+ if (other.Timestamp != 0L) {
+ Timestamp = other.Timestamp;
+ }
+ if (other.Unknown73.Length != 0) {
+ Unknown73 = other.Unknown73;
+ }
+ }
+
+ public void MergeFrom(pb::CodedInputStream input) {
+ uint tag;
+ while ((tag = input.ReadTag()) != 0) {
+ switch(tag) {
+ default:
+ input.SkipLastField();
+ break;
+ case 10: {
+ Unknown71 = input.ReadBytes();
+ break;
+ }
+ case 16: {
+ Timestamp = input.ReadInt64();
+ break;
+ }
+ case 26: {
+ Unknown73 = input.ReadBytes();
+ break;
+ }
+ }
+ }
+ }
+
+ }
+
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public sealed partial class Requests : pb::IMessage<Requests> {
private static readonly pb::MessageParser<Requests> _parser = new pb::MessageParser<Requests>(() => new Requests());
public static pb::MessageParser<Requests> Parser { get { return _parser; } }
public static pbr::MessageDescriptor Descriptor {
- get { return global::PokemonGo.RocketAPI.GeneratedCode.Request.Descriptor.NestedTypes[0]; }
+ get { return global::PokemonGo.RocketAPI.GeneratedCode.Request.Descriptor.NestedTypes[1]; }
}
pbr::MessageDescriptor pb::IMessage.Descriptor {
@@ -400,7 +593,7 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
public Requests(Requests other) : this() {
type_ = other.type_;
- Message = other.message_ != null ? other.Message.Clone() : null;
+ message_ = other.message_;
}
public Requests Clone() {
@@ -419,11 +612,11 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
/// <summary>Field number for the "message" field.</summary>
public const int MessageFieldNumber = 2;
- private global::PokemonGo.RocketAPI.GeneratedCode.Request.Types.Unknown3 message_;
- public global::PokemonGo.RocketAPI.GeneratedCode.Request.Types.Unknown3 Message {
+ private pb::ByteString message_ = pb::ByteString.Empty;
+ public pb::ByteString Message {
get { return message_; }
set {
- message_ = value;
+ message_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
}
}
@@ -439,14 +632,14 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
return true;
}
if (Type != other.Type) return false;
- if (!object.Equals(Message, other.Message)) return false;
+ if (Message != other.Message) return false;
return true;
}
public override int GetHashCode() {
int hash = 1;
if (Type != 0) hash ^= Type.GetHashCode();
- if (message_ != null) hash ^= Message.GetHashCode();
+ if (Message.Length != 0) hash ^= Message.GetHashCode();
return hash;
}
@@ -459,9 +652,9 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
output.WriteRawTag(8);
output.WriteInt32(Type);
}
- if (message_ != null) {
+ if (Message.Length != 0) {
output.WriteRawTag(18);
- output.WriteMessage(Message);
+ output.WriteBytes(Message);
}
}
@@ -470,8 +663,8 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
if (Type != 0) {
size += 1 + pb::CodedOutputStream.ComputeInt32Size(Type);
}
- if (message_ != null) {
- size += 1 + pb::CodedOutputStream.ComputeMessageSize(Message);
+ if (Message.Length != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeBytesSize(Message);
}
return size;
}
@@ -483,11 +676,8 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
if (other.Type != 0) {
Type = other.Type;
}
- if (other.message_ != null) {
- if (message_ == null) {
- message_ = new global::PokemonGo.RocketAPI.GeneratedCode.Request.Types.Unknown3();
- }
- Message.MergeFrom(other.Message);
+ if (other.Message.Length != 0) {
+ Message = other.Message;
}
}
@@ -503,10 +693,7 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
break;
}
case 18: {
- if (message_ == null) {
- message_ = new global::PokemonGo.RocketAPI.GeneratedCode.Request.Types.Unknown3();
- }
- input.ReadMessage(message_);
+ Message = input.ReadBytes();
break;
}
}
@@ -521,7 +708,7 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
public static pb::MessageParser<Unknown3> Parser { get { return _parser; } }
public static pbr::MessageDescriptor Descriptor {
- get { return global::PokemonGo.RocketAPI.GeneratedCode.Request.Descriptor.NestedTypes[1]; }
+ get { return global::PokemonGo.RocketAPI.GeneratedCode.Request.Descriptor.NestedTypes[2]; }
}
pbr::MessageDescriptor pb::IMessage.Descriptor {
@@ -624,7 +811,7 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
public static pb::MessageParser<Unknown6> Parser { get { return _parser; } }
public static pbr::MessageDescriptor Descriptor {
- get { return global::PokemonGo.RocketAPI.GeneratedCode.Request.Descriptor.NestedTypes[2]; }
+ get { return global::PokemonGo.RocketAPI.GeneratedCode.Request.Descriptor.NestedTypes[3]; }
}
pbr::MessageDescriptor pb::IMessage.Descriptor {
@@ -870,7 +1057,7 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
public static pb::MessageParser<AuthInfo> Parser { get { return _parser; } }
public static pbr::MessageDescriptor Descriptor {
- get { return global::PokemonGo.RocketAPI.GeneratedCode.Request.Descriptor.NestedTypes[3]; }
+ get { return global::PokemonGo.RocketAPI.GeneratedCode.Request.Descriptor.NestedTypes[4]; }
}
pbr::MessageDescriptor pb::IMessage.Descriptor {
diff --git a/PokemonGo/RocketAPI/GeneratedCode/SettingsResponse.cs b/PokemonGo/RocketAPI/GeneratedCode/SettingsResponse.cs
index 160159d..fdb7917 100644
--- a/PokemonGo/RocketAPI/GeneratedCode/SettingsResponse.cs
+++ b/PokemonGo/RocketAPI/GeneratedCode/SettingsResponse.cs
@@ -24,53 +24,52 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
byte[] descriptorData = global::System.Convert.FromBase64String(
string.Concat(
"ChZTZXR0aW5nc1Jlc3BvbnNlLnByb3RvEiFQb2tlbW9uR28uUm9ja2V0QVBJ",
- "LkdlbmVyYXRlZENvZGUipg4KEFNldHRpbmdzUmVzcG9uc2USEAoIdW5rbm93",
+ "LkdlbmVyYXRlZENvZGUimg4KEFNldHRpbmdzUmVzcG9uc2USEAoIdW5rbm93",
"bjEYASABKAUSEAoIdW5rbm93bjIYAiABKAMSDwoHYXBpX3VybBgDIAEoCRJO",
"Cgh1bmtub3duNhgGIAEoCzI8LlBva2Vtb25Hby5Sb2NrZXRBUEkuR2VuZXJh",
- "dGVkQ29kZS5TZXR0aW5nc1Jlc3BvbnNlLlVua25vd242Ek4KCHVua25vd243",
- "GAcgASgLMjwuUG9rZW1vbkdvLlJvY2tldEFQSS5HZW5lcmF0ZWRDb2RlLlNl",
- "dHRpbmdzUmVzcG9uc2UuVW5rbm93bjcSTAoHcGF5bG9hZBhkIAMoCzI7LlBv",
- "a2Vtb25Hby5Sb2NrZXRBUEkuR2VuZXJhdGVkQ29kZS5TZXR0aW5nc1Jlc3Bv",
- "bnNlLlBheWxvYWQSFAoMZXJyb3JNZXNzYWdlGGUgASgJGpMBCghVbmtub3du",
- "NhIQCgh1bmtub3duMRgBIAEoBRJXCgh1bmtub3duMhgCIAEoCzJFLlBva2Vt",
- "b25Hby5Sb2NrZXRBUEkuR2VuZXJhdGVkQ29kZS5TZXR0aW5nc1Jlc3BvbnNl",
- "LlVua25vd242LlVua25vd24yGhwKCFVua25vd24yEhAKCHVua25vd24xGAEg",
- "ASgMGkMKCFVua25vd243EhEKCXVua25vd243MRgBIAEoDBIRCgl1bmtub3du",
- "NzIYAiABKAMSEQoJdW5rbm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SEAoIQmFzZUVnZ3MYBSABKAViBnByb3RvMw=="));
descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData,
new pbr::FileDescriptor[] { },
new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] {
- new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse), global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Parser, new[]{ "Unknown1", "Unknown2", "ApiUrl", "Unknown6", "Unknown7", "Payload", "ErrorMessage" }, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Unknown6), global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Unknown6.Parser, new[]{ "Unknown1", "Unknown2" }, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Unknown6.Types.Unknown2), global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Unknown6.Types.Unknown2.Parser, new[]{ "Unknown1" }, null, null, null)}),
- new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Unknown7), global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Unknown7.Parser, new[]{ "Unknown71", "Unknown72", "Unknown73" }, null, null, null),
+ new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse), global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Parser, new[]{ "Unknown1", "Unknown2", "ApiUrl", "Unknown6", "Auth", "Payload", "ErrorMessage" }, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Unknown6), global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Unknown6.Parser, new[]{ "Unknown1", "Unknown2" }, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Unknown6.Types.Unknown2), global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Unknown6.Types.Unknown2.Parser, new[]{ "Unknown1" }, null, null, null)}),
+ new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Auth), global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Auth.Parser, new[]{ "Unknown71", "Timestamp", "Unknown73" }, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Payload), global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Payload.Parser, new[]{ "Guid", "Settings" }, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Payload.Types.GlobalSettingsProto), global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Payload.Types.GlobalSettingsProto.Parser, new[]{ "FortSettings", "MapSettings", "LevelSettings", "InventorySettings", "MinimumClientVersion" }, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Payload.Types.FortSettingsProto), global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Payload.Types.FortSettingsProto.Parser, new[]{ "InteractionRangeMeters", "MaxTotalDeployedPokemon", "MaxPlayerDeployedPokemon", "DeployStaminaMultiplier", "DeployAttackMultiplier", "FarInteractionRangeMeters" }, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Payload.Types.MapSettingsProto), global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Payload.Types.MapSettingsProto.Parser, new[]{ "PokemonVisibleRange", "PokeNavRangeMeters", "EncounterRangeMeters", "GetMapObjectsMinRefreshSeconds", "GetMapObjectsMaxRefreshSeconds", "GetMapObjectsMinDistanceMeters", "GoogleMapsApiKey" }, null, null, null),
@@ -106,7 +105,7 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
unknown2_ = other.unknown2_;
apiUrl_ = other.apiUrl_;
Unknown6 = other.unknown6_ != null ? other.Unknown6.Clone() : null;
- Unknown7 = other.unknown7_ != null ? other.Unknown7.Clone() : null;
+ Auth = other.auth_ != null ? other.Auth.Clone() : null;
payload_ = other.payload_.Clone();
errorMessage_ = other.errorMessage_;
}
@@ -155,13 +154,13 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
}
}
- /// <summary>Field number for the "unknown7" field.</summary>
- public const int Unknown7FieldNumber = 7;
- private global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Unknown7 unknown7_;
- public global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Unknown7 Unknown7 {
- get { return unknown7_; }
+ /// <summary>Field number for the "auth" field.</summary>
+ public const int AuthFieldNumber = 7;
+ private global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Auth auth_;
+ public global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Auth Auth {
+ get { return auth_; }
set {
- unknown7_ = value;
+ auth_ = value;
}
}
@@ -202,7 +201,7 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
if (Unknown2 != other.Unknown2) return false;
if (ApiUrl != other.ApiUrl) return false;
if (!object.Equals(Unknown6, other.Unknown6)) return false;
- if (!object.Equals(Unknown7, other.Unknown7)) return false;
+ if (!object.Equals(Auth, other.Auth)) return false;
if(!payload_.Equals(other.payload_)) return false;
if (ErrorMessage != other.ErrorMessage) return false;
return true;
@@ -214,7 +213,7 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
if (Unknown2 != 0L) hash ^= Unknown2.GetHashCode();
if (ApiUrl.Length != 0) hash ^= ApiUrl.GetHashCode();
if (unknown6_ != null) hash ^= Unknown6.GetHashCode();
- if (unknown7_ != null) hash ^= Unknown7.GetHashCode();
+ if (auth_ != null) hash ^= Auth.GetHashCode();
hash ^= payload_.GetHashCode();
if (ErrorMessage.Length != 0) hash ^= ErrorMessage.GetHashCode();
return hash;
@@ -241,9 +240,9 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
output.WriteRawTag(50);
output.WriteMessage(Unknown6);
}
- if (unknown7_ != null) {
+ if (auth_ != null) {
output.WriteRawTag(58);
- output.WriteMessage(Unknown7);
+ output.WriteMessage(Auth);
}
payload_.WriteTo(output, _repeated_payload_codec);
if (ErrorMessage.Length != 0) {
@@ -266,8 +265,8 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
if (unknown6_ != null) {
size += 1 + pb::CodedOutputStream.ComputeMessageSize(Unknown6);
}
- if (unknown7_ != null) {
- size += 1 + pb::CodedOutputStream.ComputeMessageSize(Unknown7);
+ if (auth_ != null) {
+ size += 1 + pb::CodedOutputStream.ComputeMessageSize(Auth);
}
size += payload_.CalculateSize(_repeated_payload_codec);
if (ErrorMessage.Length != 0) {
@@ -295,11 +294,11 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
}
Unknown6.MergeFrom(other.Unknown6);
}
- if (other.unknown7_ != null) {
- if (unknown7_ == null) {
- unknown7_ = new global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Unknown7();
+ if (other.auth_ != null) {
+ if (auth_ == null) {
+ auth_ = new global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Auth();
}
- Unknown7.MergeFrom(other.Unknown7);
+ Auth.MergeFrom(other.Auth);
}
payload_.Add(other.payload_);
if (other.ErrorMessage.Length != 0) {
@@ -334,10 +333,10 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
break;
}
case 58: {
- if (unknown7_ == null) {
- unknown7_ = new global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Unknown7();
+ if (auth_ == null) {
+ auth_ = new global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Types.Auth();
}
- input.ReadMessage(unknown7_);
+ input.ReadMessage(auth_);
break;
}
case 802: {
@@ -603,9 +602,9 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
- public sealed partial class Unknown7 : pb::IMessage<Unknown7> {
- private static readonly pb::MessageParser<Unknown7> _parser = new pb::MessageParser<Unknown7>(() => new Unknown7());
- public static pb::MessageParser<Unknown7> Parser { get { return _parser; } }
+ public sealed partial class Auth : pb::IMessage<Auth> {
+ private static readonly pb::MessageParser<Auth> _parser = new pb::MessageParser<Auth>(() => new Auth());
+ public static pb::MessageParser<Auth> Parser { get { return _parser; } }
public static pbr::MessageDescriptor Descriptor {
get { return global::PokemonGo.RocketAPI.GeneratedCode.SettingsResponse.Descriptor.NestedTypes[1]; }
@@ -615,20 +614,20 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
get { return Descriptor; }
}
- public Unknown7() {
+ public Auth() {
OnConstruction();
}
partial void OnConstruction();
- public Unknown7(Unknown7 other) : this() {
+ public Auth(Auth other) : this() {
unknown71_ = other.unknown71_;
- unknown72_ = other.unknown72_;
+ timestamp_ = other.timestamp_;
unknown73_ = other.unknown73_;
}
- public Unknown7 Clone() {
- return new Unknown7(this);
+ public Auth Clone() {
+ return new Auth(this);
}
/// <summary>Field number for the "unknown71" field.</summary>
@@ -641,13 +640,13 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
}
}
- /// <summary>Field number for the "unknown72" field.</summary>
- public const int Unknown72FieldNumber = 2;
- private long unknown72_;
- public long Unknown72 {
- get { return unknown72_; }
+ /// <summary>Field number for the "timestamp" field.</summary>
+ public const int TimestampFieldNumber = 2;
+ private long timestamp_;
+ public long Timestamp {
+ get { return timestamp_; }
set {
- unknown72_ = value;
+ timestamp_ = value;
}
}
@@ -662,10 +661,10 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
}
public override bool Equals(object other) {
- return Equals(other as Unknown7);
+ return Equals(other as Auth);
}
- public bool Equals(Unknown7 other) {
+ public bool Equals(Auth other) {
if (ReferenceEquals(other, null)) {
return false;
}
@@ -673,7 +672,7 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
return true;
}
if (Unknown71 != other.Unknown71) return false;
- if (Unknown72 != other.Unknown72) return false;
+ if (Timestamp != other.Timestamp) return false;
if (Unknown73 != other.Unknown73) return false;
return true;
}
@@ -681,7 +680,7 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
public override int GetHashCode() {
int hash = 1;
if (Unknown71.Length != 0) hash ^= Unknown71.GetHashCode();
- if (Unknown72 != 0L) hash ^= Unknown72.GetHashCode();
+ if (Timestamp != 0L) hash ^= Timestamp.GetHashCode();
if (Unknown73.Length != 0) hash ^= Unknown73.GetHashCode();
return hash;
}
@@ -695,9 +694,9 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
output.WriteRawTag(10);
output.WriteBytes(Unknown71);
}
- if (Unknown72 != 0L) {
+ if (Timestamp != 0L) {
output.WriteRawTag(16);
- output.WriteInt64(Unknown72);
+ output.WriteInt64(Timestamp);
}
if (Unknown73.Length != 0) {
output.WriteRawTag(26);
@@ -710,8 +709,8 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
if (Unknown71.Length != 0) {
size += 1 + pb::CodedOutputStream.ComputeBytesSize(Unknown71);
}
- if (Unknown72 != 0L) {
- size += 1 + pb::CodedOutputStream.ComputeInt64Size(Unknown72);
+ if (Timestamp != 0L) {
+ size += 1 + pb::CodedOutputStream.ComputeInt64Size(Timestamp);
}
if (Unknown73.Length != 0) {
size += 1 + pb::CodedOutputStream.ComputeBytesSize(Unknown73);
@@ -719,15 +718,15 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
return size;
}
- public void MergeFrom(Unknown7 other) {
+ public void MergeFrom(Auth other) {
if (other == null) {
return;
}
if (other.Unknown71.Length != 0) {
Unknown71 = other.Unknown71;
}
- if (other.Unknown72 != 0L) {
- Unknown72 = other.Unknown72;
+ if (other.Timestamp != 0L) {
+ Timestamp = other.Timestamp;
}
if (other.Unknown73.Length != 0) {
Unknown73 = other.Unknown73;
@@ -746,7 +745,7 @@ namespace PokemonGo.RocketAPI.GeneratedCode {
break;
}
case 16: {
- Unknown72 = input.ReadInt64();
+ Timestamp = input.ReadInt64();
break;
}
case 26: {
diff --git a/PokemonGo/RocketAPI/Helpers/JsonHelper.cs b/PokemonGo/RocketAPI/Helpers/JsonHelper.cs
new file mode 100644
index 0000000..8255e6b
--- /dev/null
+++ b/PokemonGo/RocketAPI/Helpers/JsonHelper.cs
@@ -0,0 +1,18 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using Newtonsoft.Json.Linq;
+
+namespace PokemonGo.RocketAPI.Helpers
+{
+ public class JsonHelper
+ {
+ public static string GetValue(string json, string key)
+ {
+ var jObject = JObject.Parse(json);
+ return jObject[key].ToString();
+ }
+ }
+}
diff --git a/PokemonGo/RocketAPI/Helpers/ProtoHelper.cs b/PokemonGo/RocketAPI/Helpers/ProtoHelper.cs
new file mode 100644
index 0000000..dca4505
--- /dev/null
+++ b/PokemonGo/RocketAPI/Helpers/ProtoHelper.cs
@@ -0,0 +1,24 @@
+using System;
+using System.Collections.Generic;
+using System.IO;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using Google.Protobuf;
+
+namespace PokemonGo.RocketAPI.Helpers
+{
+ public class ProtoHelper
+ {
+ public static byte[] EncodeUlongList(List<ulong> integers)
+ {
+ var output = new List<byte>();
+ foreach (var integer in integers.OrderBy(c => c))
+ {
+ output.AddRange(VarintBitConverter.GetVarintBytes(integer));
+ }
+
+ return output.ToArray();
+ }
+ }
+}
diff --git a/PokemonGo/RocketAPI/Helpers/RequestBuilder.cs b/PokemonGo/RocketAPI/Helpers/RequestBuilder.cs
index e9ed0c9..8efbe56 100644
--- a/PokemonGo/RocketAPI/Helpers/RequestBuilder.cs
+++ b/PokemonGo/RocketAPI/Helpers/RequestBuilder.cs
@@ -1,41 +1,74 @@
using System;
using System.Collections.Generic;
+using System.IO;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Google.Protobuf;
using PokemonGo.RocketAPI.Enums;
+using PokemonGo.RocketAPI.Extensions;
using PokemonGo.RocketAPI.GeneratedCode;
using PokemonGo.RocketAPI.Helpers;
namespace PokemonGo.RocketAPI.Helpers
{
- public class RequestBuilder
+ public static class RequestBuilder
{
- public static Request GetRequest(RequestType requestType, string authToken, double lat, double lng, double altitude)
+ public static Request GetInitialRequest(string authToken, AuthType authType, double lat, double lng, double altitude, params Request.Types.Requests[] customRequests)
{
return new Request()
{
- Altitude = altitude,
+ Altitude = Utils.FloatAsUlong(altitude),
Auth = new Request.Types.AuthInfo()
{
- Provider = "google",
+ Provider = authType == AuthType.Google ? "google" : "ptc",
Token = new Request.Types.AuthInfo.Types.JWT()
{
Contents = authToken,
- Unknown13 = 59
+ Unknown13 = 14
}
},
- Latitude = lat,
- Longitude = lng,
- RpcId = 6032429073588813826,// RandomHelper.GetLongRandom(1000000000000000000, long.MaxValue),
+ Latitude = Utils.FloatAsUlong(lat),
+ Longitude = Utils.FloatAsUlong(lng),
+ RpcId = 1469378659230941192,
Unknown1 = 2,
- Unknown12 = 138, //Required otherwise we receive incompatible protocol
+ Unknown12 = 989, //Required otherwise we receive incompatible protocol
Requests =
{
- new Request.Types.Requests() { Type = (int)requestType },
+ customRequests
}
};
}
+
+ public static Request GetInitialRequest(string authToken, AuthType authType, double lat, double lng,
+ double altitude, params RequestType[] customRequestTypes)
+ {
+ var customRequests = customRequestTypes.ToList().Select(c => new Request.Types.Requests() {Type = (int) c});
+ return GetInitialRequest(authToken, authType, lat, lng, altitude, customRequests.ToArray());
+ }
+
+ public static Request GetRequest(Request.Types.UnknownAuth unknownAuth, double lat, double lng, double altitude, params Request.Types.Requests[] customRequests)
+ {
+ return new Request()
+ {
+ Altitude = Utils.FloatAsUlong(altitude),
+ Unknownauth = unknownAuth,
+ Latitude = Utils.FloatAsUlong(lat),
+ Longitude = Utils.FloatAsUlong(lng),
+ RpcId = 1469378659230941192,
+ Unknown1 = 2,
+ Unknown12 = 989, //Required otherwise we receive incompatible protocol
+ Requests =
+ {
+ customRequests
+ }
+ };
+ }
+
+ public static Request GetRequest(Request.Types.UnknownAuth unknownAuth, double lat, double lng, double altitude, params RequestType[] customRequestTypes)
+ {
+ var customRequests = customRequestTypes.ToList().Select(c => new Request.Types.Requests() { Type = (int)c });
+ return GetRequest(unknownAuth, lat, lng, altitude, customRequests.ToArray());
+ }
}
}
diff --git a/PokemonGo/RocketAPI/Helpers/RetryHandler.cs b/PokemonGo/RocketAPI/Helpers/RetryHandler.cs
new file mode 100644
index 0000000..4382dec
--- /dev/null
+++ b/PokemonGo/RocketAPI/Helpers/RetryHandler.cs
@@ -0,0 +1,42 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Net.Http;
+using System.Text;
+using System.Threading;
+using System.Threading.Tasks;
+
+namespace PokemonGo.RocketAPI.Helpers
+{
+ class RetryHandler : DelegatingHandler
+ {
+ private const int MaxRetries = 10;
+
+ public RetryHandler(HttpMessageHandler innerHandler)
+ : base(innerHandler)
+ { }
+
+ protected override async Task<HttpResponseMessage> SendAsync(
+ HttpRequestMessage request,
+ CancellationToken cancellationToken)
+ {
+ for (int i = 0; i <= MaxRetries; i++)
+ {
+ try
+ {
+ return await base.SendAsync(request, cancellationToken);
+ }
+ catch (Exception ex)
+ {
+ if (i < MaxRetries)
+ {
+ await Task.Delay(2000);
+ continue;
+ }
+ throw;
+ }
+ }
+ return null;
+ }
+ }
+}
diff --git a/PokemonGo/RocketAPI/Helpers/S2Helper.cs b/PokemonGo/RocketAPI/Helpers/S2Helper.cs
new file mode 100644
index 0000000..8143f43
--- /dev/null
+++ b/PokemonGo/RocketAPI/Helpers/S2Helper.cs
@@ -0,0 +1,46 @@
+using System.Collections.Generic;
+using System.Linq;
+using Google.Common.Geometry;
+
+namespace PokemonGo.RocketAPI.Helpers
+{
+ public class S2Helper
+ {
+ public static List<ulong> GetNearbyCellIds(double longitude, double latitude)
+ {
+ var nearbyCellIds = new List<S2CellId>();
+
+ var cellId = S2CellId.FromLatLng(S2LatLng.FromDegrees(latitude, longitude)).ParentForLevel(15);//.Parent.Parent.Parent.Parent.Parent.Parent.Parent.Parent.Parent.Parent.Parent.Parent.Parent.Parent.Parent;
+
+ nearbyCellIds.Add(cellId);
+ for (int i = 0; i < 10; i++)
+ {
+ nearbyCellIds.Add(GetPrevious(cellId, i));
+ nearbyCellIds.Add(GetNext(cellId, i));
+ }
+
+ return nearbyCellIds.Select(c => c.Id).OrderBy(c => c).ToList();
+ }
+
+ private static S2CellId GetPrevious(S2CellId cellId, int depth)
+ {
+ if (depth < 0)
+ return cellId;
+
+ depth--;
+
+ return GetPrevious(cellId.Previous, depth);
+ }
+
+ private static S2CellId GetNext(S2CellId cellId, int depth)
+ {
+ if (depth < 0)
+ return cellId;
+
+ depth--;
+
+ return GetNext(cellId.Next, depth);
+ }
+
+ }
+}
\ No newline at end of file
diff --git a/PokemonGo/RocketAPI/Helpers/Utils.cs b/PokemonGo/RocketAPI/Helpers/Utils.cs
new file mode 100644
index 0000000..7ad1ca2
--- /dev/null
+++ b/PokemonGo/RocketAPI/Helpers/Utils.cs
@@ -0,0 +1,18 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace PokemonGo.RocketAPI.Helpers
+{
+ public class Utils
+ {
+ public static ulong FloatAsUlong(double value)
+ {
+ var bytes = BitConverter.GetBytes((double)(float)value);
+ return BitConverter.ToUInt64(bytes, 0);
+ }
+
+ }
+}
diff --git a/PokemonGo/RocketAPI/PokemonGo.RocketAPI.csproj b/PokemonGo/RocketAPI/PokemonGo.RocketAPI.csproj
index e389d13..5d3f6eb 100644
--- a/PokemonGo/RocketAPI/PokemonGo.RocketAPI.csproj
+++ b/PokemonGo/RocketAPI/PokemonGo.RocketAPI.csproj
@@ -30,6 +30,10 @@
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
+ <Reference Include="C5, Version=2.2.5073.27396, Culture=neutral, PublicKeyToken=282361b99ded7e8e, processorArchitecture=MSIL">
+ <HintPath>..\..\packages\C5.2.2.5073.27396\lib\portable-net40+sl50+wp80+win\C5.dll</HintPath>
+ <Private>True</Private>
+ </Reference>
<Reference Include="Google.Protobuf, Version=3.0.0.0, Culture=neutral, PublicKeyToken=a7d26565bac4d604, processorArchitecture=MSIL">
<HintPath>packages\Google.Protobuf.3.0.0-beta3\lib\dotnet\Google.Protobuf.dll</HintPath>
<Private>True</Private>
@@ -46,6 +50,10 @@
<HintPath>..\..\packages\Newtonsoft.Json.7.0.1\lib\net45\Newtonsoft.Json.dll</HintPath>
<Private>True</Private>
</Reference>
+ <Reference Include="S2Geometry, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL">
+ <HintPath>..\..\packages\S2Geometry.1.0.1\lib\portable-net45+wp8+win8\S2Geometry.dll</HintPath>
+ <Private>True</Private>
+ </Reference>
<Reference Include="System" />
<Reference Include="System.Configuration" />
<Reference Include="System.Core" />
@@ -53,6 +61,10 @@
<HintPath>..\..\packages\Microsoft.AspNet.WebApi.Client.5.2.3\lib\net45\System.Net.Http.Formatting.dll</HintPath>
<Private>True</Private>
</Reference>
+ <Reference Include="System.VarintBitConverter, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL">
+ <HintPath>..\..\packages\VarintBitConverter.1.0.0.0\lib\Net40\System.VarintBitConverter.dll</HintPath>
+ <Private>True</Private>
+ </Reference>
<Reference Include="System.Web" />
<Reference Include="System.Windows.Forms" />
<Reference Include="System.Xml.Linq" />
@@ -63,10 +75,18 @@
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
+ <Compile Include="Enums\AuthType.cs" />
<Compile Include="Enums\RequestType.cs" />
+ <Compile Include="Extensions\DateTimeExtensions.cs" />
+ <Compile Include="GeneratedCode\EncounterRequest.cs" />
<Compile Include="GeneratedCode\EncounterResponse.cs" />
<Compile Include="GeneratedCode\Request.cs" />
<Compile Include="GeneratedCode\SettingsResponse.cs" />
+ <Compile Include="Helpers\JsonHelper.cs" />
+ <Compile Include="Helpers\ProtoHelper.cs" />
+ <Compile Include="Helpers\RetryHandler.cs" />
+ <Compile Include="Helpers\S2Helper.cs" />
+ <Compile Include="Helpers\Utils.cs" />
<Compile Include="Settings.cs" />
<None Include="app.config" />
<Compile Include="Client.cs" />
@@ -80,15 +100,14 @@
<ItemGroup>
<None Include="packages.config" />
<None Include="Proto\EncounterResponse.proto" />
+ <None Include="Proto\EncounterRequest.proto" />
<None Include="Proto\SettingsResponse.proto" />
<None Include="Proto\Request.proto" />
</ItemGroup>
<ItemGroup>
<None Include="Proto\ProfileResponse.proto" />
</ItemGroup>
- <ItemGroup>
- <Folder Include="Models\" />
- </ItemGroup>
+ <ItemGroup />
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
diff --git a/PokemonGo/RocketAPI/Proto/EncounterRequest.proto b/PokemonGo/RocketAPI/Proto/EncounterRequest.proto
new file mode 100644
index 0000000..6dd1358
--- /dev/null
+++ b/PokemonGo/RocketAPI/Proto/EncounterRequest.proto
@@ -0,0 +1,72 @@
+ syntax = "proto3";
+
+package PokemonGo.RocketAPI.GeneratedCode;
+
+message EncounterRequest {
+ int32 unknown1 = 1;
+ int64 rpc_id = 3;
+ repeated Requests requests = 4;
+ Unknown6 unknown6 = 6;
+ fixed64 latitude = 7;
+ fixed64 longitude = 8;
+ fixed64 altitude = 9;
+ //AuthInfo auth = 10;
+ Auth auth = 11;
+
+ int64 unknown12 = 12;
+
+ message Requests {
+ int32 type = 1;
+ bytes message = 2;
+ }
+
+ message RequestsMessage
+ {
+ bytes cellIds = 1;
+ bytes unknown14 = 2;
+ fixed64 latitude = 3;
+ fixed64 longitude = 4;
+ }
+
+ message SettingsGuid
+ {
+ bytes guid = 1;
+ }
+
+ message Time
+ {
+ int64 time = 1;
+ }
+
+ message Unknown3 {
+ string unknown4 = 1;
+ }
+
+ message Unknown6 {
+ int32 unknown1 = 1;
+ Unknown2 unknown2 = 2;
+
+ message Unknown2 {
+ bytes unknown1 = 1;
+ }
+
+ }
+
+
+ message Auth {
+ bytes unknown71 = 1;
+ int64 timestamp = 2;
+ bytes unknown73 = 3;
+ }
+
+ /* message AuthInfo {
+ string provider = 1;
+ JWT token = 2;
+
+ message JWT {
+ string contents = 1;
+ int32 unknown13 = 2;
+ }
+ }
+ */
+}
\ No newline at end of file
diff --git a/PokemonGo/RocketAPI/Proto/ProfileResponse.proto b/PokemonGo/RocketAPI/Proto/ProfileResponse.proto
index 55120a4..dadac8c 100644
--- a/PokemonGo/RocketAPI/Proto/ProfileResponse.proto
+++ b/PokemonGo/RocketAPI/Proto/ProfileResponse.proto
@@ -7,7 +7,7 @@ message ProfileResponse {
int64 unknown2 = 2;
string api_url = 3;
Unknown6 unknown6 = 6;
- Unknown7 unknown7 = 7;
+ Auth auth = 7;
repeated Payload payload = 100;
string errorMessage = 101; //Should be moved to an error-proto file if error is always 101 field
@@ -21,9 +21,9 @@ message ProfileResponse {
}
- message Unknown7 {
+ message Auth {
bytes unknown71 = 1;
- int64 unknown72 = 2;
+ int64 timestamp = 2;
bytes unknown73 = 3;
}
diff --git a/PokemonGo/RocketAPI/Proto/Request.proto b/PokemonGo/RocketAPI/Proto/Request.proto
index 70459e3..3ac2283 100644
--- a/PokemonGo/RocketAPI/Proto/Request.proto
+++ b/PokemonGo/RocketAPI/Proto/Request.proto
@@ -7,15 +7,23 @@ message Request {
int64 rpc_id = 3;
repeated Requests requests = 4;
Unknown6 unknown6 = 6;
- double latitude = 7;
- double longitude = 8;
- double altitude = 9;
+ fixed64 latitude = 7;
+ fixed64 longitude = 8;
+ fixed64 altitude = 9;
AuthInfo auth = 10;
+ UnknownAuth unknownauth = 11;
int64 unknown12 = 12;
+
+ message UnknownAuth {
+ bytes unknown71 = 1;
+ int64 timestamp = 2;
+ bytes unknown73 = 3;
+ }
+
message Requests {
int32 type = 1;
- Unknown3 message = 2;
+ bytes message = 2;
}
message Unknown3 {
diff --git a/PokemonGo/RocketAPI/Proto/SettingsResponse.proto b/PokemonGo/RocketAPI/Proto/SettingsResponse.proto
index da188ec..d63c889 100644
--- a/PokemonGo/RocketAPI/Proto/SettingsResponse.proto
+++ b/PokemonGo/RocketAPI/Proto/SettingsResponse.proto
@@ -7,7 +7,7 @@ message SettingsResponse {
int64 unknown2 = 2;
string api_url = 3;
Unknown6 unknown6 = 6;
- Unknown7 unknown7 = 7;
+ Auth auth = 7;
repeated Payload payload = 100;
string errorMessage = 101; //Should be moved to an error-proto file if error is always 101 field
@@ -21,9 +21,9 @@ message SettingsResponse {
}
- message Unknown7 {
+ message Auth {
bytes unknown71 = 1;
- int64 unknown72 = 2;
+ int64 timestamp = 2;
bytes unknown73 = 3;
}
diff --git a/PokemonGo/RocketAPI/Resources.cs b/PokemonGo/RocketAPI/Resources.cs
index 878f284..781f385 100644
--- a/PokemonGo/RocketAPI/Resources.cs
+++ b/PokemonGo/RocketAPI/Resources.cs
@@ -8,11 +8,10 @@ namespace PokemonGo.RocketAPI
{
public class Resources
{
- public const string RPC_URL = @"https://pgorelease.nianticlabs.com/plfe/rpc";
- public const string NUMBERED_RPC_URL = @"https://pgorelease.nianticlabs.com/plfe/{0}/rpc";
- public const string LOGIN_URL = "https://sso.pokemon.com/sso/login?service=https%3A%2F%2Fsso.pokemon.com%2Fsso%2Foauth2.0%2FcallbackAuthorize";
- public const string LOGIN_OAUTH = "https://sso.pokemon.com/sso/oauth2.0/accessToken";
-
- public const string GOOGLE_GRANT_REFRESH_ACCESS_URL = "https://android.clients.google.com/auth";
+ public const string RpcUrl = @"https://pgorelease.nianticlabs.com/plfe/rpc";
+ public const string NumberedRpcUrl = @"https://pgorelease.nianticlabs.com/plfe/{0}/rpc";
+ public const string PtcLoginUrl = "https://sso.pokemon.com/sso/login?service=https%3A%2F%2Fsso.pokemon.com%2Fsso%2Foauth2.0%2FcallbackAuthorize";
+ public const string PtcLoginOauth = "https://sso.pokemon.com/sso/oauth2.0/accessToken";
+ public const string GoogleGrantRefreshAccessUrl = "https://android.clients.google.com/auth";
}
}
diff --git a/PokemonGo/RocketAPI/Settings.cs b/PokemonGo/RocketAPI/Settings.cs
index bf223b4..20e1d4c 100644
--- a/PokemonGo/RocketAPI/Settings.cs
+++ b/PokemonGo/RocketAPI/Settings.cs
@@ -8,7 +8,7 @@ namespace PokemonGo.RocketAPI
{
public static class Settings
{
- //Fetch these settings from intercepting the /auth call in headers and body
+ //Fetch these settings from intercepting the /auth call in headers and body (only needed for google auth)
public const string DeviceId = "cool-device-id";
public const string Email = "fake@gmail.com";
public const string ClientSig = "fake";
diff --git a/PokemonGo/RocketAPI/packages.config b/PokemonGo/RocketAPI/packages.config
index cb2f4d3..08cd317 100644
--- a/PokemonGo/RocketAPI/packages.config
+++ b/PokemonGo/RocketAPI/packages.config
@@ -1,9 +1,12 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
+ <package id="C5" version="2.2.5073.27396" targetFramework="net45" />
<package id="EnterpriseLibrary.TransientFaultHandling" version="6.0.1304.0" targetFramework="net45" />
<package id="EnterpriseLibrary.TransientFaultHandling.Data" version="6.0.1304.1" targetFramework="net45" />
<package id="Google.Protobuf" version="3.0.0-beta3" targetFramework="net45" />
<package id="Google.Protobuf.Tools" version="3.0.0-beta3" targetFramework="net45" />
<package id="Microsoft.AspNet.WebApi.Client" version="5.2.3" targetFramework="net45" />
<package id="Newtonsoft.Json" version="7.0.1" targetFramework="net45" />
+ <package id="S2Geometry" version="1.0.1" targetFramework="net45" />
+ <package id="VarintBitConverter" version="1.0.0.0" targetFramework="net45" />
</packages>
\ No newline at end of file
diff --git a/README.md b/README.md
index cb48285..e46df2e 100644
--- a/README.md
+++ b/README.md
@@ -2,15 +2,14 @@
Working:
--Login by registered device
-
--Retrieve Profile:
-
-```{{ "unknown1": 1, "profile": { "creationTime": "1467979220181", "username": "SEKRET", "team": 1, "tutorial": "AAEDBAc=", "avatar": { "unknown3": 1, "unknown9": 4 }, "pokeStorage": 250, "itemStorage": 350, "dailyBonus": { }, "currency": [ { "type": "POKECOIN" }, { "type": "STARDUST", "amount": 5300 } ] } }}```
-
--Retrieve Server Settings
-
-```{{ "fortSettings": { "interactionRangeMeters": 40, "maxTotalDeployedPokemon": 10, "maxPlayerDeployedPokemon": 1, "deployStaminaMultiplier": 2, "farInteractionRangeMeters": 1000 }, "mapSettings": { "pokemonVisibleRange": 100, "pokeNavRangeMeters": 201, "encounterRangeMeters": 50, "getMapObjectsMinRefreshSeconds": 5, "getMapObjectsMaxRefreshSeconds": 30, "getMapObjectsMinDistanceMeters": 10, "googleMapsApiKey": "AIzaSyDF9rksdsdsgVFzjnNo13WtmJIM" }, "inventorySettings": { "maxPokemon": 1000, "maxBagItems": 1000, "basePokemon": 250, "baseBagItems": 350, "baseEggs": 9 }, "minimumClientVersion": "0.29.0" }}```
+```
+await client.LoginPtc("FeroxRev", "Sekret");
+//await client.LoginGoogle(Settings.DeviceId, Settings.Email, Settings.LongDurationToken);
+var serverResponse = await client.GetServer();
+var profile = await client.GetProfile();
+var settings = await client.GetSettings();
+var encounters = await client.GetEncounters();
+```
Todo:
You may download the files in Public Git.