高级 Minecraft 配方管理插件
广泛的配方支持 · 触发系统 · 脚本引擎 · GUI 界面 · 物品插件集成
为什么选择 Craftorithm
- 通过其他插件提供的物品 ID 匹配物品 —— 重命名、添加附魔甚至更改物品类型都不会影响合成
- 通过注入原版合成系统来实现功能 —— 性能远超依赖事件监听器的插件,并完全支持所有原版特性
- 禁用原版或其他插件的配方
- 结果处理器、触发器、自定义箱子菜单以及其他强大的自定义功能
功能特性
快速开始
要求
- Java: 21 或更高版本
- 服务器: Paper / Spigot 1.20+(支持 Folia)
安装
- 下载插件
- 将 JAR 文件放入
plugins/目录 - 重启服务器
创建你的第一个配方
/cra create vanilla_shaped
在 GUI 中放置原料和结果物品,然后点击确认。配方将自动保存至
plugins/Craftorithm/recipes/。
强大的配置
结果处理器
结果处理器允许你对合成结果应用额外的修改,例如:
result_processors:
enchantments:
type: copy_from_source
lore:
type: add
data:
value:
- "&7传奇武器"
- "&a在地狱中锻造"
attributes:
type: merge_source
支持对附魔、属性、描述文本、物品标志等多种组件类型使用 copy_from_source(从源复制)/ add(添加)/ merge_source(合并源)/ remove(移除)策略。
合成余料
remainders 控制每次合成后每个输入槽位留下什么。每条规则使用 action 来选择耐久度消耗、物品替换或保留原物:
remainders:
- ingredient: minecraft:flint_and_steel
action: damage
damage: 1
- ingredient: my_items:magic_water_bucket
action: replace
item: minecraft:iron_ingot 2
- ingredient: my_items:reusable_catalyst
action: keep
damage: 保留已消耗的物品并应用配置的耐久度伤害;耐久度耗尽时物品会消失。replace: 返回配置的item;数量遵循物品 ID(例如minecraft:iron_ingot 2),默认为 1。keep: 返回一个未改变的已消耗物品副本。- 原料使用与配方原料相同的 ID,包括原版 ID、自定义 ID、
tag:以及item_pack:。 - 没有匹配规则的槽位保留其原版余料。当多条规则匹配时,优先级最高的第一条生效。
世界隔离
enable_worlds 将配方限制在特定世界中。如果省略此项,则该配方在所有世界中可用:
# 单个世界
enable_worlds: world
# 多个世界
enable_worlds:
- world
- world_nether
- 世界名称为 Bukkit 世界名称,而非 Namespaced ID。
- 加载过程中,未知的世界会被报告为错误并被跳过。
- 没有
enable_worlds的配方不受限制。 - 目前适用于铁砧、酿造台和切石机配方。
文档
| 模块 | 描述 |
|---|---|
| 快速开始 | 安装、命令、权限 |
| 配方系统 | 多种配方类型的详解 |
| 触发系统 | 事件监听器和条件 |
| 脚本引擎 | 语法和内置函数 |
| 物品系统 | 自定义物品和外部插件 |
| 配置参考 | 配置说明 |
| UI 系统 | GUI 和自定义菜单 |
bStats
Advanced Minecraft Recipe Management Plugin
Extensive Recipe Support · Trigger System · Script Engine · GUI Interface · Item Plugin Integrations
Why Craftorithm
- Matches items by other plugin-provided item ID — renaming, adding enchantments, or even changing item types won't affect crafting
- Implements functionality by injecting into the vanilla crafting system — performance far surpasses plugins that rely on event listeners, with full support for all vanilla features
- Disable recipes from vanilla or other plugins
- Result processors, triggers, custom chest menus, and other powerful customization features
Features
Quick Start
Requirements
- Java: 21 or higher
- Server: Paper / Spigot 1.20+ (Folia supported)
Installation
- Downloa plugin
- Place the JAR file in the
plugins/directory - Restart the server
Create Your First Recipe
/cra create vanilla_shaped
Place ingredients and result items in the GUI, then click confirm. Recipes are automatically saved to
plugins/Craftorithm/recipes/.
Powerful Configuration
Result Processors
Result processors allow you to apply additional modifications to crafting results, for example:
result_processors:
enchantments:
type: copy_from_source
lore:
type: add
data:
value:
- "&7Legendary Weapon"
- "&aForged in the Nether"
attributes:
type: merge_source
Supports copy_from_source / add / merge_source / remove strategies for various component types including
enchantments, attributes, lore, item flags, and more.
Crafting Remainders
remainders controls what each crafting input slot leaves behind after a craft. Each rule uses action to select
durability damage, item replacement, or keeping the original item:
remainders:
- ingredient: minecraft:flint_and_steel
action: damage
damage: 1
- ingredient: my_items:magic_water_bucket
action: replace
item: minecraft:iron_ingot 2
- ingredient: my_items:reusable_catalyst
action: keep
damage: keeps the consumed item and applies the configured durability damage; it breaks when durability runs out.replace: returns the configureditem; the amount follows the item ID (for exampleminecraft:iron_ingot 2) and defaults to 1.keep: returns one unchanged copy of the consumed item.- Ingredients use the same IDs as recipe ingredients, including vanilla IDs, custom IDs,
tag:, anditem_pack:. - Slots without a matching rule keep their vanilla remainder. When multiple rules match, the first one wins.
World Isolation
enable_worlds restricts a recipe to specific worlds. When omitted, the recipe is available in every world:
# Single world
enable_worlds: world
# Multiple worlds
enable_worlds:
- world
- world_nether
- World names are Bukkit world names, not namespaced IDs.
- Unknown worlds are reported as errors during loading and skipped.
- Recipes without
enable_worldsare not restricted. - Currently applies to anvil, brewing, and stonecutting recipes.
Documentation
| Module | Description |
|---|---|
| Quick Start | Installation, commands, permissions |
| Recipe System | Multiple recipe types explained |
| Trigger System | Event listeners and conditions |
| Script Engine | Syntax and built-in functions |
| Item System | Custom items and external plugins |
| Configuration | Configuration reference |
| UI System | GUI and custom menus |
bStats
下载 Craftorithm
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Craftorithm
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Craftorithm
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Craftorithm
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Craftorithm
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Craftorithm
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
破坏性更新 | Breaking Changes
- API 事件
RecipeLoadFromConfigEvent更名为RecipeRegisterEvent,并新增reason()表示注册原因(RELOAD、NEW_RECIPE、EDIT_RECIPE),监听该事件的插件需要同步修改 | The API eventRecipeLoadFromConfigEventhas been renamed toRecipeRegisterEventand now exposesreason()(RELOAD,NEW_RECIPE,EDIT_RECIPE). Plugins listening to it need to be updated accordingly
更新内容 | Update Contents
- 配方新增
auto_discover选项,开启后该配方会在玩家进服、插件重载完成以及配方被新建或修改时自动解锁到配方书 | Added anauto_discoveroption to recipes. When enabled, the recipe is automatically discovered for players when they join, after a plugin reload completes, and when the recipe is created or edited - 配方创建页与编辑页新增「自动解锁配方书」开关,用于切换当前配方的
auto_discover| Added an "Auto-discover recipe book" toggle to the recipe creator and editor, flippingauto_discoverfor the current recipe - 新增 API 事件
CraftorithmReloadDoneEvent,在插件重载完成后异步触发 | Added the API eventCraftorithmReloadDoneEvent, fired asynchronously after the plugin finishes reloading
破坏性更新 | Breaking Changes
- 最低支持版本由 1.20 提升至 1.20.1,不再支持 1.20 | The minimum supported version is now 1.20.1; 1.20 is no longer supported
更新内容 | Update Contents
- 修复 1.20.3-1.21.1 版本下获取到的熔炉、高炉、烟熏炉与营火配方结果物品变成熔炉等图标物品的问题 | Fixed furnace, blast furnace, smoker and campfire recipes returning icon items such as the furnace as their result on 1.20.3-1.21.1
- 修复 1.21.6 版本的服务端因未匹配到正确的 NMS 实现导致所有配方都无法注册的问题 | Fixed all recipes failing to register on 1.21.6 because no matching NMS implementation was found
- 修复 1.21.5-1.21.8 的 Paper 服务端注册锻造转换配方(
vanilla_smithing_transform)时报NoSuchMethodError的问题 | Fixed aNoSuchMethodErrorwhen registering smithing transform recipes (vanilla_smithing_transform) on Paper 1.21.5-1.21.8 - 修复 1.21.5 及以上版本锻造纹饰配方(
vanilla_smithing_trim)的纹饰图案固定为 bolt 的问题 | Fixed smithing trim recipes (vanilla_smithing_trim) always using the bolt pattern on 1.21.5 and above - 修复 1.21.9-1.21.11 的 Paper 服务端重建配方数据时报
NoSuchMethodError的问题 | Fixed aNoSuchMethodErrorwhen rebuilding recipe data on Paper 1.21.9-1.21.11 - 修复 1.21.11 的 Spigot 服务端无法注册锻造转换配方(
vanilla_smithing_transform)的问题 | Fixed smithing transform recipes (vanilla_smithing_transform) failing to register on Spigot 1.21.11
更新内容
-
插件的开源协议由 GPL-3.0 更改为 MIT | The plugin license has changed from GPL-3.0 to MIT
-
结果处理器的取值现在支持脚本:数值、布尔与文本(
display_name、item_name、lore、skull_profile)都可以写成用<>包裹的脚本,例如value: '<random_int(0, 100)>',脚本中可使用player、source_item、result_item变量,详见结果处理器文档 | Result processor values now support scripts: numbers, booleans and text (display_name,item_name,lore,skull_profile) can be written as a script wrapped in<>, e.g.value: '<random_int(0, 100)>'. Scripts can use theplayer,source_itemandresult_itemvariables. See the result processor documentation for details -
skull_profile结果处理器新增add行为,可通过name/uuid给头颅写入玩家资料 -
新增结果处理器扩展 API,第三方插件可通过
CraftorithmApi#resultProcessor()注册新组件,或为已有组件追加行为 -
新增 PlaceholderAPI 变量
%craftorithm_discovered_craftorithm%,返回玩家已解锁的 Craftorithm 配方数量 -
修复通过自定义菜单与配方列表菜单打开编辑页面后,无法正确返回上一页的问题
-
修复属性结果处理器在 1.20.5 以下版本无法使用的问题 | Fixed attribute result processors not working below 1.20.5
更新内容
- 优化配方材料匹配性能
- 优化基于 lore 的材料限制规则的性能
- 优化在开启禁用全部原版配方的情况下的重载性能表现
- 优化配方相关命令的补全性能
更新内容
- 修复物品组中前向引用、多层嵌套引用与共享依赖引用无法解析的问题,并增加检测循环引用与无效引用 | Fixed item pack entries failing to resolve forward references, nested references and shared dependencies, and added detection for circular and invalid references
- 进一步修复内置物品源在同一物品保存为多个 id 时 id 重复、不稳定的问题;覆盖物品定义时不会再误匹配到其它物品 | Further fixed unstable/duplicate ids in the built-in item provider when the same item is saved under multiple ids; overwriting an item definition no longer matches other items by mistake
- 修复 Spigot 端下营火配方在一些情况下出现异常的问题 | Fixed campfire recipes behaving incorrectly under some circumstances on Spigot
- 修复酿造配方的模板与结果物品未隔离,导致结果处理器的修改在多个槽位、多个批次间互相污染的问题 | Fixed brewing recipe templates and per-slot result items not being isolated, so result processor changes leaked across slots and batches
- 修复讲台取书触发器键名与实际事件不符的问题,键名由
player_take_campfire修正为player_take_lectern_book| Fixed the lectern book take trigger key not matching the event it is bound to; the key has been renamed fromplayer_take_campfiretoplayer_take_lectern_book - 修复一定情况下
player_deathblock_breakblock_place触发器的玩家对象不正确的问题 | Fixed the player object being incorrect for theplayer_death,block_breakandblock_placetriggers under some circumstances - 修复合成、锻造与铁砧触发器在合成被其他插件取消后仍会执行动作的问题 | Fixed crafting, smithing and anvil triggers still running actions after the craft was cancelled by another plugin
- 修复无法获取配方 key 的配方不经过材料限制规则的问题 | Fixed recipes whose key cannot be obtained not going through ingredient restriction rules
- 修复 Vault、VaultUnlocked 与 PlayerPoints 经济脚本函数未返回实际交易结果的问题 | Fixed the Vault, VaultUnlocked and PlayerPoints economy script functions not returning the actual transaction result
- 修复 AdvancedEnchantments 的结果处理器实际没有注册的问题 | Fixed the AdvancedEnchantments result processor not being registered at all
- 修复配方编辑器保存配方时,解析或注册失败可能导致原配方丢失或误报保存成功的问题 | Fixed the recipe editor potentially losing the original recipe or reporting a false success when saving failed to parse or register
- 结果处理器的单条组件出错不再影响同配方的其余组件;组件参数在加载期校验,非法参数会告警并跳过该条 | A single failing result processor component no longer affects the remaining components of the same recipe. Component parameters are validated at load time and invalid ones are skipped with a warning
- 修复铁砧配方在 Ctrl+Q 丢弃、批量合成计数与等级花费显示上的若干问题 | Fixed several anvil recipe issues with Ctrl+Q dropping, batch craft counting and level cost display
- 修复
/craftorithm disable命令传入非法配方 ID 时会报错、无参数时补全越界的问题 | Fixed the/craftorithm disablecommand erroring on an invalid recipe id and tab completion going out of bounds with no arguments - 修复重载期间可能误删玩家已解锁配方的问题 | Fixed reloads potentially deleting players' unlocked recipes
- 修复数据库连接重建期间可能返回已关闭连接的问题 | Fixed a possible closed connection being returned while the database connection was being rebuilt
- 修复
log_level配置为非法值时会导致插件加载/重载失败的问题 | Fixedlog_levelbeing set to an invalid value causing plugin load/reload to fail
破坏性更新 | Breaking Changes
- 结果处理器的
lore(物品说明文本)组件,其add策略现在会追加到结果物品已有的说明文本之后,不再覆盖原有内容;需要整体替换说明文本的配方请把type: add改为type: set| For thelore(item lore) component of result processors, theaddstrategy now appends to the result item's existing lore instead of overwriting it; recipes that need to replace the whole lore should changetype: addtotype: set
更新内容 | Update Contents
- 结果处理器新增
set策略,用于整体替换组件内容,适用于说明文本、附魔、属性、物品标志、持久数据这类可以容纳多项的组件,详见结果处理器文档 | Added asetstrategy to result processors for full replacement, available on the components that can hold multiple entries: lore, enchantments, attributes, item flags and persistent data. See the result processor documentation for details - 结果处理器新增
damage、max_damage、base_color、skull_profile、enchantment_glint_override、potion、glider、enchantable、tooltip_style、use_cooldown、damage_resistant类型,trim新增add策略 | Added new result processor component types:damage,max_damage,base_color,skull_profile,enchantment_glint_override,potion,glider,enchantable,tooltip_style,use_cooldownanddamage_resistant;trimnow supports theaddstrategy - 配方创建页与编辑页新增「保存结果物品全部组件」开关,开启后保存配方时结果物品的全部组件会被完整写入插件内置物品源 | Added a "Save all components of the result item" toggle to the recipe creator and editor; when enabled, saving a recipe writes every component of the result item into the built-in item provider
- 修复自 1.15.0.0 起,材料限制规则无法作用于原版配方与其他插件注册的配方的问题;规则的
recipes现在支持用*匹配所有配方,配方无法获取 key 时只有该写法能命中 | Fixed an issue since 1.15.0.0 where ingredient restriction rules did not apply to vanilla recipes or recipes registered by other plugins; therecipeslist now accepts*to match every recipe, which is the only form that matches recipes whose key is unavailable - 修复配置单个世界时,如果该世界不存在会让配方在任何世界都能合成的问题 | Fixed an issue where a recipe could be crafted in every world when world isolation listed a single world that does not exist
- 修复被限制材料的铁砧配方会阻断同材料其它铁砧配方合成的问题 | Fixed an issue where an anvil recipe with restricted ingredients blocked other anvil recipes using the same ingredients
- 修复恢复配方失败时仍然将其从禁用列表移除,导致配方丢失的问题 | Fixed an issue where a recipe was removed from the disabled list even though restoring it failed, causing the recipe to be lost
- 修复重载时会重复处理已经禁用的配方的问题 | Fixed reloading processing already disabled recipes again
- 修复打开熔炉界面时按住 Shift 点击背包内空格会报错的问题 | Fixed an error when shift-clicking an empty backpack slot while the furnace menu is open
- 修复 1.21 以上版本的有序配方不能正确处理材料限制的问题 | Fixed shaped recipes on 1.21+ not handling ingredient restrictions correctly
- 修复切石机编辑界面读取结果物品错误的问题 | Fixed the stonecutter editor reading the wrong result item
更新内容
- 有序配方与无序配方新增
remainders字段,用于控制每个输入槽在合成后留下的物品,支持damage(扣除耐久)、replace(替换为指定物品)、keep(原样保留)三种动作 | 为有序和无序配方添加了remainders部分,用于控制每次合成后各输入槽残留的物品。可用动作为damage(消耗耐久)、replace(替换为给定物品)和keep(保留原物品)。 - (配置会自动迁移)材料相关配置项统一收至
ingredient节点 | (配置将自动迁移)所有与材料相关的配置选项已整合至ingredient部分。 - 修复内置物品源在同一个物品被保存为不同ID时,解析出的物品ID不稳定导致物品可能不能正确用于合成的问题 | 修复了当同一物品以不同 ID 保存时,内置物品源解析出的物品 ID 不稳定的问题,该问题可能导致物品无法在合成中正确匹配。
- 调整部分加载与重载提示信息的输出时间 | 调整了部分加载和重载提示信息的输出时机。
更新内容 | Update Contents
- 移除配置项
use_experimental_recipe_ingredients,新增配置项ingredient_match_mode,用于选择配方材料的匹配方式:first(默认,使用第一个识别到的物品 id 匹配)或all(收集物品所有可能的物品 id 后逐个尝试匹配,性能开销更高) | Removed theuse_experimental_recipe_ingredientsoption and added theingredient_match_modeoption to choose how recipe ingredients are matched:first(default, matches using the first recognized item id) orall(collects all possible item ids of an item and tries them one by one, which costs more performance). not_convert_listener_classes支持以*结尾的条目按类名前缀匹配 |not_convert_listener_classesnow supports entries ending with*for class-name prefix matching.- 连续发起的插件重载请求现在会进入队列依次执行,不再被直接丢弃 | Consecutive plugin reload requests are now queued and executed in order instead of being dropped.
- 优化插件启动加载流程 | Optimized the plugin's startup loading flow.
- 优化26.3版本下禁用较多酿造配方时,重载过程占用较多网络带宽的问题 | Reduced excessive network bandwidth usage during reload on 26.3 when a large number of brewing recipes are disabled.
- 其他插件监听器转换成功的日志级别由
verbose调整为info| The log level for successfully converted third-party listeners has been changed fromverbosetoinfo. - 修复通过
/craftorithm restore恢复的配方无法出现在命令补全列表中的问题 | Fixed recipes restored via/craftorithm restorenot showing up in command tab completion. - 修复
ingredient_restriction_rules中的物品 id 无法解析时导致整份限制规则重载中断的问题 | Fixed an issue where an unparseable item id iningredient_restriction_rulesaborted reloading of the entire rule list. - 修复迁移整型配置项时输出无意义警告的问题 | Fixed meaningless warnings when migrating integer config options.
关于这个资源的讨论、问题反馈与使用心得
还没有讨论,来发第一帖吧
你是这个资源的作者?登录后可认领此资源。
相似资源
插件
PacketEvents 是一款专为 Minecraft Java 版打造的协议库,旨在简化数据包的处理与传输。
插件
使床在所有维度中爆炸的模组
插件
ExyliaPlugins 的库。
插件
通过对话框或铁砧界面帮助你的 Anthme
插件
重新定义服务器上的生物运输方式。使用高度可定制的口袋道具,安全地捕获、存储和释放任何实体。
插件
为基于 Spigot/Paper/Folia 的服务器添加对 Vivecraft 的支持
评论 0
登录后参与评分
还没有评论,来抢沙发吧