Skip to content
This repository has been archived by the owner on Oct 1, 2024. It is now read-only.

Commit

Permalink
3.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
ic3w0lf22 committed May 8, 2022
1 parent 460c7cf commit 73ece19
Show file tree
Hide file tree
Showing 13 changed files with 104 additions and 68 deletions.
20 changes: 9 additions & 11 deletions RBX Alt Manager/AccountManager.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions RBX Alt Manager/AccountManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ public partial class AccountManager : Form
public static Account SelectedAccount;
public static RestClient MainClient;
public static RestClient FriendsClient;
public static RestClient UsersClient;
public static RestClient APIClient;
public static RestClient AuthClient;
public static RestClient EconClient;
Expand Down Expand Up @@ -405,6 +406,9 @@ private void AccountManager_Load(object sender, EventArgs e)
FriendsClient = new RestClient("https://friends.roblox.com");
FriendsClient.CachePolicy = new System.Net.Cache.RequestCachePolicy(System.Net.Cache.RequestCacheLevel.BypassCache);

UsersClient = new RestClient("https://users.roblox.com");
UsersClient.CachePolicy = new System.Net.Cache.RequestCachePolicy(System.Net.Cache.RequestCacheLevel.BypassCache);

ApplyTheme();

PlaceID_TextChanged(PlaceID, new EventArgs());
Expand Down Expand Up @@ -1260,8 +1264,10 @@ private async void LaunchAccounts(List<Account> Accounts, long PlaceId, string J
account.JoinServer(PlaceId, JobID, FollowUser, VIPServer);

if (AsyncJoin)
{
while (!LaunchNext)
await Task.Delay(50);
}
else
await Task.Delay(Delay * 1000);

Expand Down
3 changes: 0 additions & 3 deletions RBX Alt Manager/AccountManager.resx
Original file line number Diff line number Diff line change
Expand Up @@ -143,9 +143,6 @@
o2fIyJ1aHQGZRu/QP23E8w+e/8nYGLZPlQAAAABJRU5ErkJggg==
</value>
</data>
<metadata name="SaveTooltip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>156, 17</value>
</metadata>
<metadata name="SaveTimer.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>375, 16</value>
</metadata>
Expand Down
25 changes: 19 additions & 6 deletions RBX Alt Manager/Classes/Account.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#pragma warning disable CS0618

using Newtonsoft.Json;
using Newtonsoft.Json.Linq;
using RestSharp;
using System;
using System.Collections.Generic;
Expand Down Expand Up @@ -588,8 +589,10 @@ public string JoinServer(long PlaceID, string JobID = "", bool FollowUser = fals

RPath = RPath + @"\RobloxPlayerBeta.exe";

Task.Run(() => // somehow some people are crashing when roblox is tryna launch??? (probably bad executor taking making the process hang)
Task.Run(() => // somehow some people are crashing when roblox is tryna launch??? (probably bad executor making the process hang)
{
AccountManager.Instance.NextAccount();

ProcessStartInfo Roblox = new ProcessStartInfo(RPath);

if (JoinVIP)
Expand All @@ -606,7 +609,7 @@ public string JoinServer(long PlaceID, string JobID = "", bool FollowUser = fals
}
else
{
Task.Run(() => // somehow some people are crashing when roblox is tryna launch??? (probably bad executor taking making the process hang)
Task.Run(() => // somehow some people are crashing when roblox is tryna launch??? (probably bad executor making the process hang)
{
try
{
Expand All @@ -616,7 +619,7 @@ public string JoinServer(long PlaceID, string JobID = "", bool FollowUser = fals
Process.Start(string.Format("roblox-player:1+launchmode:play+gameinfo:{0}+launchtime:{2}+placelauncherurl:https://assetgame.roblox.com/game/PlaceLauncher.ashx?request=RequestFollowUser&userId={1}+browsertrackerid:{3}+robloxLocale:en_us+gameLocale:en_us", Ticket, PlaceID, LaunchTime, BrowserTrackerID)).WaitForExit();
else
Process.Start($"roblox-player:1+launchmode:play+gameinfo:{Ticket}+launchtime:{LaunchTime}+placelauncherurl:https://assetgame.roblox.com/game/PlaceLauncher.ashx?request=RequestGame{ (string.IsNullOrEmpty(JobID) ? "" : "Job") }&browserTrackerId={BrowserTrackerID}&placeId={PlaceID}{(string.IsNullOrEmpty(JobID) ? "" : ("&gameId=" + JobID))}&isPlayTogetherGame=false{(AccountManager.IsTeleport ? "&isTeleport=true" : "")}+browsertrackerid:{BrowserTrackerID}+robloxLocale:en_us+gameLocale:en_us").WaitForExit();

AccountManager.Instance.NextAccount();
}
catch
Expand Down Expand Up @@ -690,10 +693,20 @@ public bool SendFriendRequest(string Username)

IRestResponse friendResponse = AccountManager.FriendsClient.Execute(friendRequest);

if (friendResponse.IsSuccessful && friendResponse.StatusCode == HttpStatusCode.OK)
return true;
return friendResponse.IsSuccessful && friendResponse.StatusCode == HttpStatusCode.OK;
}

return false;
public void SetDisplayName(string DisplayName)
{
RestRequest dpRequest = new RestRequest($"/v1/users/{UserID}/display-names", Method.PATCH);
dpRequest.AddCookie(".ROBLOSECURITY", SecurityToken);
dpRequest.AddHeader("X-CSRF-TOKEN", GetCSRFToken());
dpRequest.AddJsonBody(new { newDisplayName = DisplayName });

IRestResponse dpResponse = AccountManager.UsersClient.Execute(dpRequest);

if (dpResponse.StatusCode != HttpStatusCode.OK)
throw new Exception(JObject.Parse(dpResponse.Content)?["errors"]?[0]?["message"].Value<string>() ?? $"Something went wrong\n{dpResponse.StatusCode}: {dpResponse.Content}");
}

public string GetField(string Name) => Fields.ContainsKey(Name) ? Fields[Name] : "";
Expand Down
6 changes: 3 additions & 3 deletions RBX Alt Manager/Classes/Avatar.cs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ namespace RBX_Alt_Manager
{
public class Avatar
{
public int targetId { get; set; }
public long targetId { get; set; }
public string state { get; set; }
public string imageUrl { get; set; }
}
Expand All @@ -18,7 +18,7 @@ public class TokenRequest
{
public string requestId { get; set; }
public string type { get; set; }
public int targetId { get; set; }
public long targetId { get; set; }
public string token { get; set; }
public string format { get; set; }
public string size { get; set; }
Expand All @@ -39,7 +39,7 @@ public class TokenAvatar
public string requestId { get; set; }
public int errorCode { get; set; }
public string errorMessage { get; set; }
public int targetId { get; set; }
public long targetId { get; set; }
public string state { get; set; }
public string imageUrl { get; set; }
}
Expand Down
6 changes: 4 additions & 2 deletions RBX Alt Manager/Forms/AccountAdder.cs
Original file line number Diff line number Diff line change
Expand Up @@ -112,13 +112,15 @@ private void OnPageLoaded(object sender, FrameLoadEndEventArgs args)
{
Task.Factory.StartNew(async () =>
{
while (chromeBrowser.Address == args.Url && Visible)
await Task.Delay(200);

while (chromeBrowser.Address.Contains("/login") && Visible)
{
JavascriptResponse response = await chromeBrowser.EvaluateScriptAsync("document.getElementById('login-password').value");

Password = (string)response.Result;

await Task.Delay(200);
await Task.Delay(50);
}
});
}
Expand Down
48 changes: 32 additions & 16 deletions RBX Alt Manager/Forms/AccountUtils.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

13 changes: 10 additions & 3 deletions RBX Alt Manager/Forms/AccountUtils.cs
Original file line number Diff line number Diff line change
Expand Up @@ -132,14 +132,21 @@ private void Block_Click(object sender, EventArgs e)

private void SetDisplayName_Click(object sender, EventArgs e)
{
MessageBox.Show("To set your display name, click 'Open App', go to settings, account info, then change your display name there");
if (AccountManager.SelectedAccount == null) return;

try
{
AccountManager.SelectedAccount.SetDisplayName(DisplayName.Text);
MessageBox.Show($"Successfully set {AccountManager.SelectedAccount.Username}'s Display Name to {DisplayName.Text}", "Account Utilities", MessageBoxButtons.OK, MessageBoxIcon.Information);
}
catch (Exception x) { MessageBox.Show(x.Message, "Account Utilities", MessageBoxButtons.OK, MessageBoxIcon.Error); }
}

private void button4_Click(object sender, EventArgs e)
private void AddFriend_Click(object sender, EventArgs e)
{
if (AccountManager.SelectedAccount == null) return;

AccountManager.SelectedAccount.SendFriendRequest(Username.Text);
}
}
}
}
3 changes: 0 additions & 3 deletions RBX Alt Manager/Forms/AccountUtils.resx
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,4 @@
<metadata name="EmailTip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
<metadata name="EmailTip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
</root>
Loading

0 comments on commit 73ece19

Please sign in to comment.