Skip to content

Commit

Permalink
woot
Browse files Browse the repository at this point in the history
  • Loading branch information
dd01da0465b4542f8f8af4ecedc149ed committed May 27, 2020
1 parent 19621f5 commit 6e29d72
Show file tree
Hide file tree
Showing 7 changed files with 20 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -348,3 +348,6 @@ MigrationBackup/

# Ionide (cross platform F# VS Code tools) working folder
.ionide/

# AuroraLauncher builds
[Bb]uild/
2 changes: 2 additions & 0 deletions AuroraLauncher/GUI.cs
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ public Gui()
Configuration = new Configuration();
Configuration.Open();

Api.Heartbeat();

// settings form manages skinmanager
_settings = new Settings(this);

Expand Down
15 changes: 15 additions & 0 deletions AuroraLauncher/Providers/Api.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
using RestSharp;
using System;

namespace AuroraLauncher.Providers
{
Expand All @@ -14,6 +15,8 @@ static class Api

public static string Version => GetVersion();

public static int Online => GetOnline();

#endregion

#region Method Region
Expand All @@ -28,6 +31,18 @@ static string GetVersion()
return version;
}

public static void Heartbeat() => _client.Post(new RestRequest("heartbeat"));

static int GetOnline()
{
string online = _client.Get(new RestRequest("online")).Content;

if (string.IsNullOrEmpty(online))
return 0;

return Convert.ToInt32(online);
}

#endregion
}
}
Binary file removed Build/FortniteLauncher.exe
Binary file not shown.
Binary file removed Build/MaterialSkin.dll
Binary file not shown.
Binary file removed Build/Newtonsoft.Json.dll
Binary file not shown.
Binary file removed Build/RestSharp.dll
Binary file not shown.

0 comments on commit 6e29d72

Please sign in to comment.