1. Wiki
  2. /实体
  3. /minecraft:leashable_to

minecraft:leashable_to

不想手写?在 GodCraft 里打开一个开关,就能帮你设置好 minecraft:leashable_to。Get GodCraft

概览

minecraft:leashable_to 是一个实体组件:写在自定义生物的 components 对象中,或其中某个组件组里。 让玩家可以把被拴住的实体系到这个实体上、把它们取回,或用剪刀剪断拴绳。只有被拴住的实体开启了 "can_be_cut" 时才能剪断。

字段

字段类型默认值说明
can_retrieve_fromBoolean"false"让玩家可以取回系在这个实体上的实体。
unleash_on_removalBoolean"true"移除组件时松开所有系在这个实体上的实体。

示例

写在 BP/entities/<name>.json 的 components 对象中(值为默认值或占位值):

BP/entities/<name>.json
{
  "minecraft:leashable_to": {
    "can_retrieve_from": "false",
    "unleash_on_removal": "true"
  }
}

We use cookies to improve your experience and analyse site traffic. Learn more