For the complete documentation index, see llms.txt. This page is also available as Markdown.

能力条件

能力条件用于决定触发器、能力修改器或能力能否继续执行。普通的 conditions 映射使用逻辑 AND(与):其中每个具名子条件都必须匹配。

EnchantmentReform 注册了 74 个内置条件键,本参考文档会对它们进行说明。

参考页面

通用格式

conditions:
  unique-entry-id:
    type: health_percent
    target: TARGET
    max: 50
    not: false

通用字段

字段
默认值
说明

type

必填

已注册的条件键。键不区分大小写,且 - 会被规范化为 _

not

false

反转该条件最终返回的结果。

target

由类型决定

当条件实现提供实体选择器时,可使用 SOURCESKILLTARGET 等选择器。

meet-message

条件匹配时,可选择向解析出的玩家发送消息。

not-meet-message

条件不匹配时,可选择发送消息。

当条件所需的实体、物品、方块、位置、事件或可修改结果不存在时,该条件会返回 false。各分类页面会说明每种条件所需的确切上下文,以及其支持的所有专用字段。

检查时机

触发器层级的条件会在能力修改器和能力之前执行。附加在某个能力修改器或能力上的条件,则会在执行到该条目时检查。因此,读取结果的条件可以观察同一触发器部分中更早执行的能力修改器所产生的变化。

类型索引

类型
参考页面

player_conditions

health_percent

catch_match_item

min_attack_cooldown

potion_effect_type

potion_effect_cause

potion_effect_action

first_attack_against_entity

first_attack_from_monster

first_monster_attack

target_category

liquid_surface_distance

liquid_transition

block_type_offset

preferred_tool

block_break_time

combust_duration

explosion_yield

explosion_radius

interaction_action

combust_origin

knockback_cause

knockback_reason

exhaustion_reason

villager_trade

cooldown_material

最后更新于