minecraft-fabric-dev by mcdxai/meteor-rejects-v2
npx skills add https://github.com/mcdxai/meteor-rejects-v2 --skill minecraft-fabric-dev本技能为使用 Fabric 进行 Minecraft 模组开发提供全面指导,包括从其他模组加载器(Forge、NeoForge)移植。它集成了三个 MCP 服务器,为模组开发提供完整的工具链。
核心 Minecraft 开发工具,用于源代码访问、反编译和分析。
访问官方 Fabric 文档,包含特定版本的内容。
Baritone 寻路库文档(适用于 AI/自动化模组)。
开始任何 Minecraft 开发任务时:
首先同步文档:
sync_fabric_docs (force: false) → 获取最新的 Fabric 文档
baritone_refresh_docs → 如果需要,获取 Baritone 文档
确定目标版本:
list_fabric_versions → 查看可用的 Fabric 版本
list_minecraft_versions → 查看可用/缓存的 Minecraft 版本
反编译目标版本(如果需要):
decompile_minecraft_version (version, mapping: "yarn", force: false)
广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
映射类型(Fabric 的优先级顺序):
何时使用每种映射:
未来兼容性说明: 从 1.21.11 之后的实验性快照开始,Minecraft 正在发布去混淆的构建版本。最终,"official" 映射将包含人类可读的名称,而不是混淆后的名称(a, b, c)。MCP 服务器已为此过渡做好准备。当这成为标准时:
当前状态(1.21.11 及更早版本): Official = 混淆的,开发时使用 yarn/mojmap 未来状态(实验性快照及以后): Official = 去混淆的,为保持 Fabric 一致性仍建议使用 yarn
从 1.21.11 之后的实验性快照版本开始,Minecraft 正在发布去混淆的构建版本。这是一个逐步过渡的过程,最终将成为所有 Minecraft 发布版本的标准。
这意味着:
a、b、c 这样的混淆名称对于新版本(去混淆的):
对于旧版本(1.21.11 及更早):
minecraft-dev-mcp 服务器已经具备未来兼容性:
您无需担心的事项:
为了最大兼容性:
# 对于 Fabric 开发,仍然使用 yarn 作为主要映射
decompile_minecraft_version (version: "1.21.11", mapping: "yarn")
decompile_minecraft_version (version: "1.22-experimental", mapping: "yarn")
# 两者工作方式相同,服务器处理差异
跨版本边界工作时:
# 比较旧(混淆)和新(去混淆)版本
compare_versions (
fromVersion: "1.21.11", # 混淆的官方映射
toVersion: "1.22", # 去混淆的官方映射
mapping: "yarn" # 两者间一致的命名
)
为何仍使用 Yarn/Mojmap:
无需采取行动:
可选优化:
工具自动处理版本类型:
# 对混淆和去混淆版本都有效
get_minecraft_source (version, className, mapping: "yarn")
# 服务器内部检测:
# - 此版本是否混淆? → 应用传统的去混淆
# - 此版本是否去混淆? → 使用直接映射转换
您永远不需要手动指定混淆状态。
工作流程:
Step 1: 查找类
→ search_fabric_docs (query: "entity", mcVersion: "latest")
→ search_minecraft_code (version, query: "Entity", searchType: "class", mapping: "yarn")
Step 2: 获取源代码
→ get_minecraft_source (version, className: "net.minecraft.entity.Entity", mapping: "yarn")
Step 3: 获取文档上下文
→ get_documentation (className: "Entity")
→ get_fabric_doc (path: "develop/entities.md", mcVersion: "latest")
最佳实践:
基本工作流程:
Step 1: 理解目标
→ get_minecraft_source (version, className: "[target]", mapping: "yarn")
→ get_fabric_doc (path: "develop/mixins.md", mcVersion: "latest")
Step 2: 编写 mixin 代码
[用户基于源代码 + 文档编写 mixin]
Step 3: 验证 mixin
→ analyze_mixin (source: "[mixin code]", mcVersion: "[version]", mapping: "yarn")
Step 4: 修复问题
[审查验证结果,进行更正]
→ analyze_mixin (source: "[updated code]", mcVersion: "[version]", mapping: "yarn")
关键规则:
验证失败时:
工作流程:
Step 1: 确定需要拓宽访问权限的内容
→ get_minecraft_source (version, className: "[class]", mapping: "yarn")
[检查字段/方法可见性]
Step 2: 创建访问拓宽文件
[使用正确的语法编写 .accesswidener 文件]
Step 3: 验证
→ validate_access_widener (content: "[file content]", mcVersion: "[version]", mapping: "yarn")
Step 4: 根据验证结果应用修复
[根据验证结果更新]
访问拓宽语法:
accessWidener v2 named
accessible class net/minecraft/class/Name
accessible method net/minecraft/class/Name methodName (Lparams;)Lreturn;
accessible field net/minecraft/class/Name fieldName Ltype;
extendable class net/minecraft/class/Name
mutable field net/minecraft/class/Name fieldName Ltype;
用于理解/移植:
Step 1: 提取模组元数据
→ analyze_mod_jar (jarPath: "[path]", includeAllClasses: false, includeRawMetadata: true)
Step 2: 检查 mixin(如果存在)
→ analyze_mixin (source: "[jar path]", mcVersion: "[version]", mapping: "yarn")
Step 3: 检查依赖项和入口点
[审查步骤 1 的元数据]
Step 4: 如果需要,进行反编译/重映射
→ remap_mod_jar (inputJar, outputJar, mcVersion, toMapping: "yarn")
路径规范化:
/mnt/c/...) 和 Windows (C:\...) 两种路径格式比较 Minecraft 版本:
Step 1: 获取高级概览
→ compare_versions (fromVersion, toVersion, mapping: "yarn", category: "all")
Step 2: 详细的 API 变更
→ compare_versions_detailed (fromVersion, toVersion, mapping: "yarn",
packages: ["net.minecraft.entity", "net.minecraft.world"], maxClasses: 500)
Step 3: 检查注册表变更
→ get_registry_data (version: "[old]", registry: "blocks")
→ get_registry_data (version: "[new]", registry: "blocks")
Step 4: 搜索特定变更
→ search_fabric_docs (query: "migration [version]", mcVersion: "all")
破坏性变更检查清单:
全面的移植工作流程:
Step 1: 分析 Forge 模组
→ analyze_mod_jar (jarPath: "[forge-mod.jar]", includeAllClasses: true, includeRawMetadata: true)
Step 2: 理解 Forge 特定代码
[审查:@Mod 注解、事件处理器、能力系统、客户端/服务端代理]
Step 3: 寻找 Fabric 等效方案
→ search_fabric_docs (query: "[forge concept]", mcVersion: "latest")
→ get_fabric_doc (path: "develop/[topic].md", mcVersion: "latest")
Step 4: 映射常见模式
Forge 事件 → Fabric 事件(不同的注册方式)
能力系统 → Cardinal Components API 或自定义解决方案
@Mod 注解 → fabric.mod.json
FMLJavaModLoadingContext → Fabric Mod 初始化器
DeferredRegister → 在 onInitialize 中使用 Registry.register
Step 5: 检查 Minecraft 版本兼容性
→ get_minecraft_source (version, className: "[needed class]", mapping: "yarn")
→ compare_versions (fromVersion: "[forge ver]", toVersion: "[fabric ver]", mapping: "yarn")
Step 6: 验证转换后的 mixin
[如果 Forge 模组使用 CoreMods/ASM]
→ analyze_mixin (source: "[converted mixin]", mcVersion, mapping: "yarn")
Forge → Fabric 翻译模式:
| Forge 模式 | Fabric 等效方案 |
|---|---|
@Mod 类 | fabric.mod.json 中的 ModInitializer 接口 |
MinecraftForge.EVENT_BUS.register() | 在相应类中的事件回调 |
@SubscribeEvent | 使用事件直接注册方法 |
| 能力系统 | Cardinal Components API(单独的库) |
@ObjectHolder | 直接调用 Registry.register() |
| 配置 (ForgeConfig) | Cloth Config API 或自定义解决方案 |
@OnlyIn(Dist.CLIENT) | fabric.mod.json 中的 client 入口点 |
| 网络数据包 (SimpleChannel) | Fabric Networking API |
@Mod.EventBusSubscriber | ClientModInitializer / DedicatedServerModInitializer |
关键的 Fabric 特定要求:
fabric.mod.json 替换 mods.tomlmodid.mixins.json)需要在整个代码库中查找模式时:
Step 1: 索引版本(一次性操作,启用快速搜索)
→ index_minecraft_version (version, mapping: "yarn")
Step 2: 快速全文搜索
→ search_indexed (query: "entity damage", version, mapping: "yarn",
types: ["method", "field"], limit: 100)
替代方案:直接搜索(较慢,无需索引)
→ search_minecraft_code (version, query: "damage", searchType: "all",
mapping: "yarn", limit: 50)
搜索类型指南:
"class" - 类名匹配"method" - 方法定义"field" - 字段声明"content" - 任何代码内容"all" - 所有内容使用场景:您有一个混淆名称,需要找到对应的 yarn 名称(旧版本):
find_mapping (symbol: "a", version: "1.21.11", sourceMapping: "official", targetMapping: "yarn")
find_mapping (symbol: "Entity", version: "1.21.11", sourceMapping: "mojmap", targetMapping: "yarn")
find_mapping (symbol: "class_1234", version: "1.21.11", sourceMapping: "intermediary", targetMapping: "yarn")
使用场景:去混淆的发布版本(1.22+ 实验性):
# 官方名称现在可读,但为了保持一致性,仍可转换为 yarn
find_mapping (symbol: "Entity", version: "1.22", sourceMapping: "official", targetMapping: "yarn")
find_mapping (symbol: "LivingEntity", version: "1.22", sourceMapping: "official", targetMapping: "intermediary")
返回:
跨版本映射:
# 在混淆/去混淆边界上工作
find_mapping (symbol: "Entity", version: "1.21.11", sourceMapping: "yarn", targetMapping: "yarn")
find_mapping (symbol: "Entity", version: "1.22", sourceMapping: "yarn", targetMapping: "yarn")
# 即使官方格式发生变化,yarn 也能提供一致性
用于方块、物品、实体等:
# 获取所有注册表
get_registry_data (version, registry: undefined)
# 获取特定注册表
get_registry_data (version, registry: "blocks")
get_registry_data (version, registry: "items")
get_registry_data (version, registry: "entities")
get_registry_data (version, registry: "biomes")
使用场景:
Fabric 文档 - 优先级 1:
# 功能实现
search_fabric_docs (query: "custom blocks", mcVersion: "latest", limit: 15)
get_fabric_doc (path: "develop/blocks.md", mcVersion: "latest")
# 概念学习
list_fabric_sections (mcVersion: "latest")
get_fabric_doc_headings (path: "develop/mixins.md", mcVersion: "latest")
Minecraft 源代码 - 优先级 2:
# 需要查看原版实现方式时
get_minecraft_source (version, className: "BlockItem", mapping: "yarn")
search_minecraft_code (version, query: "registerBlock", searchType: "method", mapping: "yarn")
Baritone 文档 - 优先级 3(AI/寻路特定):
# 仅用于寻路/AI 模组
baritone_search_docs (query: "GoalBlock")
baritone_read_doc (path: "baritone/api/pathing/goals/GoalBlock.md")
"未找到反编译的源代码" → 首先运行 decompile_minecraft_version
"Mixin 验证失败" → 检查目标类是否存在:get_minecraft_source → 验证方法签名是否完全匹配 → 确保使用 yarn 映射
"未找到文档" → 运行 sync_fabric_docs (Fabric) → 运行 baritone_refresh_docs (Baritone)
"无效的映射类型" → Fabric 始终使用 "yarn"(不是 mojmap)→ 使用 find_mapping 检查可用的映射
"未找到路径"(模组分析) → 检查路径格式(支持 WSL 和 Windows)→ 验证指定位置是否存在文件 → 使用规范化路径(自动转换)
在声明代码完成之前,始终进行验证:
analyze_mixinvalidate_access_widenercompare_versionsget_registry_data用户想要...
├─ 理解 Minecraft 代码
│ ├─ 查找一个类 → search_minecraft_code (searchType: "class")
│ ├─ 查看实现 → get_minecraft_source
│ └─ 查找所有用法 → search_indexed (索引后)
│
├─ 学习 Fabric 概念
│ ├─ 浏览主题 → list_fabric_sections
│ ├─ 搜索功能 → search_fabric_docs
│ └─ 阅读完整指南 → get_fabric_doc
│
├─ 编写一个 mixin
│ ├─ 获取目标类 → get_minecraft_source
│ ├─ 检查 Fabric mixin 文档 → get_fabric_doc (path: "develop/mixins.md")
│ └─ 验证 mixin → analyze_mixin
│
├─ 访问私有成员
│ ├─ 检查存在的内容 → get_minecraft_source
│ ├─ 编写访问拓宽器 → [用户编写]
│ └─ 验证 → validate_access_widener
│
├─ 移植一个模组
│ ├─ 分析原始模组 → analyze_mod_jar
│ ├─ 检查 Forge→Fabric 模式 → search_fabric_docs
│ ├─ 比较 MC 版本 → compare_versions_detailed
│ └─ 验证转换后的代码 → analyze_mixin
│
├─ 为新版本更新
│ ├─ 高级变更 → compare_versions
│ ├─ 详细的 API 差异 → compare_versions_detailed
│ ├─ 注册表变更 → get_registry_data (两个版本)
│ └─ 迁移指南 → search_fabric_docs (query: "migration")
│
└─ 理解映射
├─ 翻译混淆名称 → find_mapping
├─ 查看所有映射 → 工具中列出可用映射
└─ 在系统间转换 → find_mapping
始终包含:
模板:
// 您的 mixin 代码放在这里
验证:
analyze_mixin (source: "[above code]", mcVersion: "1.21.11", mapping: "yarn")
重要: 在生产环境中使用之前,请在开发环境中测试。
模板:
accessWidener v2 named
[entries here]
验证:
validate_access_widener (content: "[above content]", mcVersion: "1.21.11", mapping: "yarn")
提供:
何时索引:
何时跳过索引:
索引命令:
index_minecraft_version (version, mapping: "yarn")
这些会被缓存(首次运行后快速):
decompile_minecraft_versionget_minecraft_sourceget_registry_data这些不会被缓存(始终新鲜):
search_minecraft_code(除非已索引)analyze_mixinvalidate_access_widenercompare_versions检查可用版本:
list_minecraft_versions → 查看可用的版本
list_fabric_versions → 查看 Fabric 支持的版本
典型工作流程:
list_minecraft_versionslist_fabric_versionsdecompile_minecraft_version混淆时代(≤1.21.11):
去混淆时代(1.22+ 实验性快照):
过渡期:
在混淆/去混淆边界上工作时:
# 使用 yarn 在版本间保持一致的名称
decompile_minecraft_version (version: "1.21.11", mapping: "yarn")
decompile_minecraft_version (version: "1.22-experimental", mapping: "yarn")
# 安全地比较版本
compare_versions_detailed (
fromVersion: "1.21.11", # 混淆的
toVersion: "1.22", # 去混淆的
mapping: "yarn" # 两者间保持一致
)
最佳实践: 无论目标版本的混淆状态如何,始终为 Fabric 开发使用 yarn。
当用户提到版本 1.22+ 或实验性快照时:
用户请求: "创建一个防止摔落伤害的 mixin"
响应模式:
让我帮您为 Fabric 创建一个防止摔落伤害的 mixin。
Step 1: 理解原版实现
[获取 LivingEntity 中摔落伤害逻辑的源代码]
Step 2: 检查 Fabric mixin 文档
[获取 mixin 指南的 Fabric 文档]
Step 3: 创建 mixin
[带有正确导入和结构的完整 mixin 代码]
Step 4: 验证(关键 - 运行这个!)
analyze_mixin (
source: "[上面的 mixin 代码]",
mcVersion: "1.21.11",
mapping: "yarn"
)
这个 mixin 注入到摔落伤害方法中并取消它。@Inject 注解定位负责应用摔落伤害的方法,我们使用 cancellable = true 来允许防止伤害。
重要说明:
- 首先在创造模式世界测试
- 可能与其他摔落伤害模组冲突
- 影响所有实体,不仅仅是玩家
模式: fabric://docs/{path}
示例:
fabric://docs/develop/getting-started.md
fabric://docs/develop/mixins.md
fabric://docs/items/custom-item.md
访问方式:
get_fabric_doc 工具模式: minecraft://source/{version}/{mapping}/{className}
示例:
minecraft://source/1.21.1/yarn/net.minecraft.entity.Entity
minecraft://source/1.21.1/mojmap/net.minecraft.world.level.Level
也可用:
minecraft://mappings/{version}/{mapping}minecraft://registry/{version}/{registryType}minecraft://versions/listminecraft://index/{version}/{mapping}在建议解决方案完成之前,请验证:
初始设置:
sync_fabric_docs
list_minecraft_versions
decompile_minecraft_version (version: "1.21.11", mapping: "yarn")
开发:
get_fabric_doc (path: "develop/[topic].md")
get_minecraft_source (version, className, mapping: "yarn")
analyze_mixin (source, mcVersion, mapping: "yarn")
分析:
analyze_mod_jar (jarPath)
compare_versions (fromVersion, toVersion, mapping: "yarn")
search_minecraft_code (version, query, searchType: "all", mapping: "yarn")
验证:
analyze_mixin (source, mcVersion, mapping: "yarn")
validate_access_widener (content, mcVersion, mapping: "yarn")
本技能使用所有可用的 MCP 工具,全面覆盖了 Minecraft Fabric 模组开发的工作流程。
每周安装数
74
仓库
GitHub 星标数
6
首次出现
2026年1月24日
安全审计
安装于
codex66
opencode64
gemini-cli62
github-copilot61
cursor55
kimi-cli52
This skill provides comprehensive guidance for Minecraft mod development with Fabric, including porting from other mod loaders (Forge, NeoForge). It integrates three MCP servers to provide complete tooling for mod development.
Core Minecraft development tools for source code access, decompilation, and analysis.
Official Fabric documentation access with version-specific content.
Baritone pathfinding library documentation (useful for AI/automation mods).
When starting ANY Minecraft development task:
Sync documentation first:
sync_fabric_docs (force: false) → Get latest Fabric docs
baritone_refresh_docs → Get Baritone docs if needed
Identify target version:
list_fabric_versions → See available Fabric versions
list_minecraft_versions → See available/cached Minecraft versions
Decompile target version (if needed):
decompile_minecraft_version (version, mapping: "yarn", force: false)
Mapping Types (in priority order for Fabric):
When to use each:
Future-Proofing Note: Starting with experimental snapshots after 1.21.11, Minecraft is releasing de-obfuscated builds. Eventually, the "official" mapping will contain human-readable names instead of obfuscated ones (a, b, c). The MCP server is already prepared for this transition. When this becomes standard:
Current State (1.21.11 and earlier): Official = obfuscated, use yarn/mojmap for development Future State (experimental snapshots+): Official = de-obfuscated, still prefer yarn for Fabric consistency
Starting with experimental snapshots after version 1.21.11, Minecraft is releasing de-obfuscated builds. This is a gradual transition that will eventually become the standard for all Minecraft releases.
What This Means:
a, b, c in official releasesFor New Versions (De-obfuscated):
For Legacy Versions (1.21.11 and earlier):
The minecraft-dev-mcp server is already future-proof:
What You Don't Need to Worry About:
For Maximum Compatibility:
# Still use yarn as primary for Fabric development
decompile_minecraft_version (version: "1.21.11", mapping: "yarn")
decompile_minecraft_version (version: "1.22-experimental", mapping: "yarn")
# Both work identically, server handles the difference
When Working Across Version Boundaries:
# Comparing old (obfuscated) to new (de-obfuscated)
compare_versions (
fromVersion: "1.21.11", # Obfuscated official
toVersion: "1.22", # De-obfuscated official
mapping: "yarn" # Consistent naming across both
)
Why Still Use Yarn/Mojmap:
No Action Required:
Optional Optimizations:
The tools automatically handle version type:
# Works for both obfuscated and de-obfuscated
get_minecraft_source (version, className, mapping: "yarn")
# Server internally detects:
# - Is this version obfuscated? → Apply traditional deobfuscation
# - Is this version de-obfuscated? → Use direct mapping translation
You never need to specify obfuscation state manually.
Workflow:
Step 1: Find the class
→ search_fabric_docs (query: "entity", mcVersion: "latest")
→ search_minecraft_code (version, query: "Entity", searchType: "class", mapping: "yarn")
Step 2: Get source code
→ get_minecraft_source (version, className: "net.minecraft.entity.Entity", mapping: "yarn")
Step 3: Get documentation context
→ get_documentation (className: "Entity")
→ get_fabric_doc (path: "develop/entities.md", mcVersion: "latest")
Best practices:
Essential workflow:
Step 1: Understand the target
→ get_minecraft_source (version, className: "[target]", mapping: "yarn")
→ get_fabric_doc (path: "develop/mixins.md", mcVersion: "latest")
Step 2: Write mixin code
[User writes mixin based on source + docs]
Step 3: Validate mixin
→ analyze_mixin (source: "[mixin code]", mcVersion: "[version]", mapping: "yarn")
Step 4: Fix issues
[Review validation results, make corrections]
→ analyze_mixin (source: "[updated code]", mcVersion: "[version]", mapping: "yarn")
Critical rules:
When validation fails:
Workflow:
Step 1: Identify what needs widening
→ get_minecraft_source (version, className: "[class]", mapping: "yarn")
[Check field/method visibility]
Step 2: Create access widener file
[Write .accesswidener with proper syntax]
Step 3: Validate
→ validate_access_widener (content: "[file content]", mcVersion: "[version]", mapping: "yarn")
Step 4: Apply fixes from validation
[Update based on validation results]
Access widener syntax:
accessWidener v2 named
accessible class net/minecraft/class/Name
accessible method net/minecraft/class/Name methodName (Lparams;)Lreturn;
accessible field net/minecraft/class/Name fieldName Ltype;
extendable class net/minecraft/class/Name
mutable field net/minecraft/class/Name fieldName Ltype;
For understanding/porting:
Step 1: Extract mod metadata
→ analyze_mod_jar (jarPath: "[path]", includeAllClasses: false, includeRawMetadata: true)
Step 2: Examine mixins (if present)
→ analyze_mixin (source: "[jar path]", mcVersion: "[version]", mapping: "yarn")
Step 3: Check dependencies and entry points
[Review metadata from Step 1]
Step 4: Decompile/remap if needed
→ remap_mod_jar (inputJar, outputJar, mcVersion, toMapping: "yarn")
Path normalization:
/mnt/c/...) and Windows (C:\...) pathsComparing Minecraft versions:
Step 1: Get high-level overview
→ compare_versions (fromVersion, toVersion, mapping: "yarn", category: "all")
Step 2: Detailed API changes
→ compare_versions_detailed (fromVersion, toVersion, mapping: "yarn",
packages: ["net.minecraft.entity", "net.minecraft.world"], maxClasses: 500)
Step 3: Check registry changes
→ get_registry_data (version: "[old]", registry: "blocks")
→ get_registry_data (version: "[new]", registry: "blocks")
Step 4: Search for specific changes
→ search_fabric_docs (query: "migration [version]", mcVersion: "all")
Breaking changes checklist:
Comprehensive porting workflow:
Step 1: Analyze Forge mod
→ analyze_mod_jar (jarPath: "[forge-mod.jar]", includeAllClasses: true, includeRawMetadata: true)
Step 2: Understand Forge-specific code
[Review: @Mod annotations, event handlers, capability system, sided proxies]
Step 3: Find Fabric equivalents
→ search_fabric_docs (query: "[forge concept]", mcVersion: "latest")
→ get_fabric_doc (path: "develop/[topic].md", mcVersion: "latest")
Step 4: Map common patterns
Forge Events → Fabric Events (different registration)
Capabilities → Cardinal Components API or custom solution
@Mod annotation → fabric.mod.json
FMLJavaModLoadingContext → Fabric Mod Initializer
DeferredRegister → Registry.register in onInitialize
Step 5: Check Minecraft version compatibility
→ get_minecraft_source (version, className: "[needed class]", mapping: "yarn")
→ compare_versions (fromVersion: "[forge ver]", toVersion: "[fabric ver]", mapping: "yarn")
Step 6: Validate converted mixins
[If Forge mod uses CoreMods/ASM]
→ analyze_mixin (source: "[converted mixin]", mcVersion, mapping: "yarn")
Forge → Fabric translation patterns:
| Forge Pattern | Fabric Equivalent |
|---|---|
@Mod class | ModInitializer interface in fabric.mod.json |
MinecraftForge.EVENT_BUS.register() | Event callbacks in respective classes |
@SubscribeEvent | Direct method registration with event |
| Capabilities | Cardinal Components API (separate library) |
@ObjectHolder | Direct Registry.register() calls |
| Config (ForgeConfig) |
Critical Fabric-specific requirements:
fabric.mod.json replaces mods.tomlmodid.mixins.json)When you need to find patterns across entire codebase:
Step 1: Index the version (one-time, enables fast search)
→ index_minecraft_version (version, mapping: "yarn")
Step 2: Fast full-text search
→ search_indexed (query: "entity damage", version, mapping: "yarn",
types: ["method", "field"], limit: 100)
Alternative: Direct search (slower, no index needed)
→ search_minecraft_code (version, query: "damage", searchType: "all",
mapping: "yarn", limit: 50)
Search type guide:
"class" - Class name matching"method" - Method definitions"field" - Field declarations"content" - Any code content"all" - EverythingUse case: You have an obfuscated name and need the yarn name (legacy versions):
find_mapping (symbol: "a", version: "1.21.11", sourceMapping: "official", targetMapping: "yarn")
find_mapping (symbol: "Entity", version: "1.21.11", sourceMapping: "mojmap", targetMapping: "yarn")
find_mapping (symbol: "class_1234", version: "1.21.11", sourceMapping: "intermediary", targetMapping: "yarn")
Use case: De-obfuscated releases (1.22+ experimental):
# Official names are now readable, but still translate to yarn for consistency
find_mapping (symbol: "Entity", version: "1.22", sourceMapping: "official", targetMapping: "yarn")
find_mapping (symbol: "LivingEntity", version: "1.22", sourceMapping: "official", targetMapping: "intermediary")
Returns:
Cross-version mapping:
# Works across obfuscated/de-obfuscated boundary
find_mapping (symbol: "Entity", version: "1.21.11", sourceMapping: "yarn", targetMapping: "yarn")
find_mapping (symbol: "Entity", version: "1.22", sourceMapping: "yarn", targetMapping: "yarn")
# Yarn provides consistency even as official format changes
For blocks, items, entities, etc.:
# Get all registries
get_registry_data (version, registry: undefined)
# Get specific registry
get_registry_data (version, registry: "blocks")
get_registry_data (version, registry: "items")
get_registry_data (version, registry: "entities")
get_registry_data (version, registry: "biomes")
Use cases:
Fabric Docs - Priority 1:
# Feature implementation
search_fabric_docs (query: "custom blocks", mcVersion: "latest", limit: 15)
get_fabric_doc (path: "develop/blocks.md", mcVersion: "latest")
# Concept learning
list_fabric_sections (mcVersion: "latest")
get_fabric_doc_headings (path: "develop/mixins.md", mcVersion: "latest")
Minecraft Source - Priority 2:
# When you need to see how vanilla does it
get_minecraft_source (version, className: "BlockItem", mapping: "yarn")
search_minecraft_code (version, query: "registerBlock", searchType: "method", mapping: "yarn")
Baritone Docs - Priority 3 (AI/pathfinding specific):
# Only for pathfinding/AI mods
baritone_search_docs (query: "GoalBlock")
baritone_read_doc (path: "baritone/api/pathing/goals/GoalBlock.md")
"Decompiled source not found" → Run decompile_minecraft_version first
"Mixin validation failed" → Check target class exists: get_minecraft_source → Verify method signatures match exactly → Ensure using yarn mappings
"Documentation not found" → Run sync_fabric_docs (Fabric) → Run baritone_refresh_docs (Baritone)
"Invalid mapping type" → Fabric ALWAYS uses "yarn" (not mojmap) → Check available mappings with find_mapping
"Path not found" (mod analysis) → Check path format (both WSL and Windows supported) → Verify file exists at specified location → Use normalized paths (auto-converted)
ALWAYS validate before suggesting code is complete:
analyze_mixinvalidate_access_widenercompare_versionsget_registry_dataUser wants to...
├─ Understand Minecraft code
│ ├─ Find a class → search_minecraft_code (searchType: "class")
│ ├─ See implementation → get_minecraft_source
│ └─ Find all usages → search_indexed (after indexing)
│
├─ Learn Fabric concepts
│ ├─ Browse topics → list_fabric_sections
│ ├─ Search for feature → search_fabric_docs
│ └─ Read full guide → get_fabric_doc
│
├─ Write a mixin
│ ├─ Get target class → get_minecraft_source
│ ├─ Check Fabric mixin docs → get_fabric_doc (path: "develop/mixins.md")
│ └─ Validate mixin → analyze_mixin
│
├─ Access private members
│ ├─ Check what exists → get_minecraft_source
│ ├─ Write access widener → [user writes]
│ └─ Validate → validate_access_widener
│
├─ Port a mod
│ ├─ Analyze original → analyze_mod_jar
│ ├─ Check Forge→Fabric patterns → search_fabric_docs
│ ├─ Compare MC versions → compare_versions_detailed
│ └─ Validate converted code → analyze_mixin
│
├─ Update for new version
│ ├─ High-level changes → compare_versions
│ ├─ Detailed API diff → compare_versions_detailed
│ ├─ Registry changes → get_registry_data (both versions)
│ └─ Migration guide → search_fabric_docs (query: "migration")
│
└─ Understand mappings
├─ Translate obfuscated → find_mapping
├─ See all mappings → List available in tool
└─ Convert between systems → find_mapping
ALWAYS include:
Template:
// Your mixin code here
Validation:
analyze_mixin (source: "[above code]", mcVersion: "1.21.11", mapping: "yarn")
Important: Test this in a development environment before using in production.
Template:
accessWidener v2 named
[entries here]
Validation:
validate_access_widener (content: "[above content]", mcVersion: "1.21.11", mapping: "yarn")
Provide:
When to index:
When to skip indexing:
Index command:
index_minecraft_version (version, mapping: "yarn")
These are cached (fast after first run):
decompile_minecraft_versionget_minecraft_sourceget_registry_dataThese are not cached (always fresh):
search_minecraft_code (unless indexed)analyze_mixinvalidate_access_widenercompare_versionsCheck available versions:
list_minecraft_versions → See what's available
list_fabric_versions → See what Fabric supports
Typical workflow:
list_minecraft_versionslist_fabric_versionsdecompile_minecraft_versionObfuscated Era (≤1.21.11):
De-obfuscated Era (1.22+ experimental snapshots):
Transition Period:
When working across obfuscated/de-obfuscated boundary:
# Use yarn for consistent names across versions
decompile_minecraft_version (version: "1.21.11", mapping: "yarn")
decompile_minecraft_version (version: "1.22-experimental", mapping: "yarn")
# Compare versions safely
compare_versions_detailed (
fromVersion: "1.21.11", # Obfuscated
toVersion: "1.22", # De-obfuscated
mapping: "yarn" # Consistent across both
)
Best Practice: Always use yarn for Fabric development regardless of target version's obfuscation state.
When user mentions version 1.22+ or experimental snapshots:
User Request: "Create a mixin to prevent fall damage"
Response Pattern:
Let me help you create a fall damage prevention mixin for Fabric.
Step 1: Understanding the vanilla implementation
[get_minecraft_source for LivingEntity with fall damage logic]
Step 2: Checking Fabric mixin documentation
[get_fabric_doc for mixins guide]
Step 3: Creating the mixin
[Full mixin code with proper imports and structure]
Step 4: Validation (CRITICAL - run this!)
analyze_mixin (
source: "[mixin code above]",
mcVersion: "1.21.11",
mapping: "yarn"
)
This mixin injects into the fall damage method and cancels it. The @Inject annotation targets the method responsible for applying fall damage, and we use cancellable = true to allow preventing the damage.
Important notes:
- Test in creative world first
- May conflict with other fall damage mods
- Affects all entities, not just players
Pattern: fabric://docs/{path}
Example:
fabric://docs/develop/getting-started.md
fabric://docs/develop/mixins.md
fabric://docs/items/custom-item.md
Access via:
get_fabric_doc toolPattern: minecraft://source/{version}/{mapping}/{className}
Example:
minecraft://source/1.21.1/yarn/net.minecraft.entity.Entity
minecraft://source/1.21.1/mojmap/net.minecraft.world.level.Level
Also available:
minecraft://mappings/{version}/{mapping}minecraft://registry/{version}/{registryType}minecraft://versions/listminecraft://index/{version}/{mapping}Before suggesting a solution is complete, verify:
Initial Setup:
sync_fabric_docs
list_minecraft_versions
decompile_minecraft_version (version: "1.21.11", mapping: "yarn")
Development:
get_fabric_doc (path: "develop/[topic].md")
get_minecraft_source (version, className, mapping: "yarn")
analyze_mixin (source, mcVersion, mapping: "yarn")
Analysis:
analyze_mod_jar (jarPath)
compare_versions (fromVersion, toVersion, mapping: "yarn")
search_minecraft_code (version, query, searchType: "all", mapping: "yarn")
Validation:
analyze_mixin (source, mcVersion, mapping: "yarn")
validate_access_widener (content, mcVersion, mapping: "yarn")
This skill provides complete coverage of Minecraft Fabric mod development workflows using all available MCP tools.
Weekly Installs
74
Repository
GitHub Stars
6
First Seen
Jan 24, 2026
Security Audits
Gen Agent Trust HubPassSocketPassSnykWarn
Installed on
codex66
opencode64
gemini-cli62
github-copilot61
cursor55
kimi-cli52
agent-browser 浏览器自动化工具 - Vercel Labs 命令行网页操作与测试
163,300 周安装
Edge Candidate Agent:自动化交易策略生成与验证工具,将市场观察转化为可执行策略
144 周安装
系统设计技能:基于整洁架构与DDD的软件架构开发最佳实践指南
103 周安装
OnchainKit 区块链开发SDK:构建链上应用的身份、钱包、交易组件
104 周安装
YouTube API 替代方案:无需配额获取字幕、搜索和频道数据 | TranscriptAPI
106 周安装
AWS Cognito 身份验证与用户管理:Web/移动应用身份验证、授权、用户池、身份池详解
90 周安装
App Store 拒绝诊断与修复指南:9种模式系统化解决审核被拒问题
96 周安装
| Cloth Config API or custom solution |
@OnlyIn(Dist.CLIENT) | client entrypoint in fabric.mod.json |
| Network packets (SimpleChannel) | Fabric Networking API |
@Mod.EventBusSubscriber | ClientModInitializer / DedicatedServerModInitializer |