Add Forge mixin support

This commit is contained in:
Juuxel
2020-12-03 12:21:01 +02:00
parent 6fc3af3f65
commit e88a614b72
3 changed files with 9 additions and 1 deletions

View File

@@ -76,6 +76,7 @@ public class LoomGradleExtension {
public File accessWidener = null;
public Function<String, Object> intermediaryUrl = mcVer -> "https://maven.fabricmc.net/net/fabricmc/intermediary/" + mcVer + "/intermediary-" + mcVer + "-v2.jar";
public boolean shareCaches = false;
public String mixinConfig = null; // FORGE: Passed to Minecraft
private final ConfigurableFileCollection unmappedMods;

View File

@@ -82,6 +82,13 @@ public class LaunchProvider extends DependencyProvider {
.argument("server", "--launchTarget")
.argument("server", "fmluserdevserver");
String mixinConfig = getExtension().mixinConfig;
if (mixinConfig != null) {
launchConfig.argument("-mixin.config");
launchConfig.argument(mixinConfig);
}
}
//Enable ansi by default for idea and vscode