public static File getMinecraftFolder() {
        JsonNode minecraftFolder = INSTANCE.versionData.getNode("install", "minecraftFolder");
        String osType = System.getProperty("os.name").toLowerCase();
        String userHomeDir = System.getProperty("user.home", ".");
        String mcDir = ".minecraft";
        if (osType.contains("win")) {
            if (minecraftFolder.getStringValue("windows").equals("default")) {
                if (System.getenv("APPDATA") != null) {
                    return new File(System.getenv("APPDATA"), mcDir);
                } else {
                    return new File(userHomeDir, mcDir);
                }
            } else {
                return new File(minecraftFolder.getStringValue("windows"));
            }
        } else if (osType.contains("mac")) {
            if (minecraftFolder.getStringValue("mac").equals("default")) {
                return new File(new File(new File(userHomeDir, "Library"), "Application Support"), "minecraft");
            } else {
                return new File(minecraftFolder.getStringValue("mac"));
            }
        } else {
            if (minecraftFolder.getStringValue("linux").equals("default")) {
                return new File(userHomeDir, mcDir);
            } else {
                return new File(minecraftFolder.getStringValue("linux"));
            }
        }
    }