From 9aba46e2766513be0c02b2f736335c05183eaa7b Mon Sep 17 00:00:00 2001 From: Juuz <6596629+Juuxel@users.noreply.github.com> Date: Tue, 31 Oct 2023 20:12:57 +0200 Subject: [PATCH] Rename MinecraftPatchedProvider jar paths on NeoForge --- .../providers/forge/MinecraftPatchedProvider.java | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/forge/MinecraftPatchedProvider.java b/src/main/java/net/fabricmc/loom/configuration/providers/forge/MinecraftPatchedProvider.java index 1c2b57552..3c8d2a08d 100644 --- a/src/main/java/net/fabricmc/loom/configuration/providers/forge/MinecraftPatchedProvider.java +++ b/src/main/java/net/fabricmc/loom/configuration/providers/forge/MinecraftPatchedProvider.java @@ -101,6 +101,7 @@ public class MinecraftPatchedProvider { private final MinecraftProvider minecraftProvider; private final Type type; + // TODO (Neo): Rename all these srg -> "intermediate" // Step 1: Remap Minecraft to SRG, merge if needed private Path minecraftSrgJar; // Step 2: Binary Patch @@ -141,9 +142,10 @@ private void initPatchedFiles() { minecraftProvider.setJarPrefix(patchId); - minecraftSrgJar = forgeWorkingDir.resolve("minecraft-" + type.id + "-srg.jar"); - minecraftPatchedSrgJar = forgeWorkingDir.resolve("minecraft-" + type.id + "-srg-patched.jar"); - minecraftPatchedSrgAtJar = forgeWorkingDir.resolve("minecraft-" + type.id + "-srg-at-patched.jar"); + final String intermediateId = getExtension().isNeoForge() ? "mojang" : "srg"; + minecraftSrgJar = forgeWorkingDir.resolve("minecraft-" + type.id + "-" + intermediateId + ".jar"); + minecraftPatchedSrgJar = forgeWorkingDir.resolve("minecraft-" + type.id + "-" + intermediateId + "-patched.jar"); + minecraftPatchedSrgAtJar = forgeWorkingDir.resolve("minecraft-" + type.id + "-" + intermediateId + "-at-patched.jar"); minecraftPatchedJar = forgeWorkingDir.resolve("minecraft-" + type.id + "-patched.jar"); minecraftClientExtra = forgeWorkingDir.resolve("client-extra.jar"); }