diff --git a/src/main/java/pojlib/account/MinecraftAccount.java b/src/main/java/pojlib/account/MinecraftAccount.java index e428d689..14ecd45a 100644 --- a/src/main/java/pojlib/account/MinecraftAccount.java +++ b/src/main/java/pojlib/account/MinecraftAccount.java @@ -2,6 +2,8 @@ import static pojlib.account.Msa.checkMcProfile; +import android.app.Activity; + import com.google.gson.Gson; import org.json.JSONException; @@ -33,8 +35,8 @@ public static MinecraftAccount login(String gameDir, String[] response) throws I return account; } - public static boolean logout(String path) { - File accountFile = new File(path + "/account.json"); + public static boolean logout(Activity activity) { + File accountFile = new File(activity.getFilesDir() + "/accounts/account.json"); return accountFile.delete(); } diff --git a/src/main/java/pojlib/api/API_V1.java b/src/main/java/pojlib/api/API_V1.java index b68cbfb5..1a453c71 100644 --- a/src/main/java/pojlib/api/API_V1.java +++ b/src/main/java/pojlib/api/API_V1.java @@ -54,6 +54,7 @@ public class API_V1 { public static String memoryValue = "1800"; public static boolean developerMods; public static MinecraftAccount currentAcc; + public static boolean advancedDebugger; @@ -126,11 +127,11 @@ public static void launchInstance(Activity activity, MinecraftAccount account, M /** * Logs the user out * - * @param home The base directory where minecraft should be setup + * @param activity The base directory where minecraft should be setup * @return True if logout was successful */ - public static boolean logout(String home) { - return MinecraftAccount.logout(home); + public static boolean logout(Activity activity) { + return MinecraftAccount.logout(activity); } public static void login(Activity activity) @@ -159,6 +160,7 @@ public static void login(Activity activity) API_V1.profileName = API_V1.currentAcc.username; } } + LoginHelper.beginLogin(activity); } } diff --git a/src/main/java/pojlib/util/JREUtils.java b/src/main/java/pojlib/util/JREUtils.java index ac2ae201..ee620464 100644 --- a/src/main/java/pojlib/util/JREUtils.java +++ b/src/main/java/pojlib/util/JREUtils.java @@ -184,7 +184,7 @@ public static int launchJavaVM(final Activity activity, final List JVMAr userArgs.add("-Xms" + API_V1.memoryValue + "M"); userArgs.add("-Xmx" + API_V1.memoryValue + "M"); } else { - if (API_V1.model.equals("Meta Quest Pro")) { + if (API_V1.model.equals("Meta Quest Pro") || API_V1.model.equals("Oculus Headset1")) { userArgs.add("-Xms" + 4096 + "M"); userArgs.add("-Xmx" + 4096 + "M"); } else {