> For the complete documentation index, see [llms.txt](https://enchantedmobs.superiormc.cn/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://enchantedmobs.superiormc.cn/ultimatequest-zhong-wen-wen-dang/pei-zhi/conditions/logical.md).

# 逻辑条件

示例写在目标或对应任务字段的 conditions 中。公共字段见[概览](/ultimatequest-zhong-wen-wen-dang/pei-zhi/conditions.md)。

## `any`

任一具名子条件满足即通过。

| 字段           | 默认值 | 说明        |
| ------------ | --- | --------- |
| `conditions` | —   | 具名事件条件映射。 |

```yaml
conditions:
  choice:
    type: any
    conditions:
      water:
        type: in_water
        target: PLAYER
      rain:
        type: storm
```

省略 conditions 节点时通过，显式空映射没有匹配子项，因此失败。

## `not`

反转子条件整体 AND 结果。

| 字段           | 默认值 | 说明        |
| ------------ | --- | --------- |
| `conditions` | —   | 具名事件条件映射。 |

```yaml
conditions:
  outside:
    type: not
    conditions:
      water:
        type: in_water
        target: PLAYER
```

与 any 不同，not(A AND B) 只在两者都满足时失败；单个条件反转可用公共 not: true。
