mirror of
https://github.com/AngelAuraMC/Amethyst-Android.git
synced 2025-09-10 05:01:29 -04:00
launcher_profiles.json, Hold slot item of hotbar to drop
This commit is contained in:
parent
8b64eb8abc
commit
0d04a1ab1b
Binary file not shown.
0
app/src/main/assets/launcher_profiles.json
Normal file
0
app/src/main/assets/launcher_profiles.json
Normal file
@ -0,0 +1,34 @@
|
||||
package net.kdt.pojavlaunch.value.launcherprofiles;
|
||||
import com.google.gson.*;
|
||||
import net.kdt.pojavlaunch.*;
|
||||
import java.io.*;
|
||||
|
||||
public class LauncherProfiles
|
||||
{
|
||||
public static MinecraftLauncherProfiles mainProfileJson;
|
||||
public static File launcherProfilesFile = new File(Tools.MAIN_PATH + "/launcher_profiles.json");
|
||||
public static MinecraftLauncherProfiles getJson() {
|
||||
try {
|
||||
if (launcherProfilesFile.exists()) {
|
||||
if (mainProfileJson == null) {
|
||||
mainProfileJson = new Gson().fromJson(Tools.read(launcherProfilesFile.getAbsolutePath()), MinecraftLauncherProfiles.class);
|
||||
}
|
||||
} else {
|
||||
mainProfileJson = new MinecraftLauncherProfiles();
|
||||
}
|
||||
insertMissing();
|
||||
return mainProfileJson;
|
||||
} catch (Throwable th) {
|
||||
throw new RuntimeException(th);
|
||||
}
|
||||
}
|
||||
|
||||
public static String insert
|
||||
|
||||
private static void insertMissing() {
|
||||
if (mainProfileJson.authenticationDatabase == null) {
|
||||
MinecraftAuthenticationDatabase mad = new MinecraftAuthenticationDatabase();
|
||||
mainProfileJson.authenticationDatabase = mad;
|
||||
}
|
||||
}
|
||||
}
|
@ -2,7 +2,7 @@ package net.kdt.pojavlaunch.value.launcherprofiles;
|
||||
|
||||
public class MinecraftAuthenticationDatabase
|
||||
{
|
||||
public static String accessToken;
|
||||
public static String username;
|
||||
public static MinecraftProfile[] profiles;
|
||||
public String accessToken;
|
||||
public String username;
|
||||
public MinecraftProfile[] profiles;
|
||||
}
|
||||
|
@ -2,7 +2,12 @@ package net.kdt.pojavlaunch.value.launcherprofiles;
|
||||
|
||||
public class MinecraftLauncherProfiles
|
||||
{
|
||||
public static MinecraftProfile[] profiles;
|
||||
public static String clientToken;
|
||||
public static MinecraftAuthenticationDatabase authenticationDatabase;
|
||||
public MinecraftProfile[] profiles;
|
||||
public String clientToken;
|
||||
public MinecraftAuthenticationDatabase[] authenticationDatabase;
|
||||
// public Map launcherVersion;
|
||||
public MinecraftLauncherSettings settings;
|
||||
// public Map analyticsToken;
|
||||
public int analyticsFailcount;
|
||||
public MinecraftSelectedUser selectedUser;
|
||||
}
|
||||
|
@ -0,0 +1,15 @@
|
||||
package net.kdt.pojavlaunch.value.launcherprofiles;
|
||||
|
||||
public class MinecraftLauncherSettings
|
||||
{
|
||||
public boolean enableSnapshots;
|
||||
public boolean enableAdvanced;
|
||||
public boolean keepLauncherOpen;
|
||||
public boolean showGameLog;
|
||||
public String locale;
|
||||
public boolean showMenu;
|
||||
public boolean enableHistorical;
|
||||
public String profileSorting;
|
||||
public boolean crashAssistance;
|
||||
public boolean enableAnalytics;
|
||||
}
|
@ -2,16 +2,16 @@ package net.kdt.pojavlaunch.value.launcherprofiles;
|
||||
|
||||
public class MinecraftProfile
|
||||
{
|
||||
public static String name;
|
||||
public static String type;
|
||||
public static String created;
|
||||
public static String lastUsed;
|
||||
public static String icon;
|
||||
public static String lastVersionId;
|
||||
public static String gameDir;
|
||||
public static String javaDir;
|
||||
public static String javaArgs;
|
||||
public static String logConfig;
|
||||
public static boolean logConfigIsXML;
|
||||
public static MinecraftResolution[]resolution;
|
||||
public String name;
|
||||
public String type;
|
||||
public String created;
|
||||
public String lastUsed;
|
||||
public String icon;
|
||||
public String lastVersionId;
|
||||
public String gameDir;
|
||||
public String javaDir;
|
||||
public String javaArgs;
|
||||
public String logConfig;
|
||||
public boolean logConfigIsXML;
|
||||
public MinecraftResolution[] resolution;
|
||||
}
|
||||
|
@ -2,6 +2,6 @@ package net.kdt.pojavlaunch.value.launcherprofiles;
|
||||
|
||||
public class MinecraftResolution
|
||||
{
|
||||
public static int width;
|
||||
public static int height;
|
||||
public int width;
|
||||
public int height;
|
||||
}
|
||||
|
@ -0,0 +1,7 @@
|
||||
package net.kdt.pojavlaunch.value.launcherprofiles;
|
||||
|
||||
public class MinecraftSelectedUser
|
||||
{
|
||||
public String account;
|
||||
public String profile;
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user