Forge 41.0.64 for Minecraft 1.19 introduces several breaking changes to client code and 41.0.94 makes several additional renames.
In this guide we'll set up, configure and run SizableShrimp's automatic remapping tool to go through your code and take care of a large number of changes for you. This will only work if your mod is written in Java, so if it isn't, skip to the manual porting guide.
ℹ This guide works regardless of the mappings you're using. ℹ |
---|
Here's what we'll do:
- Ensure the mod compiles
- Add the auto-remapping script
- Run the script
- Remove the script and update Forge
You can find a guide with further manual porting steps and all major changes at the following link:
<link is not ready yet>
First off, you will want ensure you're running ForgeGradle 5 and that you're on a version of Forge prior to 1.19-41.0.64
. It can be any version, even 1.18.X or lower, as long as your code compiles correctly.
Next, we'll set up the script. To do this, simply add the following after all the plugin lines in your build.gradle
:
apply from: 'https://raw.githubusercontent.com/SizableShrimp/ForgeUpdatesRemapper/main/remapper.gradle'
The resulting file will look something like this:
// ["buildscript" block and other plugins]
apply plugin: 'net.minecraftforge.gradle'
apply plugin: 'maven-publish'
apply from: 'https://raw.githubusercontent.com/SizableShrimp/ForgeUpdatesRemapper/main/remapper.gradle'
// [The rest of your script]
Or like this:
plugins {
id 'net.minecraftforge.gradle' version '5.+'
id 'maven-publish'
}
apply from: 'https://raw.githubusercontent.com/SizableShrimp/ForgeUpdatesRemapper/main/remapper.gradle'
// [The rest of your script]
Now that the script is set up, we will run it. If you have multiple source sets, continue reading.
gradlew -PUPDATE_SRGS="https://gist.githubusercontent.com/amadornes/e00ea624b3cccc84fbca0800f651b546/raw/raw_mappings.tsrg;https://gist.githubusercontent.com/SizableShrimp/882a671ff74256d150776da08c89ef72/raw/forge_1.19_renames.tsrg" updateEverything
For more complex projects using multiple source sets, you will need to manually tell the script to update them. You can do this by adding -PUPDATE_SOURCESETS="<your source sets>"
before updateEverything
in the previous command, replacing <your source sets>
with a semicolon-separated list of target source sets.
For example, if you have main
and api
, your command would look like this:
gradlew -PUPDATE_SRGS="https://gist.githubusercontent.com/amadornes/e00ea624b3cccc84fbca0800f651b546/raw/raw_mappings.tsrg;https://gist.githubusercontent.com/SizableShrimp/882a671ff74256d150776da08c89ef72/raw/forge_1.19_renames.tsrg" -PUPDATE_SOURCESETS="main;api" updateEverything
At this point we're done with the script.
Remove the line you added to your buildscript earlier and update Forge to 1.19-41.0.94
or newer.
That's it! Everything that could be automatically updated, has been! 🎉
If you run into any issues, reach out via the Forge Discord: https://discord.gg/forge in the #modder-support-119
channel and someone will help you out.
Now you will likely need to manually make additional changes.
To aid with that, we have a manual porting guide and change list you can find at the following link:
<link is not ready yet>
Quick note if you're running this on Linux/Mac: you'll need to quote the pair of URL's like this (because of the semicolon):