User Tools

Site Tools


actions:sequence_handlers:first_to_succeed

minecraft:first_to_succeed

The minecraft:first_to_succeed sequence handler runs all actions in the sequence until it hits one that was successful and then returns true. The sequence handler is unsuccessful if all actions were executed unsuccessfully.

Fields

Name Description Type Default Value
entries The entries of the sequence. An action, list of actions or hash-prefixed action tag

Example

{
  "type": "minecraft:sequence",
  "handler": "minecraft:first_to_succeed",
  "entries": [
    {
      "action": {
        "type": "minecraft:place_carved_pumpkin",
        "position": "target"
      }
    },
    {
      "action": {
        "type": "minecraft:equip_entity_at_position",
        "position": "target"
      }
    }
  ]
}
actions/sequence_handlers/first_to_succeed.txt · Last modified: 2024/05/02 15:10 by errorcraft