diff --git a/Il2CppDumper/Config.cs b/Il2CppDumper/Config.cs index a2e6844..bbd33cc 100644 --- a/Il2CppDumper/Config.cs +++ b/Il2CppDumper/Config.cs @@ -1,9 +1,4 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; - -namespace Il2CppDumper +namespace Il2CppDumper { public class Config { @@ -14,7 +9,8 @@ namespace Il2CppDumper public bool DumpFieldOffset = true; public bool DumpMethodOffset = true; public bool DumpTypeDefIndex = true; - public bool DummyDll = true; + public bool GenerateDummyDll = true; + public bool GenerateScript = true; public bool RequireAnyKey = true; public bool ForceIl2CppVersion = false; public float ForceVersion = 24.3f; diff --git a/Il2CppDumper/Program.cs b/Il2CppDumper/Program.cs index 9b7647f..300739f 100644 --- a/Il2CppDumper/Program.cs +++ b/Il2CppDumper/Program.cs @@ -108,7 +108,7 @@ namespace Il2CppDumper static void ShowHelp() { - Console.WriteLine($"usage: {AppDomain.CurrentDomain.FriendlyName} "); + Console.WriteLine($"usage: {AppDomain.CurrentDomain.FriendlyName} "); } private static bool Init(byte[] il2cppBytes, byte[] metadataBytes, out Metadata metadata, out Il2Cpp il2Cpp) @@ -219,11 +219,14 @@ namespace Il2CppDumper var decompiler = new Il2CppDecompiler(executor); decompiler.Decompile(config, outputDir); Console.WriteLine("Done!"); - Console.WriteLine("Generate script..."); - var scriptGenerator = new ScriptGenerator(executor); - scriptGenerator.WriteScript(outputDir); - Console.WriteLine("Done!"); - if (config.DummyDll) + if (config.GenerateScript) + { + Console.WriteLine("Generate script..."); + var scriptGenerator = new ScriptGenerator(executor); + scriptGenerator.WriteScript(outputDir); + Console.WriteLine("Done!"); + } + if (config.GenerateDummyDll) { Console.WriteLine("Generate dummy dll..."); DummyAssemblyExporter.Export(metadata, il2Cpp, outputDir); diff --git a/Il2CppDumper/config.json b/Il2CppDumper/config.json index 6a8ad77..b40c6a2 100644 --- a/Il2CppDumper/config.json +++ b/Il2CppDumper/config.json @@ -6,8 +6,9 @@ "DumpFieldOffset": true, "DumpMethodOffset": true, "DumpTypeDefIndex": true, - "DummyDll": true, + "GenerateDummyDll": true, + "GenerateScript": true, "RequireAnyKey": true, "ForceIl2CppVersion": false, - "ForceVersion": 24.3 + "ForceVersion": 16 } \ No newline at end of file diff --git a/Il2CppDumper/ghidra.py b/Il2CppDumper/ghidra.py index 583f817..e1038e1 100644 --- a/Il2CppDumper/ghidra.py +++ b/Il2CppDumper/ghidra.py @@ -33,7 +33,6 @@ def make_function(start, end): else: func.setBody(body) -print 'Script: Edit config.json and set MakeFunction to false to speed up ghidra script execution' f = askFile("script.json from Il2cppdumper", "Open") data = json.loads(open(f.absolutePath, 'rb').read().decode('utf-8'))