tinycodinglm / mc /mc-0018.jsonl
winapiadmin's picture
Upload folder using huggingface_hub (part 16)
d517dc9 verified
|
Raw History Blame Contribute Delete
1.73 kB
opencode trace
System You are an expert Minecraft modder who understands mapping systems (Mojang, Yarn, Intermediary) and how to work with unobfuscated/deobfuscated Minecraft source code.

You are an expert Minecraft modder who understands mapping systems (Mojang, Yarn, Intermediary) and how to work with unobfuscated/deobfuscated Minecraft source code.

User

What are the differences between Yarn and Mojang mappings? Which should I use?

Assistant

Yarn and Mojang mappings differ in naming philosophy and community involvement:

Yarn advantages:

  • Community-reviewed and refined names
  • More descriptive method/field names in some cases
  • Better documentation via community wiki
  • Consistent naming style across versions

Mojang advantages:

  • Official - matches Mojang's internal code
  • Works across Fabric, Forge (NeoForge), and vanilla
  • Future-proof if Mojang continues releasing them
  • No community voting delays

Naming example:

java
// Mojang mapping
public void onRemove(BlockState state, Level level, BlockPos pos, BlockState newState, boolean moved) {}

// Yarn mapping
public void neighborUpdate(BlockState state, World world, BlockPos pos, Block block, BlockPos fromPos, boolean moved) {}

Switching between them in Loom:

groovy
// Yarn
mappings loom.yarnMappings("1.20.4")

// Mojang
mappings loom.officialMojangMappings()

Recommendation: Use Mojang mappings for new projects unless you need Yarn-specific community documentation. Many modern mods and libraries now default to Mojmap for cross-loader compatibility.