mirror of
https://github.com/GravitLauncher/Launcher
synced 2024-11-15 11:39:11 +03:00
[FIX] 1.14 запуск.
This commit is contained in:
parent
56bd3f1268
commit
29519728b8
1 changed files with 2 additions and 2 deletions
|
@ -304,11 +304,11 @@ private static void launch(ClientProfile profile, Params params) throws Throwabl
|
||||||
LogHelper.debug("Args: " + copy);
|
LogHelper.debug("Args: " + copy);
|
||||||
// Resolve main class and method
|
// Resolve main class and method
|
||||||
Class<?> mainClass = classLoader.loadClass(profile.getMainClass());
|
Class<?> mainClass = classLoader.loadClass(profile.getMainClass());
|
||||||
MethodHandle mainMethod = MethodHandles.publicLookup().findStatic(mainClass, "main", MethodType.methodType(void.class, String[].class));
|
MethodHandle mainMethod = MethodHandles.publicLookup().findStatic(mainClass, "main", MethodType.methodType(void.class, String[].class)).asFixedArity();
|
||||||
Launcher.LAUNCHED.set(true);
|
Launcher.LAUNCHED.set(true);
|
||||||
JVMHelper.fullGC();
|
JVMHelper.fullGC();
|
||||||
// Invoke main method
|
// Invoke main method
|
||||||
mainMethod.invoke((Object) args.toArray(new String[0]));
|
mainMethod.invokeWithArguments((Object)args.toArray(new String[0]));
|
||||||
}
|
}
|
||||||
|
|
||||||
private static Process process = null;
|
private static Process process = null;
|
||||||
|
|
Loading…
Reference in a new issue