声明式 UI
一款基于 Fabric 的数据驱动 Minecraft GUI 模组,简化了图形界面的创建过程,并支持在数据包中创建命令。
无需学习 Java 或 Kotlin。
还支持容器功能,因此你可以尝试制作出售界面等。
? 使用方法
要创建一个数据包,可以使用 /datapack create <id> <description>。你会在世界的数据包文件夹中找到它。
要创建一个 GUI(支持自定义槽位操作和标题),请在其 data/<namespace>/declarative_ui/menu 文件夹中创建一个 JSON 文件。有关 JSON 格式,请查看 菜单生成器
要创建一个命令(带参数或不带参数),遵循之前的步骤,但将 JSON 放入 data/<namespace>/declarative_ui/command 中,并查看 命令生成器 以了解格式。
要创建一个容器,请在 data/<namespace>/declarative_ui/container 中创建一个 JSON 文件,并在 size 字段中填入大于 0 的数字。
要处理自定义点击操作,请在 data/<namespace>/declarative_ui/custom_click_action 中创建一个 JSON 文件,并在 function 字段中填入函数路径。
? 额外命令
- 使用
/item (modify|replace) container对玩家存储的容器进行命令修改 - 使用
/declarative_ui open <targets> <menu>打开一个菜单 /execute if container
? 战利品表
- 在 1.21.11+ 版本中,你可以在槽位条目中选择
declarative_ui:container槽位来源
你还可以在此处下载 .mcdoc 和 commands.json 文件用于 Spyglass:
Declarative UI
A data-driven UI mod for Minecraft using Fabric, making creation of GUIs easier and creating commands possible within a datapack.
No need to learn Java or Kotlin.
Containers also exist, so you could try making a sell gui, etc.
? Usage
To create a datapack, you can use /datapack create <id> <description>. You'll find it in your world's datapacks folder.
To create a GUI, which also allows customized slot actions and titles, create a JSON file within its data/<namespace>/declarative_ui/menu folder you'll create. For the format of the JSON, check the Menu Generator
To create a Command, with or without parameters, follow previous steps but put the JSON within data/<namespace>/declarative_ui/command and check the Command Generator for the format.
To create a container, create a JSON file within data/<namespace>/declarative_ui/container and put a number greater than 0 in a size field.
To handle a custom click action, create a JSON file within data/<namespace>/declarative_ui/custom_click_action and put a function path in a function field.
? Extra Commands
- Use
/item (modify|replace) containerfor command modification of player stored containers - Use
/declarative_ui open <targets> <menu>to open a menu /execute if container
? Loot Tables
- In 1.21.11+ you can choose the
declarative_ui:containerslot source in a slot entry
You can also download the .mcdoc and commands.json files for Spyglass here:
下载 Declarative UI
下载 Declarative UI
下载 Declarative UI
下载 Declarative UI
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Declarative UI
下载 Declarative UI
下载 Declarative UI
下载 Declarative UI
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Declarative UI
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Declarative UI
更新版本
因 Perplex 的更改,禁用了 /item 添加项
关于这个资源的讨论、问题反馈与使用心得
还没有讨论,来发第一帖吧
你是这个资源的作者?登录后可认领此资源。
相似资源
模组
一个用于收集生物掉落物的多区块模组。
模组
显示你正在注视的方块的信息。(适用于 Minecraft 1.16+ 的 Hwyla/Waila 分支)
模组
查看物品与配方
模组
在游戏画面角落显示附近世界地形、玩家、生物和实体的地图。可创建路径点,帮助你找到标记过的位置。
模组
使用 JavaScript 编辑配方、添加自定义物品、编写世界事件!
模组
适用于 MC 1.18+ 的 Effekseer 加载器
评论 0
登录后参与评分
还没有评论,来抢沙发吧