From 1df628b7efa209b8fa4fce4a6ab330018a71293e Mon Sep 17 00:00:00 2001 From: FeroxRev Date: Mon, 25 Jul 2016 16:50:21 +0200 Subject: [PATCH] Add newly awarded badges --- PokemonGo.RocketAPI/Rpc/Player.cs | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/PokemonGo.RocketAPI/Rpc/Player.cs b/PokemonGo.RocketAPI/Rpc/Player.cs index bbfde90..cf67252 100644 --- a/PokemonGo.RocketAPI/Rpc/Player.cs +++ b/PokemonGo.RocketAPI/Rpc/Player.cs @@ -35,7 +35,7 @@ public async Task UpdatePlayerLocation(double latitude, do RequestMessage = message.ToByteString() }); - return await _client.PokemonHttpClient.PostProtoPayload(ApiUrl, updatePlayerLocationRequestEnvelope); + return await PostProtoPayload(updatePlayerLocationRequestEnvelope); } internal void SetCoordinates(double lat, double lng, double altitude) @@ -47,8 +47,12 @@ internal void SetCoordinates(double lat, double lng, double altitude) public async Task GetOwnProfile() { - var request = RequestBuilder.GetRequestEnvelope(RequestType.GetPlayer, new GetPlayerMessage()); - return await _client.PokemonHttpClient.PostProtoPayload(ApiUrl, request); + return await PostProtoPayload(RequestType.GetPlayer, new GetPlayerMessage()); + } + + public async Task GetNewlyAwardedBadges() + { + return await PostProtoPayload(RequestType.CheckAwardedBadges, new CheckAwardedBadgesMessage()); } } }