From e4b98391869955f92e5bdf66bd930f2b3f178c62 Mon Sep 17 00:00:00 2001 From: Duy Tran Khanh Date: Thu, 31 Dec 2020 04:49:53 +0700 Subject: [PATCH] restore --- .../java/net/kdt/pojavlaunch/PLaunchApp.java | 25 ++----------------- 1 file changed, 2 insertions(+), 23 deletions(-) diff --git a/src/main/java/net/kdt/pojavlaunch/PLaunchApp.java b/src/main/java/net/kdt/pojavlaunch/PLaunchApp.java index b3036036..e62a0a55 100644 --- a/src/main/java/net/kdt/pojavlaunch/PLaunchApp.java +++ b/src/main/java/net/kdt/pojavlaunch/PLaunchApp.java @@ -22,31 +22,10 @@ public class PLaunchApp extends UIApplicationDelegateAdapter { Thread launchThread = new Thread() { @Override public void run() { - // Application.launch(PLaunchJFXApp.class); - - // Start Minecraft there! - File file = new File(Tools.DIR_GAME_NEW); - file.mkdirs(); - - String mcver = "1.13"; - try { - mcver = Tools.read(Tools.DIR_GAME_HOME + "/config_ver.txt"); - } catch (IOException e) { - System.out.println("config_ver.txt not found, defaulting to Minecraft 1.13"); - } - - MinecraftAccount acc = new MinecraftAccount(); - acc.selectedVersion = mcver; - JMinecraftVersionList.Version version = Tools.getVersionInfo(mcver); - - try { - Tools.launchMinecraft(acc, version); - } catch (Throwable th) { - Tools.showError(th); - } + Application.launch(PLaunchJFXApp.class); } }; - // launchThread.setDaemon(true); + launchThread.setDaemon(true); launchThread.start(); } else { WindowAlertController alertController = new WindowAlertController("Error", "OpenJDK is not installed. Please install before enter launcher.", UIAlertControllerStyle.Alert);