{
  "format_version": "1.26.0",
  "minecraft:entity": {
    "description": {
      "identifier": "minecraft:skeleton",
      "is_experimental": false,
      "is_summonable": true,
      "is_spawnable": true,
      "spawn_category": "monster"
    },
    "components": {
      "minecraft:behavior.avoid_mob_type": {
        "entity_types": [
          {
            "filters": {
              "AND": [
                {
                  "test": "is_family",
                  "subject": 1,
                  "operator": 0,
                  "value": "wolf"
                }
              ]
            },
            "max_dist": 6,
            "walk_speed_multiplier": 1.2,
            "sprint_speed_multiplier": 1.2
          }
        ],
        "priority": 4
      },
      "minecraft:behavior.equip_item": {
        "priority": 3
      },
      "minecraft:behavior.flee_sun": {
        "priority": 2,
        "speed_multiplier": 1
      },
      "minecraft:behavior.hurt_by_target": {
        "priority": 1
      },
      "minecraft:behavior.look_at_player": {
        "look_time": {
          "min": 1,
          "max": 2
        },
        "priority": 7
      },
      "minecraft:behavior.nearest_attackable_target": {
        "reselect_targets": true,
        "must_see": true,
        "entity_types": [
          {
            "filters": {
              "AND": [
                {
                  "test": "is_family",
                  "subject": 1,
                  "operator": 0,
                  "value": "player"
                }
              ]
            }
          },
          {
            "filters": {
              "AND": [
                {
                  "test": "is_family",
                  "subject": 1,
                  "operator": 0,
                  "value": "irongolem"
                }
              ]
            }
          },
          {
            "filters": {
              "AND": [
                {
                  "test": "is_family",
                  "subject": 1,
                  "operator": 0,
                  "value": "baby_turtle"
                },
                {
                  "test": "in_water",
                  "subject": 1,
                  "operator": 1,
                  "value": true
                }
              ]
            }
          }
        ],
        "priority": 2
      },
      "minecraft:behavior.pickup_items": {
        "can_pickup_any_item": true,
        "goal_radius": 2,
        "priority": 5,
        "max_dist": 3,
        "speed_multiplier": 1.0,
        "pickup_based_on_chance": true
      },
      "minecraft:behavior.random_look_around": {
        "priority": 8
      },
      "minecraft:behavior.random_stroll": {
        "priority": 6,
        "speed_multiplier": 1
      },
      "minecraft:behavior.ranged_attack": {
        "attack_interval_max": 3.0,
        "attack_interval_min": 1.0,
        "attack_radius": 15.0,
        "priority": 0
      },
      "minecraft:breathable": {
        "breathes_water": true,
        "suffocate_time": 0,
        "total_supply": 15
      },
      "minecraft:burns_in_daylight": {},
      "minecraft:can_climb": {},
      "minecraft:collision_box": {
        "height": 1.9,
        "width": 0.6
      },
      "minecraft:conditional_bandwidth_optimization": {},
      "minecraft:despawn": {
        "despawn_from_distance": {}
      },
      "minecraft:environment_sensor": {
        "triggers": [
          {
            "event": "minecraft:melee_mode",
            "filters": {
              "operator": "==",
              "test": "is_underwater",
              "subject": "self",
              "value": true
            }
          },
          {
            "event": "minecraft:melee_mode",
            "filters": {
              "operator": "==",
              "test": "has_ranged_weapon",
              "subject": "self",
              "value": false
            }
          },
          {
            "event": "got_in_powder_snow",
            "filters": {
              "operator": "==",
              "test": "in_block",
              "subject": "self",
              "value": "minecraft:powder_snow"
            }
          }
        ]
      },
      "minecraft:equip_item": {},
      "minecraft:equipment": {
        "table": "loot_tables/entities/skeleton_gear.json"
      },
      "minecraft:experience_reward": {
        "on_death": {
          "expression": "query.last_hit_by_player ? 5 + (query.equipment_count * Math.Random(1,3)) : 0",
          "version": 1
        }
      },
      "minecraft:health": {
        "max": 20,
        "value": 20
      },
      "minecraft:hurt_on_condition": {
        "damage_conditions": [
          {
            "cause": "lava",
            "damage_per_tick": 4,
            "filters": {
              "operator": "==",
              "test": "in_lava",
              "subject": "self",
              "value": true
            }
          }
        ]
      },
      "minecraft:is_hidden_when_invisible": {},
      "minecraft:jump.static": {},
      "minecraft:loot": {
        "table": "loot_tables/entities/skeleton.json"
      },
      "minecraft:movement": {
        "value": 0.25
      },
      "minecraft:movement.basic": {},
      "minecraft:nameable": {},
      "minecraft:navigation.walk": {
        "avoid_sun": true,
        "is_amphibious": true,
        "avoid_water": true,
        "using_door_annotation": true
      },
      "minecraft:physics": {},
      "minecraft:pushable": {
        "is_pushable": true,
        "is_pushable_by_piston": true
      },
      "minecraft:rotation_locked_to_vehicle": {},
      "minecraft:shareables": {
        "items": [
          {
            "item": "minecraft:netherite_sword",
            "priority": 0,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:diamond_sword",
            "priority": 1,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:iron_sword",
            "priority": 2,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:stone_sword",
            "priority": 3,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:golden_sword",
            "priority": 4,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:wooden_sword",
            "priority": 5,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:bow",
            "priority": 6,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:netherite_helmet",
            "priority": 0,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:diamond_helmet",
            "priority": 1,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:iron_helmet",
            "priority": 2,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:chainmail_helmet",
            "priority": 3,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:golden_helmet",
            "priority": 4,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:leather_helmet",
            "priority": 5,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:turtle_helmet",
            "priority": 6,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:skull:0",
            "priority": 7,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:skull:1",
            "priority": 7,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:carved_pumpkin",
            "priority": 7,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:netherite_chestplate",
            "priority": 0,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:diamond_chestplate",
            "priority": 1,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:iron_chestplate",
            "priority": 2,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:chainmail_chestplate",
            "priority": 3,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:golden_chestplate",
            "priority": 4,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:leather_chestplate",
            "priority": 5,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:netherite_leggings",
            "priority": 0,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:diamond_leggings",
            "priority": 1,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:iron_leggings",
            "priority": 2,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:chainmail_leggings",
            "priority": 3,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:golden_leggings",
            "priority": 4,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:leather_leggings",
            "priority": 5,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:netherite_boots",
            "priority": 0,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:diamond_boots",
            "priority": 1,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:iron_boots",
            "priority": 2,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:chainmail_boots",
            "priority": 3,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:golden_boots",
            "priority": 4,
            "surplus_amount": 1,
            "want_amount": 1
          },
          {
            "item": "minecraft:leather_boots",
            "priority": 5,
            "surplus_amount": 1,
            "want_amount": 1
          }
        ]
      },
      "minecraft:shooter": {
        "def": "minecraft:arrow"
      },
      "minecraft:type_family": {
        "family": [
          "skeleton",
          "undead",
          "monster",
          "mob"
        ]
      }
    },
    "component_groups": {
      "become_stray": {
        "minecraft:transformation": {
          "drop_inventory": true,
          "into": "minecraft:stray",
          "keep_level": true,
          "preserve_equipment": true,
          "transformation_sound": "convert_to_stray"
        }
      },
      "got_out_of_powder_snow_environment_sensor": {
        "minecraft:environment_sensor": {
          "triggers": [
            {
              "event": "minecraft:melee_mode",
              "filters": {
                "operator": "==",
                "test": "is_underwater",
                "subject": "self",
                "value": true
              }
            },
            {
              "event": "minecraft:melee_mode",
              "filters": {
                "operator": "==",
                "test": "has_ranged_weapon",
                "subject": "self",
                "value": false
              }
            },
            {
              "event": "minecraft:ranged_mode",
              "filters": {
                "all_of": [
                  {
                    "operator": "==",
                    "test": "in_water",
                    "subject": "self",
                    "value": false
                  },
                  {
                    "operator": "==",
                    "test": "has_ranged_weapon",
                    "subject": "self",
                    "value": true
                  }
                ]
              }
            }
          ]
        }
      },
      "in_powder_snow": {
        "minecraft:environment_sensor": {
          "triggers": [
            {
              "event": "got_out_of_powder_snow",
              "filters": {
                "operator": "!=",
                "test": "in_block",
                "subject": "self",
                "value": "minecraft:powder_snow"
              }
            }
          ]
        },
        "minecraft:is_shaking": {},
        "minecraft:timer": {
          "looping": false,
          "time": 20,
          "time_down_event": {
            "event": "become_stray_event"
          }
        }
      },
      "minecraft:lightning_immune": {
        "minecraft:damage_sensor": {
          "triggers": {
            "deals_damage": "no",
            "on_damage": {
              "filters": {
                "other_with_families": "lightning"
              }
            }
          }
        }
      },
      "minecraft:melee_attack": {
        "minecraft:attack": {
          "damage": 3
        },
        "minecraft:behavior.melee_attack": {
          "speed_multiplier": 1.25,
          "track_target": true,
          "priority": 4
        },
        "minecraft:environment_sensor": {
          "triggers": [
            {
              "event": "minecraft:ranged_mode",
              "filters": {
                "all_of": [
                  {
                    "operator": "==",
                    "test": "in_water",
                    "subject": "self",
                    "value": false
                  },
                  {
                    "operator": "==",
                    "test": "has_ranged_weapon",
                    "subject": "self",
                    "value": true
                  }
                ]
              }
            },
            {
              "event": "got_in_powder_snow",
              "filters": {
                "operator": "==",
                "test": "in_block",
                "subject": "self",
                "value": "minecraft:powder_snow"
              }
            }
          ]
        }
      },
      "minecraft:ranged_attack": {
        "minecraft:behavior.ranged_attack": {
          "attack_interval_max": 3.0,
          "attack_interval_min": 1.0,
          "attack_radius": 15.0,
          "priority": 0
        },
        "minecraft:environment_sensor": {
          "triggers": [
            {
              "event": "minecraft:melee_mode",
              "filters": {
                "operator": "==",
                "test": "is_underwater",
                "subject": "self",
                "value": true
              }
            },
            {
              "event": "minecraft:melee_mode",
              "filters": {
                "operator": "==",
                "test": "has_ranged_weapon",
                "subject": "self",
                "value": false
              }
            },
            {
              "event": "got_in_powder_snow",
              "filters": {
                "operator": "==",
                "test": "in_block",
                "subject": "self",
                "value": "minecraft:powder_snow"
              }
            }
          ]
        },
        "minecraft:shooter": {
          "def": "minecraft:arrow"
        }
      }
    },
    "events": {
      "become_stray_event": {
        "add": {
          "component_groups": [
            "become_stray"
          ]
        }
      },
      "got_in_powder_snow": {
        "add": {
          "component_groups": [
            "in_powder_snow"
          ]
        }
      },
      "got_out_of_powder_snow": {
        "add": {
          "component_groups": [
            "got_out_of_powder_snow_environment_sensor"
          ]
        },
        "remove": {
          "component_groups": [
            "in_powder_snow"
          ]
        }
      },
      "minecraft:melee_mode": {
        "add": {
          "component_groups": [
            "minecraft:melee_attack"
          ]
        },
        "remove": {
          "component_groups": [
            "minecraft:ranged_attack",
            "got_out_of_powder_snow_environment_sensor"
          ]
        }
      },
      "minecraft:entity_spawned": {
        "add": {
          "component_groups": [
            "minecraft:ranged_attack"
          ]
        }
      },
      "minecraft:ranged_mode": {
        "add": {
          "component_groups": [
            "minecraft:ranged_attack"
          ]
        },
        "remove": {
          "component_groups": [
            "minecraft:melee_attack",
            "got_out_of_powder_snow_environment_sensor"
          ]
        }
      },
      "minecraft:spring_trap": {
        "add": {
          "component_groups": [
            "minecraft:lightning_immune"
          ]
        }
      }
    }
  }
}