diff --git a/Launcher/src/main/java/ru/gravit/launcher/LauncherEngine.java b/Launcher/src/main/java/ru/gravit/launcher/LauncherEngine.java index 93dc8385..5ddcd707 100644 --- a/Launcher/src/main/java/ru/gravit/launcher/LauncherEngine.java +++ b/Launcher/src/main/java/ru/gravit/launcher/LauncherEngine.java @@ -216,14 +216,10 @@ public void start(String... args) throws Throwable { CommonHelper.newThread("FX Task Worker", true, FunctionalBridge.worker); loadScript(Launcher.API_SCRIPT_FILE); loadScript(Launcher.CONFIG_SCRIPT_FILE); + Thread.sleep(100); loadScript(Launcher.INIT_SCRIPT_FILE); LogHelper.info("Invoking start() function"); Invocable invoker = (Invocable) engine; - if (Launcher.isUsingAvanguard()) { - AvanguardStarter.start(DirBridge.dir); - AvanguardStarter.load(); - AvanguardStarter.main(false); - } Launcher.modulesManager.postInitModules(); invoker.invokeFunction("start", (Object) args); } diff --git a/Launcher/src/main/java/ru/gravit/launcher/DirBridge.java b/Launcher/src/main/java/ru/gravit/launcher/client/DirBridge.java similarity index 93% rename from Launcher/src/main/java/ru/gravit/launcher/DirBridge.java rename to Launcher/src/main/java/ru/gravit/launcher/client/DirBridge.java index 7f2fd10c..e7b4e35c 100644 --- a/Launcher/src/main/java/ru/gravit/launcher/DirBridge.java +++ b/Launcher/src/main/java/ru/gravit/launcher/client/DirBridge.java @@ -1,4 +1,4 @@ -package ru.gravit.launcher; +package ru.gravit.launcher.client; import ru.gravit.launcher.LauncherAPI; import ru.gravit.utils.helper.IOHelper; diff --git a/Launcher/src/main/java/ru/gravit/launcher/FunctionalBridge.java b/Launcher/src/main/java/ru/gravit/launcher/client/FunctionalBridge.java similarity index 95% rename from Launcher/src/main/java/ru/gravit/launcher/FunctionalBridge.java rename to Launcher/src/main/java/ru/gravit/launcher/client/FunctionalBridge.java index 82a08c51..96b0172d 100644 --- a/Launcher/src/main/java/ru/gravit/launcher/FunctionalBridge.java +++ b/Launcher/src/main/java/ru/gravit/launcher/client/FunctionalBridge.java @@ -1,8 +1,9 @@ -package ru.gravit.launcher; +package ru.gravit.launcher.client; import javafx.concurrent.Task; +import ru.gravit.launcher.HWID; import ru.gravit.launcher.LauncherAPI; -import ru.gravit.launcher.client.ClientLauncher; +import ru.gravit.launcher.RequestWorker; import ru.gravit.launcher.hasher.FileNameMatcher; import ru.gravit.launcher.hasher.HashedDir; import ru.gravit.launcher.hwid.OshiHWIDProvider; @@ -49,11 +50,6 @@ public LegacyLauncherRequest.Result offlineLauncherRequest() throws IOException, // Return last sign and profiles return new LegacyLauncherRequest.Result(null, settings.lastDigest, settings.lastProfiles); } - - @FunctionalInterface - public interface HashedDirRunnable { - SignedObjectHolder run() throws Exception; - } @LauncherAPI public void makeJsonRequest(RequestInterface request, Runnable callback) { @@ -73,4 +69,9 @@ public HWID getHWID() { return hwidProvider.getHWID(); } + + @FunctionalInterface + public interface HashedDirRunnable { + SignedObjectHolder run() throws Exception; + } } diff --git a/Launcher/src/main/java/ru/gravit/launcher/LauncherSettings.java b/Launcher/src/main/java/ru/gravit/launcher/client/LauncherSettings.java similarity index 98% rename from Launcher/src/main/java/ru/gravit/launcher/LauncherSettings.java rename to Launcher/src/main/java/ru/gravit/launcher/client/LauncherSettings.java index bdb463a1..563a5c29 100644 --- a/Launcher/src/main/java/ru/gravit/launcher/LauncherSettings.java +++ b/Launcher/src/main/java/ru/gravit/launcher/client/LauncherSettings.java @@ -1,7 +1,8 @@ -package ru.gravit.launcher; +package ru.gravit.launcher.client; import ru.gravit.launcher.Launcher; import ru.gravit.launcher.LauncherAPI; +import ru.gravit.launcher.client.DirBridge; import ru.gravit.launcher.hasher.HashedDir; import ru.gravit.launcher.profiles.ClientProfile; import ru.gravit.launcher.serialize.HInput;