{
  "format_version": "1.16.100",
  "minecraft:entity": {
    "description": {
      "identifier": "cc_fairytales:minotaur",
      "is_spawnable": true,
      "is_summonable": true,
      "is_experimental": false
    },
    "component_groups": {
      "tranquilo": {
        "minecraft:movement": {
          "value": 0.3
        },
        "minecraft:mark_variant": {
          "value": 0
        },
        "minecraft:attack": {
          "damage": 15.0
        },
        "minecraft:behavior.move_towards_target": {
          "within_radius": 2
        },
        "minecraft:behavior.random_stroll": {
          "priority": 10,
          "speed_multiplier": 0.4
        },
        "minecraft:behavior.look_at_player": {
          "priority": 6,
          "look_distance": 6,
          "angle_of_view_horizontal": 45,
          "probability": 1
        },
        "minecraft:behavior.nearest_attackable_target": {
          "priority": 2,
          "must_see": true,
          "reselect_targets": true,
          "within_radius": 25.0,
          "must_see_forget_duration": 17.0,
          "entity_types": [
            {
              "filters": {
                "any_of": [
                  {
                    "subject": "other",
                    "test": "is_family",
                    "value": "player"
                  },
                  {
                    "subject": "other",
                    "test": "is_family",
                    "value": "irongolem"
                  }
                ]
              },
              "max_dist": 35
            }
          ]
        },
        "minecraft:on_target_acquired": {
          "target": "self",
          "event": "enojado"
        }
      },
      // FASE 1
      "hostil1": {
        "minecraft:movement": {
          "value": 0.5
        },
        "minecraft:mark_variant": {
          "value": 0
        },
        "minecraft:attack": {
          "damage": 15.0
        },
        "minecraft:behavior.move_towards_target": {
          "within_radius": 2
        },
        "minecraft:behavior.random_stroll": {
          "priority": 6,
          "speed_multiplier": 0.4
        },
        "minecraft:behavior.look_at_player": {
          "priority": 7,
          "look_distance": 6,
          "angle_of_view_horizontal": 45,
          "probability": 1
        },
        "minecraft:behavior.melee_box_attack": {
          "priority": 0,
          "track_target": true
        },
        "minecraft:behavior.look_at_entity": {
          "priority": 10,
          "look_distance": 8,
          "angle_of_view_horizontal": 45,
          "filters": {
            "test": "is_family",
            "subject": "other",
            "value": "mob"
          }
        },
        "minecraft:behavior.nearest_attackable_target": {
          "priority": 2,
          "must_see": true,
          "reselect_targets": true,
          "within_radius": 25.0,
          "must_see_forget_duration": 17.0,
          "entity_types": [
            {
              "filters": {
                "any_of": [
                  {
                    "subject": "other",
                    "test": "is_family",
                    "value": "player"
                  },
                  {
                    "subject": "other",
                    "test": "is_family",
                    "value": "irongolem"
                  }
                ]
              },
              "max_dist": 35
            }
          ]
        },
        "minecraft:timer": {
          "time": 6,
          "looping": true,
          "time_down_event": {
            "event": "remove",
            "target": "self"
          }
        }
      },
      //timer que cambia del evento que remueve los ataques de random1 para nuevamente llamar a random1
      "t1": {
        "minecraft:timer": {
          "time": 0.1,
          "looping": true,
          "time_down_event": {
            "event": "random1",
            "target": "self"
          }
        }
      },
      // ATAQUE DE AREA ACTIVADA POR ESCUDO
      "aturdido": {
        "minecraft:is_stunned": {},
        "minecraft:timer": {
          "looping": false,
          "time": 2,
          "time_down_event": {
            "event": "area"
          }
        }
      },
      "ataque_area_escudo": {
        "minecraft:behavior.knockback_roar": {
          "priority": 1,
          "duration": 1,
          "attack_time": 0.5,
          "knockback_damage": 13,
          "knockback_horizontal_strength": 5,
          "knockback_vertical_strength": 5,
          "knockback_range": 7,
          "damage_filters": {},
          "on_roar_end": {
            "event": "fin_area"
          },
          "cooldown_time": 0.1
        }
      },
      //ATAQUE DE AREA
      "ataque_area": {
        "minecraft:behavior.knockback_roar": {
          "priority": 1,
          "duration": 1,
          "attack_time": 1,
          "knockback_damage": 13,
          "knockback_horizontal_strength": 5,
          "knockback_vertical_strength": 5,
          "knockback_range": 10,
          "damage_filters": {},
          "cooldown_time": 2
        },
        "minecraft:timer": {
          "time": 2,
          "looping": true,
          "time_down_event": {
            "event": "remove",
            "target": "self"
          }
        },
        "minecraft:movement": {
          "value": 0.3
        },
        "minecraft:behavior.random_stroll": {
          "priority": 6,
          "speed_multiplier": 0.4
        },
        "minecraft:behavior.look_at_player": {
          "priority": 7,
          "look_distance": 6,
          "angle_of_view_horizontal": 45,
          "probability": 1
        },
        "minecraft:behavior.look_at_entity": {
          "priority": 10,
          "look_distance": 8,
          "angle_of_view_horizontal": 45,
          "filters": {
            "test": "is_family",
            "subject": "other",
            "value": "mob"
          }
        },
        "minecraft:behavior.nearest_attackable_target": {
          "priority": 2,
          "must_see": true,
          "reselect_targets": true,
          "within_radius": 25.0,
          "must_see_forget_duration": 17.0,
          "entity_types": [
            {
              "filters": {
                "any_of": [
                  {
                    "subject": "other",
                    "test": "is_family",
                    "value": "player"
                  }
                ]
              },
              "max_dist": 35
            }
          ]
        }
      },
      // FASE 2
      "periodo_gracia": {
        "minecraft:environment_sensor": {
          "triggers": [
            {
              "event": "fase2",
              "filters": {
                "all_of": [
                  {
                    "test": "actor_health",
                    "subject": "self",
                    "value": 25,
                    "operator": "<="
                  }
                ]
              }
            }
          ]
        },
        "minecraft:damage_sensor": {
          "triggers": [
            {
              "on_damage": {
                "filters": {
                  "all_of": [
                    {
                      "test": "has_damage",
                      "subject": "self",
                      "value": "fatal"
                    }
                  ]
                }
              },
              "deals_damage": false
            }
          ]
        }
      },
      "llamar_runa": {
        "minecraft:addrider": {
          "entity_type": "cc_fairytales:rune"
        },
        "minecraft:rideable": {
          "crouching_skip_interact": true,
          "family_types": [
            "rune"
          ],
          "interact_text": "ride",
          "pull_in_entities": true,
          "rider_can_interact": false,
          "seat_count": 1,
          "seats": [
            {
              "position": [
                0,
                0.5,
                1
              ]
            }
          ]
        },
        "minecraft:mark_variant": {
          "value": 1
        }
      },
      "regeneracion": {
        "minecraft:spell_effects": {
          "add_effects": [
            {
              "effect": "regeneration",
              "duration": 900,
              "amplifier": 6
            }
          ]
        }
      },
      "quieto": {
        "minecraft:movement": {
          "value": 0
        },
        "minecraft:damage_sensor": {
          "triggers": [
            {
              "cause": "all",
              "deals_damage": false
            }
          ]
        },
        "minecraft:knockback_resistance": {
          "value": 100
        },
        "minecraft:pushable": {
          "is_pushable": false
        }
      },
      // FASE 3
      "hostil2": {
        "minecraft:movement": {
          "value": 0.7
        },
        "minecraft:attack": {
          "damage": 20.0
        },
        "minecraft:behavior.move_towards_target": {
          "within_radius": 2
        },
        "minecraft:behavior.random_stroll": {
          "priority": 6,
          "speed_multiplier": 0.4
        },
        "minecraft:behavior.look_at_player": {
          "priority": 7,
          "look_distance": 6,
          "angle_of_view_horizontal": 45,
          "probability": 1
        },
        "minecraft:behavior.look_at_entity": {
          "priority": 10,
          "look_distance": 8,
          "angle_of_view_horizontal": 45,
          "filters": {
            "test": "is_family",
            "subject": "other",
            "value": "mob"
          }
        },
        "minecraft:behavior.melee_box_attack": {
          "priority": 0,
          "track_target": true,
          "cooldown_time": 2
        },
        "minecraft:behavior.nearest_attackable_target": {
          "priority": 2,
          "must_see": true,
          "reselect_targets": true,
          "within_radius": 25.0,
          "must_see_forget_duration": 17.0,
          "entity_types": [
            {
              "filters": {
                "any_of": [
                  {
                    "subject": "other",
                    "test": "is_family",
                    "value": "player"
                  }
                ]
              },
              "max_dist": 35
            }
          ]
        }
      },
      "moverse_denuevo": {
        "minecraft:movement": {
          "value": 0.4
        },
        "minecraft:pushable": {
          "is_pushable": true
        },
        "minecraft:mark_variant": {
          "value": 0
        },
        "minecraft:damage_sensor": {
          "triggers": [
            {
              "cause": "all",
              "deals_damage": true
            }
          ]
        }
      },
      "quitar_regeneracion": {
        "minecraft:spell_effects": {
          "remove_effects": [
            "regeneration"
          ]
        }
      }
    },
    "components": {
      "minecraft:behavior.float": {
        "priority": 0
      },
      "minecraft:ravager_blocked": {
        "knockback_strength": 3.0,
        "reaction_choices": [
          {
            "weight": 1,
            "value": {
              "event": "queda_aturdido",
              "target": "self"
            }
          },
          {
            "weight": 1
          }
        ]
      },
      "minecraft:boss": {
        "hud_range": 55,
        "name": "MINOTAUR",
        "should_darken_sky": false
      },
      "minecraft:experience_reward": {
        "on_death": "100"
      },
      "minecraft:breathable": {
        "suffocate_time": 0,
        "total_supply": 15
      },
      "minecraft:collision_box": {
        "width": 2,
        "height": 4.6
      },
      "minecraft:health": {
        "value": 300
      },
      "minecraft:jump.static": {},
      "minecraft:loot": {
        "table": "loot_tables/chillcraft/fairy/entities/minotaur.json"
      },
      "minecraft:knockback_resistance": {
        "value": 0.75
      },
      "minecraft:movement": {
        "value": 0.4
      },
      "minecraft:movement.basic": {},
      "minecraft:navigation.walk": {
        "avoid_damage_blocks": true,
        "can_path_over_water": true,
        "can_sink": false
      },
      "minecraft:behavior.hurt_by_target": {
        "priority": 3
      },
      "minecraft:physics": {},
      "minecraft:pushable": {
        "is_pushable": true,
        "is_pushable_by_piston": true
      },
      "minecraft:conditional_bandwidth_optimization": {},
      "minecraft:despawn": {
        "despawn_from_distance": {}
      },
      "minecraft:follow_range": {
        "value": 64
      },
      "minecraft:type_family": {
        "family": [
          "monster",
          "mob",
          "minotaur"
        ]
      },
      "minecraft:break_blocks": {
        "breakable_blocks": [
          "acacia_leaves",
          "azalea_leaves",
          "azalea_leaves_flowered",
          "birch_leaves",
          "dark_oak_leaves",
          "jungle_leaves",
          "mangrove_leaves",
          "oak_leaves",
          "spruce_leaves"
        ]
      }
    },
    "events": {
      "minecraft:entity_spawned": {
        "add": {
          "component_groups": [
            "periodo_gracia",
            "tranquilo"
          ]
        }
      },
      "enojado": {
        "remove": {
          "component_groups": [
            "tranquilo"
          ]
        },
        "add": {
          "component_groups": [
            "hostil1"
          ]
        }
      },
      "queda_aturdido": {
        "add": {
          "component_groups": [
            "aturdido"
          ]
        },
        "remove": {
          "component_groups": [
            "hostil1"
          ]
        }
      },
      "area": {
        "add": {
          "component_groups": [
            "ataque_area_escudo"
          ]
        },
        "remove": {
          "component_groups": [
            "aturdido"
          ]
        }
      },
      "fin_area": {
        "add": {
          "component_groups": [
            "hostil1"
          ]
        },
        "remove": {
          "component_groups": [
            "ataque_area_escudo",
            "ataque_area"
          ]
        }
      },
      "remove": {
        "remove": {
          "component_groups": [
            "hostil1",
            "ataque_area"
          ]
        },
        "add": {
          "component_groups": [
            "t1"
          ]
        }
      },
      "random1": {
        "randomize": [
          {
            "add": {
              "component_groups": [
                "hostil1"
              ]
            },
            "weight": 50
          },
          {
            "add": {
              "component_groups": [
                "ataque_area"
              ]
            },
            "weight": 40
          }
        ]
      },
      "fase2": {
        "add": {
          "component_groups": [
            "llamar_runa",
            "regeneracion",
            "quieto"
          ]
        },
        "remove": {
          "component_groups": [
            "hostil1",
            "ataque_area"
          ]
        }
      },
      "runa_destruida": {
        "add": {
          "component_groups": [
            "moverse_denuevo",
            "quitar_regeneracion",
            "hostil2"
          ]
        },
        "remove": {
          "component_groups": [
            "quieto",
            "periodo_gracia"
          ]
        }
      }
    }
  }
}