跳到正文

Jcraft

作者:k3nder

Use the Fabric api in a Json

收藏

介绍

中文介绍正在准备中,下面暂时显示原文。

There is no mod that does this so far,at least I haven’t seen any,
it may not be very useful but it seems to me that it is useful,
at least for those who have read the documentation WHICH ONLY TAKES A FEW MINUTES TO READ, today I present Jcraft (Json Craft) is a mod/library to be able to use the fabric API in Json configuration files, I would consider it a bit useless but I didn’t know what to do so this occurred to me, you can add blocks and items with very little programming!, except the texture, for that use Texture Packs, I will soon solve that, and soon there will also be improvements!

How to use

jcraft creates a folder in the game directory called ‘jcraft’, inside this folder there are two other ‘blocks’ and ‘items’, inside these folders the json are added, it doesn’t matter the name, the important thing is the structure, in the case For the items, the important thing is to add the values name and namespace, you can also add the settings and more, an example of json item would be:

{
    "name": "myItem",
    "namespace": "myMod",
    "settings":{
        "fireproof": true
    }
}

with the value fireproof: true makes it fire resistant, while name and namespace configure the basic values, such as the item name and the namespace (such as the mod name)

How to add a block

Something similar happens with the blocks, these have the name and the namespace, but apart from that they also contain the item value that adds the item of the block in addition to the block itself, in settings the easiest thing to configure is the parent , An example:

{
  "name": "myBlock",
  "namespace": "myMod",
  "settings":{
    "parent": "BEDROCK"
  }
}

The parent does what it inherits the configuration of the block that has already been configured, it is important to put it in capitals as in this case the BEDROCK

常见问题

Jcraft 支持哪些 Minecraft 版本?

Jcraft 支持 Minecraft Java 版 1.20.4,可用的加载器:Fabric。下载时注意选择和你游戏版本一致的文件。

Jcraft 怎么安装?

先用 PCL2 或 HMCL 启动器安装对应版本的 Fabric,再把下载的 .jar 文件放进游戏目录的 mods 文件夹,重新启动游戏即可。开启了版本隔离的,mods 文件夹在 versions/版本名 下面。运行环境:客户端和服务端都要装。

评论

登录后评论和评分

k3nder 的其他作品

查看全部 →