Skip to main content

Any Of (Meta Condition Type)

Passes when at least one condition in the list passes, and an empty list fails. It works in every kind of condition.

Type ID: apoli:any_of (alias apoli:or)

Fields

FieldTypeDefaultDescription
conditionsarray of conditionsrequiredAny one of them passing is enough. They are the same kind as the containing condition.

Examples

Wet in any way:

{
  "type": "apoli:any_of",
  "conditions": [
    { "type": "apoli:in_rain" },
    { "type": "apoli:submerged_in", "fluid": "minecraft:water" },
    { "type": "apoli:in_block", "block_condition": { "type": "apoli:block", "block": "minecraft:water_cauldron" } }
  ]
}

A list of acceptable dimensions, which is the most common use:

{
  "type": "apoli:any_of",
  "conditions": [
    { "type": "apoli:dimension", "dimension": "minecraft:the_nether" },
    { "type": "apoli:dimension", "dimension": "minecraft:the_end" }
  ]
}
tip

Conditions are checked in order and stop at the first success, so put the likeliest first.