diff options
Diffstat (limited to 'ShiftOS_TheReturn/UniteClient.cs')
| -rw-r--r-- | ShiftOS_TheReturn/UniteClient.cs | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/ShiftOS_TheReturn/UniteClient.cs b/ShiftOS_TheReturn/UniteClient.cs index cb08382..1136b5c 100644 --- a/ShiftOS_TheReturn/UniteClient.cs +++ b/ShiftOS_TheReturn/UniteClient.cs @@ -4,6 +4,7 @@ using System.Linq; using System.Net; using System.Text; using System.Threading.Tasks; +using Newtonsoft.Json; namespace ShiftOS.Unite { @@ -12,6 +13,16 @@ namespace ShiftOS.Unite public string Token { get; private set; } public string BaseURL { get; private set; } + public string GetDisplayNameId(string id) + { + return MakeCall("/API/GetDisplayName/" + id); + } + + public PongHighscoreModel GetPongHighscores() + { + return JsonConvert.DeserializeObject<PongHighscoreModel>(MakeCall("/API/GetPongHighscores")); + } + public UniteClient(string baseurl, string usertoken) { BaseURL = baseurl; @@ -100,4 +111,17 @@ namespace ShiftOS.Unite MakeCall("/API/SetCodepoints/" + value.ToString()); } } + + public class PongHighscoreModel + { + public int Pages { get; set; } + public PongHighscore[] Highscores { get; set; } + } + + public class PongHighscore + { + public string UserId { get; set; } + public int Level { get; set; } + public long CodepointsCashout { get; set; } + } } |
