From 1f2bed2ef119094bdc156aa3a206b93dea5081d1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20Mr=C3=A1zek?= Date: Thu, 16 Jun 2016 02:20:23 +0200 Subject: NOISSUE implement direct java launch Just running the Java process and giving it params on the command line --- .../org/multimc/onesix/OneSixLauncher.java | 112 --------------------- 1 file changed, 112 deletions(-) (limited to 'libraries/launcher/org/multimc/onesix/OneSixLauncher.java') diff --git a/libraries/launcher/org/multimc/onesix/OneSixLauncher.java b/libraries/launcher/org/multimc/onesix/OneSixLauncher.java index 179df0ee..e3e4c283 100644 --- a/libraries/launcher/org/multimc/onesix/OneSixLauncher.java +++ b/libraries/launcher/org/multimc/onesix/OneSixLauncher.java @@ -30,9 +30,6 @@ public class OneSixLauncher implements Launcher { // parameters, separated from ParamBucket private List libraries; - private List extlibs; - private List extlibs32; - private List extlibs64; private List mcparams; private List mods; private List jarmods; @@ -56,28 +53,9 @@ public class OneSixLauncher implements Launcher private void processParams(ParamBucket params) throws NotFoundException { libraries = params.all("cp"); - extlibs = params.allSafe("ext", new ArrayList()); - extlibs32 = params.allSafe("ext32", new ArrayList()); - extlibs64 = params.allSafe("ext64", new ArrayList()); - - // Unify the extracted native libs according to actual system architecture - String property = System.getProperty("os.arch"); - boolean is_64 = property.equalsIgnoreCase("x86_64") || property.equalsIgnoreCase("amd64"); - if(is_64) - { - extlibs.addAll(extlibs64); - } - else - { - extlibs.addAll(extlibs32); - } - mcparams = params.allSafe("param", new ArrayList() ); mainClass = params.firstSafe("mainClass", "net.minecraft.client.Minecraft"); appletClass = params.firstSafe("appletClass", "net.minecraft.client.MinecraftApplet"); - mods = params.allSafe("mod", new ArrayList()); - jarmods = params.allSafe("jarmod", new ArrayList()); - coremods = params.allSafe("coremod", new ArrayList()); traits = params.allSafe("traits", new ArrayList()); nativePath = params.first("natives"); @@ -105,75 +83,6 @@ public class OneSixLauncher implements Launcher } } - private void printStats() - { - Utils.log("Main Class:"); - Utils.log(" " + mainClass); - Utils.log(); - - Utils.log("Native path:"); - Utils.log(" " + nativePath); - Utils.log(); - - Utils.log("Traits:"); - Utils.log(" " + traits); - Utils.log(); - - Utils.log("Libraries:"); - for (String s : libraries) - { - File f = new File(s); - if (f.exists()) - { - Utils.log(" " + s); - } - else - { - Utils.log(" " + s + " (missing)", "Warning"); - } - } - Utils.log(); - - if(mods.size() > 0) - { - Utils.log("Mods:"); - for (String s : mods) - { - Utils.log(" " + s); - } - Utils.log(); - } - - if(coremods.size() > 0) - { - Utils.log("Core Mods:"); - for (String s : coremods) - { - Utils.log(" " + s); - } - Utils.log(); - } - - if(jarmods.size() > 0) - { - Utils.log("Jar Mods:"); - for (String s : jarmods) - { - Utils.log(" " + s); - } - Utils.log(); - } - - Utils.log("Params:"); - Utils.log(" " + mcparams.toString()); - Utils.log(); - if(maximize) - Utils.log("Window size: max (if available)"); - else - Utils.log("Window size: " + Integer.toString(winSize.width) + " x " + Integer.toString(winSize.height)); - Utils.log(); - } - int legacyLaunch() { // Get the Minecraft Class and set the base folder @@ -310,27 +219,6 @@ public class OneSixLauncher implements Launcher return -1; } - // print the pretty things - printStats(); - - // extract native libs (depending on platform here... java!) - Utils.log("Preparing native libraries..."); - for(String extlib: extlibs) - { - try - { - File extlibf = new File(extlib); - Utils.log("Extracting " + extlibf.getName()); - Utils.unzipNatives(extlibf, new File(nativePath)); - } catch (IOException e) - { - System.err.println("Failed to extract native library:"); - e.printStackTrace(System.err); - return -1; - } - } - Utils.log(); - // set the native libs path... the brute force way try { -- cgit v1.2.3