Skip to content

Commit

Permalink
rename hasIntermediary to usesMojmapAsIntermediate
Browse files Browse the repository at this point in the history
  • Loading branch information
Jab125 committed Apr 28, 2024
1 parent be248c6 commit 287b34e
Showing 1 changed file with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ private void initPatchedFiles() {
minecraftProvider.setJarPrefix(patchId);

String intermediateId = getExtension().isNeoForge() ? "mojang" : "srg";
if (!hasIntermediary()) intermediateId += "-no-intermediary";
if (usesMojmapAsIntermediate()) intermediateId += "-no-intermediary";
minecraftIntermediateJar = forgeWorkingDir.resolve("minecraft-" + type.id + "-" + intermediateId + ".jar");
minecraftPatchedIntermediateJar = forgeWorkingDir.resolve("minecraft-" + type.id + "-" + intermediateId + "-patched.jar");
minecraftPatchedIntermediateAtJar = forgeWorkingDir.resolve("minecraft-" + type.id + "-" + intermediateId + "-at-patched.jar");
Expand Down Expand Up @@ -233,8 +233,8 @@ private TinyRemapper buildRemapper(SharedServiceManager serviceManager, Path inp
MemoryMappingTree mappings = mappingsService.getMappingTree();

TinyRemapper remapper = TinyRemapper.newRemapper()
.withMappings(TinyRemapperHelper.create(mappings, sourceNamespace, hasIntermediary() ? "official" : sourceNamespace, true))
.withMappings(InnerClassRemapper.of(InnerClassRemapper.readClassNames(input), mappings, sourceNamespace, hasIntermediary() ? "official" : sourceNamespace))
.withMappings(TinyRemapperHelper.create(mappings, sourceNamespace, !usesMojmapAsIntermediate() ? "official" : sourceNamespace, true))
.withMappings(InnerClassRemapper.of(InnerClassRemapper.readClassNames(input), mappings, sourceNamespace, !usesMojmapAsIntermediate() ? "official" : sourceNamespace))
.renameInvalidLocals(true)
.rebuildSourceFilenames(true)
.build();
Expand Down Expand Up @@ -573,8 +573,8 @@ public void applyLoomPatchVersion(Path target) throws IOException {
}
}

public boolean hasIntermediary() {
return !getExtension().isNeoForge();
public boolean usesMojmapAsIntermediate() {
return getExtension().isNeoForge();
}

public McpExecutor createMcpExecutor(Path cache) {
Expand Down

0 comments on commit 287b34e

Please sign in to comment.