描述:
此模组允许你使用 Origins 模组创建自定义饰品物品。
命令:
/originsxtrinkets registertrinket
用于直接将 JSON 中生成的新物品添加到 item_gen.json 文件中,从而生成并注册你所制作的饰品。
/originsxtrinkets unregistertrinket
用于直接从 item_gen.json 配置文件中移除任何饰品物品。
(请注意,为了看到使用 registertrinket 和 unregistertrinket 命令所做的更改,你必须重载你的整合包)
/originsxtrinkets debugmode true
开启或关闭游戏内的调试信息。
设置指南:
步骤 1:创建一个新的数据包并将其放入你的 Minecraft 世界的数据包文件夹中,然后创建以下文件夹列表
saves<Your World>\datapacks<Your Datapack>\data<namespace of datapack>\originsxtrinkets\trinket_items\power_trinkets.json
步骤 2:编辑 power_trinket.json 使其如下面的示例所示
{
"type": "originsxtrinkets:power_trinket",
"fire_ring": {
"item": "bluestrinkets:fire_ting",
"tooltip":"This is a fire ringsss",
"tooltip_color":"#5E4CE4",
"shift_tooltip": "fire ring does alot more things",
"shift_tooltip_color":"#BCB14E",
"crtl_tooltip": "fire ring does alt of more things",
"crtl_tooltip_color":"#4EBC9B",
"powers": [
"origins:fire_immunity"
]
},
"climbing_belt": {
"item": "bluestrinkets:climbing_belt",
"powers": [
"origins:climbing"
]
}
}
定义:
# =================================================================
# "item" - 用于保存你的自定义物品的命名空间,或者用于获取现有物品的命名空间。这将通过命名空间选择物品以应用起源能力。
# 另外请注意,item 既可用于将起源能力应用于现有物品,也可用于制作自定义物品。
# =================================================================
# "powers" - 用于保存当佩戴饰品时想要赋予用户的起源能力。这是通过在 powers 中输入能力的命名空间来完成的。
# =================================================================
# "tooltip" - 如果你制作的是自定义物品,这将为其生成一个普通的提示文本。
# ==================================================================
# "tooltip_color" - 用于为选定提示文本设置自定义颜色。
步骤 3:如果你创建的物品尚不存在,则必须更新模组的配置以便能够生成这些饰品物品。该配置文件位于此处 <YourModpackFolder>.minecraft\config\originsxtrinkets\gen_items.json
然后在配置文件中添加你的自定义物品命名空间,示例如下
{
"generated_items": [
"bluestrinkets:fire_ring",
"bluestrinkets:climbing_belt"
]
}
这将创建具有你在 generated items 配置中输入的精确命名空间的新物品,你可以将这些物品用作饰品。
另一种注册你的饰品物品的方法是使用 registertrinket 命令。
=================================================================
/originsxtrinkets registertrinket all
=================================================================
运行此命令后,所有未包含在 generated items 配置中的物品都会自动添加到配置文件中。
然而,使用此命令时,为了看到新注册的物品,你必须重启你的整合包。
步骤 4:使用刚刚生成的带有自定义命名空间的新物品,实现饰品的功能部分,例如将其放置在戒指、腰带或项链槽位中等等。
要设置饰品相关部分,请查看 Trinkets API。
如果你想查看示例数据包,请访问这里
Description:
This mod makes it so that you can create custom trinket items using the origins mod
Commands:
/originsxtrinkets registertrinket
is used to directly add the newly generated items from the json into the item_gen.json file to generate and register the trinkets you make
/originsxtrinkets unregistertrinket
is used to directly remove any trinket item from the item_gen.json config file
(please note that in order to see changes made by using the registertrinket and unregistertrinket command you must reload your modpack)
/originsxtrinkets debugmode true
turns off and on debuging messages within the game
Set Up Guide:
Step 1: Create a new datapack and put it in your minecraft worlds datapack folder then create the following list of folders
saves<Your World>\datapacks<Your Datapack>\data<namespace of datapack>\originsxtrinkets\trinket_items\power_trinkets.json
Step 2: edit the power_trinket.json so that it looks like the following example
{
"type": "originsxtrinkets:power_trinket",
"fire_ring": {
"item": "bluestrinkets:fire_ting",
"tooltip":"This is a fire ringsss",
"tooltip_color":"#5E4CE4",
"shift_tooltip": "fire ring does alot more things",
"shift_tooltip_color":"#BCB14E",
"crtl_tooltip": "fire ring does alt of more things",
"crtl_tooltip_color":"#4EBC9B",
"powers": [
"origins:fire_immunity"
]
},
"climbing_belt": {
"item": "bluestrinkets:climbing_belt",
"powers": [
"origins:climbing"
]
}
}
Definitions:
# =================================================================
# "item"- is used to hold your custom items namespace or it is used to get an existing items namespace. this will get the select item using the namespace to apply the origin powers to.
# Also note that item can be used to apply origin powers to existing items as well as making custom items as well.
# =================================================================
# "powers"- is used to hold the origin powers you want to apply to the user when the trinket is worn. this is done through typing the powers namespace within powers.
# =================================================================
# "tooltip"- if the item you are making is a custom one then this will generate a normal tooltip for that item.
# ==================================================================
# "tooltip_color"- is used to set a custom color for the text of the select tooltip.
Step 3: if the items you are creating do not already exist then you must update the config of the mod so that it is able to generate
the trinket items this config file can be found here <YourModpackFolder>.minecraft\config\originsxtrinkets\gen_items.json
then once you are in the config file add in your custom items namespace here is an example
{
"generated_items": [
"bluestrinkets:fire_ring",
"bluestrinkets:climbing_belt"
]
}
this will create new items with the exact namespaces you put into the generated items config that you can use to make them into a trinket item
another way to also register your trinket items is to use the registertrinket command
=================================================================
/originsxtrinkets registertrinket all
=================================================================
when this command is ran all items that were not put within the generated items config will be added into the config file for you automatically
however, when using this command in order to see the newly registered items you must restart your modpack
Step 4: with the new items that you just generated using there custom namespaces implement the trinket side of the item. like the item being in the ring, belt or necklace slots and etc
in order to setup the trinket side of things look here trinkets api
Also if you want to see an example datapack look here
评论 0
登录后参与评分
还没有评论,来抢沙发吧