家具执行动作
交互时执行命令
items:
lamp:
display_name: "Lamp"
permission: myitems.decorative.lamp
lore:
- lore-decorative-item
resource:
material: PAPER
generate: false
model_path: lamp
behaviours:
furniture:
light_level: 13
solid: true
events:
placed_armorstand:
interact:
execute_commands:
the_first_command:
command: help
as_console: false在这个例子中,你可以看到一个家具,当玩家与其交互时会执行命令 /help。
当然,你也可以在placed_armorstand中添加更多的动作,不仅是 execute_commands。
交互时打开交易菜单
在这个例子中,你可以看到如何将交易 GUI 附加到你的家具上。这对于创建自定义机器非常有用。
Last updated
Was this helpful?