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

minecraft:celebrate_hunt

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

概览

minecraft:celebrate_hunt 是一个实体组件:写在自定义生物的 components 对象中,或其中某个组件组里。 让生物在击杀目标后庆祝,就像猪灵狩猎后跳舞一样。

字段

字段类型默认值说明
broadcastBoolean"true"为 true 时,附近的实体也会一起庆祝。
celeberation_targetsMinecraft Filter无被击杀的目标必须满足的条件,才会开始庆祝。
celebrate_soundString无庆祝时播放的声音。
durationInteger"4"庆祝持续多少秒。
radiusDecimal"16"广播时通知其他实体一起庆祝的距离(以方块计)。
sound_intervalRange [a, b]"0"两次庆祝声音之间的随机等待秒数。

示例

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

BP/entities/<name>.json
{
  "minecraft:celebrate_hunt": {
    "broadcast": "true",
    "celeberation_targets": {},
    "celebrate_sound": "",
    "duration": "4",
    "radius": "16",
    "sound_interval": "0"
  }
}

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