diff options
Diffstat (limited to 'src/main/java/cuchaz/enigma/ConvertMain.java')
| -rw-r--r-- | src/main/java/cuchaz/enigma/ConvertMain.java | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/main/java/cuchaz/enigma/ConvertMain.java b/src/main/java/cuchaz/enigma/ConvertMain.java index 67baeae..7715003 100644 --- a/src/main/java/cuchaz/enigma/ConvertMain.java +++ b/src/main/java/cuchaz/enigma/ConvertMain.java | |||
| @@ -63,7 +63,7 @@ public class ConvertMain { | |||
| 63 | editFieldMatches(sourceJar, destJar, outMappingsFile, mappings, classMatchesFile, fieldMatchesFile); | 63 | editFieldMatches(sourceJar, destJar, outMappingsFile, mappings, classMatchesFile, fieldMatchesFile); |
| 64 | convertMappings(outMappingsFile, sourceJar, destJar, mappings, classMatchesFile, fieldMatchesFile); | 64 | convertMappings(outMappingsFile, sourceJar, destJar, mappings, classMatchesFile, fieldMatchesFile); |
| 65 | } else if (command.equalsIgnoreCase("computeMethodMatches")) { | 65 | } else if (command.equalsIgnoreCase("computeMethodMatches")) { |
| 66 | computeMethodMatches(methodMatchesFile, destJar, outMappingsFile, classMatchesFile); | 66 | computeMethodMatches(outMappingsFile, sourceJar, destJar, mappings, classMatchesFile, fieldMatchesFile, methodMatchesFile); |
| 67 | convertMappings(outMappingsFile, sourceJar, destJar, mappings, classMatchesFile, fieldMatchesFile, methodMatchesFile); | 67 | convertMappings(outMappingsFile, sourceJar, destJar, mappings, classMatchesFile, fieldMatchesFile, methodMatchesFile); |
| 68 | } else if (command.equalsIgnoreCase("editMethodMatches")) { | 68 | } else if (command.equalsIgnoreCase("editMethodMatches")) { |
| 69 | editMethodMatches(sourceJar, destJar, outMappingsFile, mappings, classMatchesFile, methodMatchesFile); | 69 | editMethodMatches(sourceJar, destJar, outMappingsFile, mappings, classMatchesFile, methodMatchesFile); |
| @@ -224,15 +224,17 @@ public class ConvertMain { | |||
| 224 | } | 224 | } |
| 225 | 225 | ||
| 226 | 226 | ||
| 227 | private static void computeMethodMatches(File methodMatchesFile, JarFile destJar, File destMappingsFile, File classMatchesFile) | 227 | private static void computeMethodMatches(File outMappingsFile, JarFile sourceJar, JarFile destJar, Mappings sourceMappings, File classMatchesFile, File fieldMatchesFile, File methodMatchesFile) |
| 228 | throws IOException, MappingParseException { | 228 | throws IOException, MappingParseException { |
| 229 | 229 | ||
| 230 | System.out.println("Reading class matches..."); | 230 | System.out.println("Reading class matches..."); |
| 231 | ClassMatches classMatches = MatchesReader.readClasses(classMatchesFile); | 231 | ClassMatches classMatches = MatchesReader.readClasses(classMatchesFile); |
| 232 | System.out.println("Reading mappings..."); | 232 | System.out.println("Reading dest mappings..."); |
| 233 | Mappings destMappings = new MappingsEnigmaReader().read(destMappingsFile); | 233 | Mappings destMappings = new MappingsEnigmaReader().read(outMappingsFile); |
| 234 | System.out.println("Indexing dest jar..."); | 234 | System.out.println("Indexing dest jar..."); |
| 235 | Deobfuscator destDeobfuscator = new Deobfuscator(destJar); | 235 | Deobfuscator destDeobfuscator = new Deobfuscator(destJar); |
| 236 | System.out.println("Indexing source jar..."); | ||
| 237 | Deobfuscator sourceDeobfuscator = new Deobfuscator(sourceJar); | ||
| 236 | 238 | ||
| 237 | System.out.println("Writing method matches..."); | 239 | System.out.println("Writing method matches..."); |
| 238 | 240 | ||