Adds local-injected dev arg

This commit is contained in:
zeruth
2019-06-08 17:13:33 -04:00
parent 9eefe65f3d
commit 5589eba498
2 changed files with 87 additions and 196 deletions

View File

@@ -61,6 +61,7 @@ import net.runelite.client.menus.MenuManager;
import net.runelite.client.plugins.Plugin;
import net.runelite.client.plugins.PluginInstantiationException;
import net.runelite.client.plugins.PluginManager;
import net.runelite.client.rs.ClientLoader;
import net.runelite.client.rs.ClientUpdateCheckMode;
import net.runelite.client.task.Scheduler;
import net.runelite.client.ui.ClientUI;
@@ -87,7 +88,7 @@ public class RuneLite
public static final File PROFILES_DIR = new File(RUNELITE_DIR, "profiles");
public static final File PLUGIN_DIR = new File(RUNELITE_DIR, "plugins");
public static final File SCREENSHOT_DIR = new File(RUNELITE_DIR, "screenshots");
private static final RuneLiteSplashScreen splashScreen = new RuneLiteSplashScreen();
static final RuneLiteSplashScreen splashScreen = new RuneLiteSplashScreen();
@Getter
@@ -183,6 +184,7 @@ public class RuneLite
parser.accepts("developer-mode", "Enable developer tools");
parser.accepts("debug", "Show extra debugging output");
parser.accepts("no-splash", "Do not show the splash screen");
parser.accepts("local-injected", "Use local injected-client");
final ArgumentAcceptingOptionSpec<String> proxyInfo = parser
.accepts("proxy")
@@ -261,6 +263,11 @@ public class RuneLite
logger.setLevel(Level.DEBUG);
}
if (options.has("local-injected"))
{
ClientLoader.useLocalInjected = true;
}
Thread.setDefaultUncaughtExceptionHandler((thread, throwable) ->
{
log.error("Uncaught exception:", throwable);