From 2668cae02232cd43b8aa803c40278e482782f05a Mon Sep 17 00:00:00 2001 From: Adrian Siekierka Date: Sat, 27 Oct 2018 18:20:29 +0200 Subject: [PATCH] allow using either Enigma or Tiny for remapping JAR --- build.gradle | 5 +- .../fabricmc/loom/LoomGradleExtension.java | 5 +- .../net/fabricmc/loom/LoomGradlePlugin.java | 2 + .../net/fabricmc/loom/task/DownloadTask.java | 22 +++- .../net/fabricmc/loom/task/FinaliseJar.java | 2 +- .../net/fabricmc/loom/task/MapJarsEnigma.java | 118 ++++++++++++++++++ .../net/fabricmc/loom/task/MapJarsTask.java | 55 ++------ .../net/fabricmc/loom/task/MapJarsTiny.java | 74 +++++++++++ .../net/fabricmc/loom/util/Constants.java | 10 +- 9 files changed, 239 insertions(+), 54 deletions(-) create mode 100644 src/main/java/net/fabricmc/loom/task/MapJarsEnigma.java create mode 100644 src/main/java/net/fabricmc/loom/task/MapJarsTiny.java diff --git a/build.gradle b/build.gradle index 56861d4..de2c4f9 100644 --- a/build.gradle +++ b/build.gradle @@ -53,7 +53,10 @@ dependencies { shade ('net.fabricmc:weave:+'){ transitive = false } - shade 'net.fabricmc:tiny-remapper:0.1.0.5' + shade ('enigma-asm:enigma:0.12.0.+:lib'){ + exclude group: 'org.ow2.asm' + } + shade 'net.fabricmc:tiny-remapper:0.1.0.12' shade 'net.sf.jopt-simple:jopt-simple:5.0.4' shade 'org.apache.logging.log4j:log4j-api:2.11.1' shade 'org.apache.logging.log4j:log4j-core:2.11.1' diff --git a/src/main/java/net/fabricmc/loom/LoomGradleExtension.java b/src/main/java/net/fabricmc/loom/LoomGradleExtension.java index 51be054..647937e 100644 --- a/src/main/java/net/fabricmc/loom/LoomGradleExtension.java +++ b/src/main/java/net/fabricmc/loom/LoomGradleExtension.java @@ -24,6 +24,7 @@ package net.fabricmc.loom; +import net.fabricmc.loom.util.Constants; import org.gradle.api.Project; import java.io.File; @@ -34,7 +35,7 @@ public class LoomGradleExtension { public String fabricVersion; public String pomfVersion; public String refmapName; - public boolean skipPrebake = false; + public String jarMapper = Constants.JAR_MAPPER_ENIGMA; // enigma, tiny public boolean localMappings = false; //Not to be set in the build.gradle @@ -60,7 +61,7 @@ public class LoomGradleExtension { } public boolean hasPomf(){ - if(localMappings){ + if (localMappings) { return true; } return pomfVersion != null && !pomfVersion.isEmpty(); diff --git a/src/main/java/net/fabricmc/loom/LoomGradlePlugin.java b/src/main/java/net/fabricmc/loom/LoomGradlePlugin.java index a5484b0..6767b22 100644 --- a/src/main/java/net/fabricmc/loom/LoomGradlePlugin.java +++ b/src/main/java/net/fabricmc/loom/LoomGradlePlugin.java @@ -25,8 +25,10 @@ package net.fabricmc.loom; import net.fabricmc.loom.task.*; +import net.fabricmc.loom.util.Constants; import org.gradle.api.DefaultTask; import org.gradle.api.Project; +import org.gradle.api.Task; public class LoomGradlePlugin extends AbstractPlugin { @Override diff --git a/src/main/java/net/fabricmc/loom/task/DownloadTask.java b/src/main/java/net/fabricmc/loom/task/DownloadTask.java index 4cce5f5..a8658d8 100644 --- a/src/main/java/net/fabricmc/loom/task/DownloadTask.java +++ b/src/main/java/net/fabricmc/loom/task/DownloadTask.java @@ -40,6 +40,7 @@ import org.gradle.api.artifacts.Configuration; import org.gradle.api.artifacts.dsl.DependencyHandler; import org.gradle.api.logging.Logger; import org.gradle.api.tasks.TaskAction; +import org.spongepowered.asm.mixin.injection.Constant; import java.io.*; import java.net.URL; @@ -72,17 +73,34 @@ public class DownloadTask extends DefaultTask { Constants.POMF_DIR.get(extension).mkdir(); } + if (Constants.JAR_MAPPER_ENIGMA.equals(extension.jarMapper)) { + if (!Constants.MAPPINGS_ENIGMA_ZIP.get(extension).exists() && extension.hasPomf()) { + this.getLogger().lifecycle(":downloading enigma mappings"); + try { + FileUtils.copyURLToFile( + new URL(Constants.POMF_JENKINS_SERVER + "/job/FabricMC/job/pomf/job/" + extension.version + "/" + extension.pomfVersion + "/artifact/build/libs/pomf-enigma-" + extension.version + "." + extension.pomfVersion + ".zip"), + Constants.MAPPINGS_ENIGMA_ZIP.get(extension) + ); + } catch (Exception e) { + throw new RuntimeException("Failed to download mappings", e); + } + } + } + if (!extension.hasPomf()) { if (Constants.MAPPINGS_DIR_LOCAL.get(extension).exists()) { - if (Constants.MAPPINGS_TINY_GZ_LOCAL.get(extension).exists() && Constants.MAPPINGS_ZIP_LOCAL.get(extension).exists()) { + if (Constants.MAPPINGS_TINY_GZ_LOCAL.get(extension).exists() && (!Constants.JAR_MAPPER_ENIGMA.equals(extension.jarMapper) || Constants.MAPPINGS_ENIGMA_ZIP_LOCAL.get(extension).exists())) { this.getLogger().lifecycle(":using local mappings!"); extension.localMappings = true; //We delete this to make sure they are always re extracted. + deleteIfExists(Constants.MAPPINGS_ENIGMA_DIR.get(extension)); + deleteIfExists(Constants.MAPPINGS_ENIGMA_ZIP.get(extension)); deleteIfExists(Constants.MAPPINGS_TINY_GZ.get(extension)); deleteIfExists(Constants.MAPPINGS_TINY.get(extension)); Constants.MAPPINGS_TINY_GZ = Constants.MAPPINGS_TINY_GZ_LOCAL; + Constants.MAPPINGS_ENIGMA_ZIP = Constants.MAPPINGS_ENIGMA_ZIP_LOCAL; } } } @@ -91,7 +109,7 @@ public class DownloadTask extends DefaultTask { if (!Constants.MAPPINGS_TINY_GZ.get(extension).exists() && !extension.localMappings) { getLogger().lifecycle(":downloading tiny mappings"); try { - FileUtils.copyURLToFile(new URL("http://modmuss50.me:8080/job/FabricMC/job/pomf/job/" + extension.version + "/" + extension.pomfVersion + "/artifact/build/libs/pomf-tiny-" + extension.version + "." + extension.pomfVersion + ".gz"), Constants.MAPPINGS_TINY_GZ.get(extension)); + FileUtils.copyURLToFile(new URL(Constants.POMF_JENKINS_SERVER + "/job/FabricMC/job/pomf/job/" + extension.version + "/" + extension.pomfVersion + "/artifact/build/libs/pomf-tiny-" + extension.version + "." + extension.pomfVersion + ".gz"), Constants.MAPPINGS_TINY_GZ.get(extension)); } catch (Exception e) { throw new RuntimeException("Failed to download mappings", e); } diff --git a/src/main/java/net/fabricmc/loom/task/FinaliseJar.java b/src/main/java/net/fabricmc/loom/task/FinaliseJar.java index aaad624..f11667a 100644 --- a/src/main/java/net/fabricmc/loom/task/FinaliseJar.java +++ b/src/main/java/net/fabricmc/loom/task/FinaliseJar.java @@ -35,7 +35,7 @@ import java.io.IOException; public class FinaliseJar extends DefaultTask { @TaskAction - public void finalisejar() throws IOException { + public void finaliseJar() throws IOException { LoomGradleExtension extension = this.getProject().getExtensions().getByType(LoomGradleExtension.class); if(Constants.MINECRAFT_FINAL_JAR.get(extension).exists()){ Constants.MINECRAFT_FINAL_JAR.get(extension).delete(); diff --git a/src/main/java/net/fabricmc/loom/task/MapJarsEnigma.java b/src/main/java/net/fabricmc/loom/task/MapJarsEnigma.java new file mode 100644 index 0000000..1061e38 --- /dev/null +++ b/src/main/java/net/fabricmc/loom/task/MapJarsEnigma.java @@ -0,0 +1,118 @@ +/* + * This file is part of fabric-loom, licensed under the MIT License (MIT). + * + * Copyright (c) 2016, 2017, 2018 FabricMC + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + */ + +package net.fabricmc.loom.task; + + +import cuchaz.enigma.Deobfuscator; +import cuchaz.enigma.TranslatingTypeLoader; +import cuchaz.enigma.mapping.MappingsEnigmaReader; +import cuchaz.enigma.mapping.TranslationDirection; +import cuchaz.enigma.mapping.Translator; +import cuchaz.enigma.mapping.entry.ReferencedEntryPool; +import cuchaz.enigma.throwables.MappingParseException; +import net.fabricmc.loom.LoomGradleExtension; +import net.fabricmc.loom.util.Constants; +import net.fabricmc.tinyremapper.OutputConsumerPath; +import net.fabricmc.tinyremapper.TinyRemapper; +import net.fabricmc.tinyremapper.TinyUtils; +import org.gradle.api.DefaultTask; +import org.gradle.api.tasks.TaskAction; +import org.zeroturnaround.zip.ZipUtil; +import org.zeroturnaround.zip.commons.FileUtils; + +import java.io.File; +import java.io.IOException; +import java.nio.file.Path; +import java.util.jar.JarFile; + +public class MapJarsEnigma { + Deobfuscator deobfuscator; + + public void mapJars(MapJarsTask task) throws IOException, MappingParseException { + LoomGradleExtension extension = task.getProject().getExtensions().getByType(LoomGradleExtension.class); + if (!Constants.MINECRAFT_MAPPED_JAR.get(extension).exists() || extension.localMappings || true) { + if(Constants.MINECRAFT_MAPPED_JAR.get(extension).exists()){ + Constants.MINECRAFT_MAPPED_JAR.get(extension).delete(); + } + + if (!extension.hasPomf()) { + task.getLogger().lifecycle("POMF version not set, skipping mapping!"); + FileUtils.copyFile(Constants.MINECRAFT_MERGED_JAR.get(extension), Constants.MINECRAFT_MAPPED_JAR.get(extension)); + return; + } + + if (!Constants.MAPPINGS_ENIGMA_DIR.get(extension).exists() || extension.localMappings) { + task.getLogger().lifecycle(":unpacking mappings"); + FileUtils.deleteDirectory(Constants.MAPPINGS_ENIGMA_DIR.get(extension)); + ZipUtil.unpack(Constants.MAPPINGS_ENIGMA_ZIP.get(extension), Constants.MAPPINGS_ENIGMA_DIR.get(extension)); + } + + task.getLogger().lifecycle(":remapping jar (Enigma)"); + deobfuscator = new Deobfuscator(new JarFile(Constants.MINECRAFT_MERGED_JAR.get(extension))); + deobfuscator.setMappings(new MappingsEnigmaReader().read(Constants.MAPPINGS_ENIGMA_DIR.get(extension))); + writeJar(Constants.MINECRAFT_PARTIAL_ENIGMA_JAR.get(extension), new ProgressListener(), deobfuscator); + + File tempAssets = new File(Constants.CACHE_FILES, "tempAssets"); + if (tempAssets.exists()) { + FileUtils.deleteDirectory(tempAssets); + } + tempAssets.mkdir(); + + ZipUtil.unpack(Constants.MINECRAFT_CLIENT_JAR.get(extension), tempAssets, name -> { + if (!name.endsWith(".class") && !name.startsWith("META-INF")) { + return name; + } else { + return null; + } + }); + ZipUtil.unpack(Constants.MINECRAFT_PARTIAL_ENIGMA_JAR.get(extension), tempAssets); + + ZipUtil.pack(tempAssets, Constants.MINECRAFT_MAPPED_JAR.get(extension)); + FileUtils.deleteDirectory(tempAssets); + } else { + task.getLogger().lifecycle(Constants.MINECRAFT_MAPPED_JAR.get(extension).getAbsolutePath()); + task.getLogger().lifecycle(":mapped jar found, skipping mapping"); + } + } + + public void writeJar(File out, Deobfuscator.ProgressListener progress, Deobfuscator deobfuscator) { + Translator obfuscationTranslator = deobfuscator.getTranslator(TranslationDirection.OBFUSCATING); + Translator deobfuscationTranslator = deobfuscator.getTranslator(TranslationDirection.DEOBFUSCATING); + TranslatingTypeLoader loader = new TranslatingTypeLoader(deobfuscator.getJar(), deobfuscator.getJarIndex(), new ReferencedEntryPool(), obfuscationTranslator, deobfuscationTranslator); + deobfuscator.transformJar(out, progress, loader::transformInto); + } + + public static class ProgressListener implements Deobfuscator.ProgressListener { + @Override + public void init(int i, String s) { + + } + + @Override + public void onProgress(int i, String s) { + + } + } +} diff --git a/src/main/java/net/fabricmc/loom/task/MapJarsTask.java b/src/main/java/net/fabricmc/loom/task/MapJarsTask.java index 835c917..2baf1a0 100644 --- a/src/main/java/net/fabricmc/loom/task/MapJarsTask.java +++ b/src/main/java/net/fabricmc/loom/task/MapJarsTask.java @@ -24,71 +24,34 @@ package net.fabricmc.loom.task; - import net.fabricmc.loom.LoomGradleExtension; import net.fabricmc.loom.util.Constants; -import net.fabricmc.tinyremapper.OutputConsumerPath; -import net.fabricmc.tinyremapper.TinyRemapper; -import net.fabricmc.tinyremapper.TinyUtils; import org.gradle.api.DefaultTask; import org.gradle.api.tasks.TaskAction; -import org.zeroturnaround.zip.ZipUtil; import org.zeroturnaround.zip.commons.FileUtils; -import java.io.File; -import java.io.IOException; -import java.nio.file.Path; - public class MapJarsTask extends DefaultTask { - - @TaskAction - public void mapJars() throws IOException { + public void mapJars() throws Exception { LoomGradleExtension extension = this.getProject().getExtensions().getByType(LoomGradleExtension.class); if (!Constants.MINECRAFT_MAPPED_JAR.get(extension).exists() || extension.localMappings || true) { if(Constants.MINECRAFT_MAPPED_JAR.get(extension).exists()){ Constants.MINECRAFT_MAPPED_JAR.get(extension).delete(); } - if(!extension.hasPomf()){ + + if (!extension.hasPomf()) { this.getLogger().lifecycle("POMF version not set, skipping mapping!"); FileUtils.copyFile(Constants.MINECRAFT_MERGED_JAR.get(extension), Constants.MINECRAFT_MAPPED_JAR.get(extension)); return; } - String fromM = "mojang"; - String toM = "pomf"; - - Path mappings = Constants.MAPPINGS_TINY.get(extension).toPath(); - Path[] classpath = getProject().getConfigurations().getByName(Constants.CONFIG_MC_DEPENDENCIES).getFiles().stream() - .map(File::toPath) - .toArray(Path[]::new); - - this.getLogger().lifecycle(":remapping minecraft to " + toM); - - TinyRemapper remapper = TinyRemapper.newRemapper() - .withMappings(TinyUtils.createTinyMappingProvider(mappings, fromM, toM)) - .build(); - - try { - OutputConsumerPath outputConsumer = new OutputConsumerPath(Constants.MINECRAFT_MAPPED_JAR.get(extension).toPath()); - outputConsumer.addNonClassFiles(Constants.MINECRAFT_MERGED_JAR.get(extension).toPath()); - remapper.read(Constants.MINECRAFT_MERGED_JAR.get(extension).toPath()); - remapper.read(classpath); - remapper.apply(Constants.MINECRAFT_MERGED_JAR.get(extension).toPath(), outputConsumer); - outputConsumer.finish(); - remapper.finish(); - } catch (Exception e){ - remapper.finish(); - throw new RuntimeException("Failed to remap minecraft to " + toM, e); + if (Constants.JAR_MAPPER_ENIGMA.equals(extension.jarMapper)) { + new MapJarsEnigma().mapJars(this); + } else if (Constants.JAR_MAPPER_TINY.equals(extension.jarMapper)) { + new MapJarsTiny().mapJars(this); + } else { + throw new RuntimeException("Unknown JAR mapper type: " + extension.jarMapper); } - - File tempAssets = new File(Constants.CACHE_FILES, "tempAssets"); - if (tempAssets.exists()) { - FileUtils.deleteDirectory(tempAssets); - } - tempAssets.mkdir(); - - FileUtils.deleteDirectory(tempAssets); } else { this.getLogger().lifecycle(Constants.MINECRAFT_MAPPED_JAR.get(extension).getAbsolutePath()); this.getLogger().lifecycle(":mapped jar found, skipping mapping"); diff --git a/src/main/java/net/fabricmc/loom/task/MapJarsTiny.java b/src/main/java/net/fabricmc/loom/task/MapJarsTiny.java new file mode 100644 index 0000000..7ea9e50 --- /dev/null +++ b/src/main/java/net/fabricmc/loom/task/MapJarsTiny.java @@ -0,0 +1,74 @@ +/* + * This file is part of fabric-loom, licensed under the MIT License (MIT). + * + * Copyright (c) 2016, 2017, 2018 FabricMC + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + */ + +package net.fabricmc.loom.task; + + +import net.fabricmc.loom.LoomGradleExtension; +import net.fabricmc.loom.util.Constants; +import net.fabricmc.tinyremapper.OutputConsumerPath; +import net.fabricmc.tinyremapper.TinyRemapper; +import net.fabricmc.tinyremapper.TinyUtils; +import org.gradle.api.DefaultTask; +import org.gradle.api.tasks.TaskAction; +import org.zeroturnaround.zip.ZipUtil; +import org.zeroturnaround.zip.commons.FileUtils; + +import java.io.File; +import java.io.IOException; +import java.nio.file.Path; + +public class MapJarsTiny { + + public void mapJars(MapJarsTask task) throws IOException { + LoomGradleExtension extension = task.getProject().getExtensions().getByType(LoomGradleExtension.class); + + String fromM = "mojang"; + String toM = "pomf"; + + Path mappings = Constants.MAPPINGS_TINY.get(extension).toPath(); + Path[] classpath = task.getProject().getConfigurations().getByName(Constants.CONFIG_MC_DEPENDENCIES).getFiles().stream() + .map(File::toPath) + .toArray(Path[]::new); + + task.getLogger().lifecycle(":remapping minecraft (TinyRemapper, " + fromM + " -> " + toM + ")"); + + TinyRemapper remapper = TinyRemapper.newRemapper() + .withMappings(TinyUtils.createTinyMappingProvider(mappings, fromM, toM)) + .build(); + + try { + OutputConsumerPath outputConsumer = new OutputConsumerPath(Constants.MINECRAFT_MAPPED_JAR.get(extension).toPath()); + outputConsumer.addNonClassFiles(Constants.MINECRAFT_MERGED_JAR.get(extension).toPath()); + remapper.read(Constants.MINECRAFT_MERGED_JAR.get(extension).toPath()); + remapper.read(classpath); + remapper.apply(Constants.MINECRAFT_MERGED_JAR.get(extension).toPath(), outputConsumer); + outputConsumer.finish(); + remapper.finish(); + } catch (Exception e){ + remapper.finish(); + throw new RuntimeException("Failed to remap minecraft to " + toM, e); + } + } +} diff --git a/src/main/java/net/fabricmc/loom/util/Constants.java b/src/main/java/net/fabricmc/loom/util/Constants.java index 0ddecf4..5adcecd 100644 --- a/src/main/java/net/fabricmc/loom/util/Constants.java +++ b/src/main/java/net/fabricmc/loom/util/Constants.java @@ -37,20 +37,25 @@ public class Constants { public static final File WORKING_DIRECTORY = new File("."); public static final File CACHE_FILES = new File(WORKING_DIRECTORY, ".gradle/minecraft"); + public static final String JAR_MAPPER_ENIGMA = "enigma"; + public static final String JAR_MAPPER_TINY = "tiny"; + public static final IDelayed MINECRAFT_CLIENT_JAR = new DelayedFile(extension -> new File(extension.getUserCache(), extension.version + "-client.jar")); public static final IDelayed MINECRAFT_SERVER_JAR = new DelayedFile(extension -> new File(extension.getUserCache(), extension.version + "-server.jar")); public static final IDelayed MINECRAFT_MERGED_JAR = new DelayedFile(extension -> new File(extension.getUserCache(), extension.version + "-merged.jar")); public static final IDelayed MINECRAFT_MAPPED_JAR = new DelayedFile(extension -> new File(extension.getUserCache(), extension.version + "-mapped-" + extension.pomfVersion + ".jar")); + public static final IDelayed MINECRAFT_PARTIAL_ENIGMA_JAR = new DelayedFile(extension -> new File(extension.getUserCache(), extension.version + "-partial-enigma-" + extension.pomfVersion + ".jar")); public static final IDelayed MINECRAFT_FINAL_JAR = new DelayedFile(extension -> new File(CACHE_FILES, extension.version + "-final-" + extension.pomfVersion + ".jar")); public static final IDelayed POMF_DIR = new DelayedFile(extension -> new File(extension.getUserCache(), "pomf")); public static IDelayed MAPPINGS_TINY_GZ = new DelayedFile(extension -> new File(POMF_DIR.get(extension), "pomf-tiny-" + extension.version + "." + extension.pomfVersion + ".gz")); public static final IDelayed MAPPINGS_TINY = new DelayedFile(extension -> new File(POMF_DIR.get(extension), "pomf-tiny-" + extension.version + "." + extension.pomfVersion)); public static final IDelayed MAPPINGS_MIXIN_EXPORT = new DelayedFile(extension -> new File(CACHE_FILES, "mixin-map-" + extension.version + "." + extension.pomfVersion + ".mappings")); - + public static IDelayed MAPPINGS_ENIGMA_ZIP = new DelayedFile(extension -> new File(POMF_DIR.get(extension), "pomf-enigma-" + extension.version + "." + extension.pomfVersion + ".zip")); + public static final IDelayed MAPPINGS_ENIGMA_DIR = new DelayedFile(extension -> new File(POMF_DIR.get(extension), "pomf-enigma-" + extension.version + "." + extension.pomfVersion + "")); public static final IDelayed MAPPINGS_DIR_LOCAL = new DelayedFile(extension -> new File(WORKING_DIRECTORY, "mappings")); - public static final IDelayed MAPPINGS_ZIP_LOCAL = new DelayedFile(extension -> new File(MAPPINGS_DIR_LOCAL.get(extension), "pomf-enigma-" + extension.version + ".zip")); + public static final IDelayed MAPPINGS_ENIGMA_ZIP_LOCAL = new DelayedFile(extension -> new File(MAPPINGS_DIR_LOCAL.get(extension), "pomf-enigma-" + extension.version + ".zip")); public static final IDelayed MAPPINGS_TINY_GZ_LOCAL = new DelayedFile(extension -> new File(MAPPINGS_DIR_LOCAL.get(extension), "pomf-tiny-" + extension.version + ".gz")); public static final IDelayed MINECRAFT_LIBS = new DelayedFile(extension -> new File(extension.getUserCache(), extension.version + "-libs")); @@ -62,6 +67,7 @@ public class Constants { public static final String FABRIC_CLIENT_TWEAKER = "net.fabricmc.base.launch.FabricClientTweaker"; public static final String FABRIC_SERVER_TWEAKER = "net.fabricmc.base.launch.FabricServerTweaker"; + public static final String POMF_JENKINS_SERVER = "http://modmuss50.me:8080"; public static final String LIBRARIES_BASE = "https://libraries.minecraft.net/"; public static final String RESOURCES_BASE = "http://resources.download.minecraft.net/";