aboutsummaryrefslogtreecommitdiff
path: root/ShiftOS_TheReturn/UniteClient.cs
diff options
context:
space:
mode:
authorAShifter <[email protected]>2017-05-04 19:01:03 -0600
committerAShifter <[email protected]>2017-05-04 19:01:03 -0600
commit13b35b32c2c429e6bd2d7b41ca43cc62f305dbc5 (patch)
treedbc42661444f813cf04f7af2fdfecb94d5b78044 /ShiftOS_TheReturn/UniteClient.cs
parent2fede89938014129cf50d66d5ff62af1bde4a477 (diff)
parenta57b5855f5a2b7e5f89e411a5cbe66dd0dcb50d6 (diff)
downloadshiftos_thereturn-13b35b32c2c429e6bd2d7b41ca43cc62f305dbc5.tar.gz
shiftos_thereturn-13b35b32c2c429e6bd2d7b41ca43cc62f305dbc5.tar.bz2
shiftos_thereturn-13b35b32c2c429e6bd2d7b41ca43cc62f305dbc5.zip
Merge remote-tracking branch 'refs/remotes/shiftos-game/master'
Diffstat (limited to 'ShiftOS_TheReturn/UniteClient.cs')
-rw-r--r--ShiftOS_TheReturn/UniteClient.cs24
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; }
+ }
}