-
Notifications
You must be signed in to change notification settings - Fork 40
Decompilation options
RetroMCP-Java features many configuration options for customizing how Minecraft is decompiled and reobfuscated.
Many of these options can be found in the GUI or by looking at the help [command_name] output in the CLI.
For example, the decompile task has the following parameters (as of v1.2):
> help decompile
- decompile Start decompiling Minecraft
Optional parameters:
source - Set a specific source version
target - Set a specific target version
javahome - Set JAVA_HOME used for compiling
javacargs - Set Java compiler arguments
ignore - Set ignored packages
ff_options - Set Fernflower options
patch - Apply patches
side - Set side
stripgenerics - Strip genericsSource and target version affect how the decompile task recompiles the game. Most Minecraft versions were originally compiled with Java 5 bytecode level though many mods today use Java 8 as the output level.
JAVA_HOME is used when compiling with a different JDK than what RetroMCP-Java is being ran with. This option is non-functional in versions before RetroMCP-Java v1.2. Examples of this option include: "C:/Program Files (x86)/Zulu/zulu-8", "C:/Program Files/Java/jdk1.6.0_45". javac.exe/javac executable must exist in the bin sub-folder of JAVA_HOME location.
Java compiler arguments are used to control how Javac (the Java compiler) is used. Examples of this include setting a custom class path to allow use of external libraries, modifying source and target versions without using the built-in option, or adding debug flags to the Java compiler.
ignore is used to control what packages are removed after decompilation. Packages which are removed by default include:
paulscode, com/jcraft, de/jarnbjo, isom, ibxm, de/matthiasmann/twl, javax/xml, javax/ws, argo, org/bouncycastle, org/apache/commons, com/google/gson, com/google/common
ff_options control the Fernflower decompiler output. Valid examples of arguments can be found here.
patch is a boolean option to determine whether patches are applied. This is true by default for all versions and is only used if patches do exist for the given version (present in conf/[SIDE].patch).
Finally, side controls which sides are to be decompiled. Valid sides include: ANY, CLIENT, SERVER, and MERGED. By default, ANY will decompile both the client and server. MERGED will decompile both sides into the same module, however, this may only be used on mappings with mergeable mappings (which have the same names for client & server).