User Tools

Site Tools


tutorial:migratemappings

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
tutorial:migratemappings [2025/10/31 21:04] – typo cassiancctutorial:migratemappings [2025/11/16 00:02] (current) cassiancc
Line 1: Line 1:
-:!: //A more thorough documentation of the process of migrating mappings, along with better, specific tooling is currently planned for the near future in order to help the transition into the non-obfuscated MC versionsThis page will likely redirect to the proper documentation once it is in a satisfying state.//+~~REDIRECT>https://docs.fabricmc.net/develop/migrating-mappings~~
  
 ====== Migrating to Yarn or Mojang Mappings in a Java codebase ====== ====== Migrating to Yarn or Mojang Mappings in a Java codebase ======
Line 7: Line 7:
 Loom does not support migrating code written in Kotlin. [[https://github.com/Deftu/ReplayMod-Remap|Third party tools]] are available. Loom does not support migrating code written in Kotlin. [[https://github.com/Deftu/ReplayMod-Remap|Third party tools]] are available.
  
-**Note:** This automated process does not yet handle Mixins or reflection. Updated tooling is currently in the works that will fix these errors. This tooling will be available before the mandatory switch to Mojang names in a future version of Minecraft.+**Note:** Loom 1.13 is required for this process to handle Mixins.
  
  
Line 18: Line 18:
   - Your migrated sources will appear in ''remappedSrc''. Verify that the migration produced valid migrated code.   - Your migrated sources will appear in ''remappedSrc''. Verify that the migration produced valid migrated code.
   - Copy the sources from ''remappedSrc'' to the original folder. Keep the original sources backed up just in case.   - Copy the sources from ''remappedSrc'' to the original folder. Keep the original sources backed up just in case.
-  - If you are coming from Yarn, you can now replace your mappings in your build.gradle with Mojang Mappings (i.e. mappings ''loom.officialMojangMappings()'').+  - If you are coming from Yarn, you can now replace your mappings in your ''build.gradle'''s dependencies section with Mojang Mappings (i.e. mappings ''loom.officialMojangMappings()'').
   - Refresh the Gradle project in your IDE.   - Refresh the Gradle project in your IDE.
   - Check and update any Mixin targets that may be outdated.   - Check and update any Mixin targets that may be outdated.
 +
 +Your dependencies section should now contain this:
 +
 +
 +    dependencies {
 +        [...]
 +        mappings loom.officialMojangMappings()
 +    }
 +
 +
  
 ===== Migrating to Yarn ===== ===== Migrating to Yarn =====
Line 30: Line 40:
   - Your migrated sources will appear in ''remappedSrc''. Verify that the migration produced valid migrated code.   - Your migrated sources will appear in ''remappedSrc''. Verify that the migration produced valid migrated code.
   - Copy the sources from ''remappedSrc'' to the original folder. Keep the original sources backed up just in case.   - Copy the sources from ''remappedSrc'' to the original folder. Keep the original sources backed up just in case.
-  - Update or add to your gradle.properties file with the Yarn version specified on [[https://fabricmc.net/develop|the Develop site]], i.e. ''yarn_mappings=1.21.10+build.2''+  - Update or add to your ''gradle.properties'' file with the Yarn version specified on [[https://fabricmc.net/develop|the Develop site]], i.e. ''yarn_mappings=1.21.10+build.2''
-  - If you are coming from Mojang Mappings, you can now replace your mappings in your build.gradle with Yarn's (i.e. ''mappings "net.fabricmc:yarn${project.yarn_mappings}:v2"'')+  - If you are coming from Mojang Mappings, you can now replace your mappings in your ''build.gradle'''s dependency section with Yarn's (i.e. ''mappings "net.fabricmc:yarn${project.yarn_mappings}:v2"'')
   - Refresh the Gradle project in your IDE.   - Refresh the Gradle project in your IDE.
   - Check and update any Mixin targets that may be outdated.   - Check and update any Mixin targets that may be outdated.
 +
 +Your dependencies section should now contain this, with the version of Yarn you are using specified in your ''gradle.properties'':
 +
 +    dependencies {
 +        [...]
 +        mappings "net.fabricmc:yarn:${project.yarn_mappings}:v2"
 +    }
 +
 +=== Migrating Split Sources ===
 +
 +At this time, users of split sources currently need to migrate their main source set with the process above, then do the process again, specifying the path to their client source set. As a reference, the command to migrate a client source set to Mojang Mappings is below.
  
  
 +    migrateMappings --mappings "net.minecraft:mappings:1.21.10" --input src/client/java
  
 === Additional customization ===  === Additional customization === 
tutorial/migratemappings.1761944648.txt.gz · Last modified: 2025/10/31 21:04 by cassiancc