{
  "format_version": "1.13.0",
  "minecraft:entity": {
    "description": {
      "identifier": "minecraft:shulker",
      "is_spawnable": true,
      "is_summonable": true,
      "is_experimental": false
    },
    "component_groups": {
      "minecraft:shulker_purple": {
        "minecraft:variant": {
          "value": 5
        }
      },
      "minecraft:shulker_black": {
        "minecraft:variant": {
          "value": 0
        }
      },
      "minecraft:shulker_blue": {
        "minecraft:variant": {
          "value": 4
        }
      },
      "minecraft:shulker_brown": {
        "minecraft:variant": {
          "value": 3
        }
      },
      "minecraft:shulker_cyan": {
        "minecraft:variant": {
          "value": 6
        }
      },
      "minecraft:shulker_gray": {
        "minecraft:variant": {
          "value": 8
        }
      },
      "minecraft:shulker_green": {
        "minecraft:variant": {
          "value": 2
        }
      },
      "minecraft:shulker_light_blue": {
        "minecraft:variant": {
          "value": 12
        }
      },
      "minecraft:shulker_lime": {
        "minecraft:variant": {
          "value": 10
        }
      },
      "minecraft:shulker_magenta": {
        "minecraft:variant": {
          "value": 13
        }
      },
      "minecraft:shulker_orange": {
        "minecraft:variant": {
          "value": 14
        }
      },
      "minecraft:shulker_pink": {
        "minecraft:variant": {
          "value": 9
        }
      },
      "minecraft:shulker_red": {
        "minecraft:variant": {
          "value": 1
        }
      },
      "minecraft:shulker_silver": {
        "minecraft:variant": {
          "value": 7
        }
      },
      "minecraft:shulker_undyed": {
        "minecraft:variant": {
          "value": 16
        }
      },
      "minecraft:shulker_white": {
        "minecraft:variant": {
          "value": 15
        }
      },
      "minecraft:shulker_yellow": {
        "minecraft:variant": {
          "value": 11
        }
      }
    },

    "components": {
      "minecraft:experience_reward": {
        "on_death": "query.last_hit_by_player ? 5 : 0"
      },
      "minecraft:type_family": {
        "family": [ "shulker", "monster", "mob" ]
      },
      "minecraft:breathable": {
        "total_supply": 15,
        "suffocate_time": 0
      },
      "minecraft:nameable": {
      },
      "minecraft:health": {
        "value": 30,
        "max": 30
      },
      "minecraft:hurt_on_condition": {
        "damage_conditions": [
          {
            "filters": { "test": "in_lava", "subject": "self", "operator": "==", "value": true },
            "cause": "lava",
            "damage_per_tick": 4
          }
        ]
      },
      "minecraft:movement": {
        "value": 0.0,
        "max": 0.0
      },
      "minecraft:loot": {
        "table": "loot_tables/entities/basic.json"
      },
      "minecraft:peek": {
        "on_open": {
          "event": "minecraft:on_open"
        },
        "on_close": {
          "event": "minecraft:on_close"
        },
        "on_target_open": {
          "event": "minecraft:on_open"
        }
      },
      "minecraft:behavior.look_at_player": {
        "priority": 1,
        "look_distance": 6.0,
        "probability": 0.02
      },
      "minecraft:shooter": {
        "type": "ShulkerBullet",
        "def": "minecraft:shulker_bullet"
      },
      "minecraft:behavior.random_look_around": {
        "priority": 8
      },
      "minecraft:behavior.ranged_attack": {
        "attack_interval_min": 1,
        "attack_interval_max": 3,
        "attack_radius": 15
      },
      "minecraft:behavior.hurt_by_target": {
        "priority": 2
      },
      "minecraft:behavior.nearest_attackable_target": {
        "priority": 3,
        "entity_types": {
          "filters": { "test" :  "is_family", "subject" : "other", "value" :  "player"},
          "max_dist": 16
        },
        "must_see": true
      },
      "minecraft:navigation.walk": {
      },
      "minecraft:movement.basic": {
      },
      "minecraft:interact": {
        "interactions": [
          {
            "on_interact": {
              "filters": {
                  "all_of": [
                    {
                      "any_of": [
                        { "test": "has_equipment", "subject": "other", "domain": "hand", "value": "dye:0"},
                        { "test": "has_equipment", "subject": "other", "domain": "hand", "value": "dye:16"}
                      ]
                    },
                    { "test" :  "is_family", "subject" : "other", "value" :  "player"},
                    { "test" :  "has_ability","subject" : "other", "value" :  "instabuild"}
                  ]
              },
              "event": "minecraft:turn_black"
            },
            "use_item": true
          },
          {
            "on_interact": {
              "filters": {
                  "all_of": [
                    { "test": "has_equipment", "subject": "other", "domain": "hand", "value": "dye:8"},
                    { "test" :  "is_family", "subject" : "other", "value" :  "player"},
                    { "test" :  "has_ability","subject" : "other", "value" :  "instabuild"}
                  ]
              },
              "event": "minecraft:turn_gray"
            },
            "use_item": true
          },
          {
            "on_interact": {
              "filters": {
                  "all_of": [
                    { "test": "has_equipment", "subject": "other", "domain": "hand", "value": "dye:7"},
                    { "test" :  "is_family", "subject" : "other", "value" :  "player"},
                    { "test" :  "has_ability","subject" : "other", "value" :  "instabuild"}
                  ]
              },
              "event": "minecraft:turn_silver"
            },
            "use_item": true
          },
          {
            "on_interact": {
              "filters": {
                  "all_of": [
                    {
                      "any_of": [
                        { "test": "has_equipment", "subject": "other", "domain": "hand", "value": "dye:15"},
                        { "test": "has_equipment", "subject": "other", "domain": "hand", "value": "dye:19"}
                      ]
                    },
                    { "test" :  "is_family", "subject" : "other", "value" :  "player"},
                    { "test" :  "has_ability","subject" : "other", "value" :  "instabuild"}
                  ]
              },
              "event": "minecraft:turn_white"
            },
            "use_item": true
          },
          {
            "on_interact": {
              "filters": {
                  "all_of": [
                    { "test": "has_equipment", "subject": "other", "domain": "hand", "value": "dye:12"},
                    { "test" :  "is_family", "subject" : "other", "value" :  "player"},
                    { "test" :  "has_ability","subject" : "other", "value" :  "instabuild"}
                  ]
              },
              "event": "minecraft:turn_light_blue"
            },
            "use_item": true
          },
          {
            "on_interact": {
              "filters": {
                  "all_of": [
                    { "test": "has_equipment", "subject": "other", "domain": "hand", "value": "dye:14"},
                    { "test" :  "is_family", "subject" : "other", "value" :  "player"},
                    { "test" :  "has_ability","subject" : "other", "value" :  "instabuild"}
                  ]
              },
              "event": "minecraft:turn_orange"
            },
            "use_item": true
          },
          {
            "on_interact": {
              "filters": {
                  "all_of": [
                    { "test": "has_equipment", "subject": "other", "domain": "hand", "value": "dye:1"},
                    { "test" :  "is_family", "subject" : "other", "value" :  "player"},
                    { "test" :  "has_ability","subject" : "other", "value" :  "instabuild"}
                  ]
              },
              "event": "minecraft:turn_red"
            },
            "use_item": true
          },
          {
            "on_interact": {
              "filters": {
                  "all_of": [
                    {
                      "any_of": [
                        { "test": "has_equipment", "subject": "other", "domain": "hand", "value": "dye:4"},
                        { "test": "has_equipment", "subject": "other", "domain": "hand", "value": "dye:18"}
                      ]
                    },
                    { "test" :  "is_family", "subject" : "other", "value" :  "player"},
                    { "test" :  "has_ability","subject" : "other", "value" :  "instabuild"}
                  ]
              },
              "event": "minecraft:turn_blue"
            },
            "use_item": true
          },
          {
            "on_interact": {
              "filters": {
                  "all_of": [
                    { "test": "has_equipment", "subject": "other", "domain": "hand", "value": "dye:5"},
                    { "test" :  "is_family", "subject" : "other", "value" :  "player"},
                    { "test" :  "has_ability","subject" : "other", "value" :  "instabuild"}
                  ]
              },
              "event": "minecraft:turn_purple"
            },
            "use_item": true
          },
          {
            "on_interact": {
              "filters": {
                  "all_of": [
                    { "test": "has_equipment", "subject": "other", "domain": "hand", "value": "dye:13"},
                    { "test" :  "is_family", "subject" : "other", "value" :  "player"},
                    { "test" :  "has_ability","subject" : "other", "value" :  "instabuild"}
                  ]
              },
              "event": "minecraft:turn_magenta"
            },
            "use_item": true
          },
          {
            "on_interact": {
              "filters": {
                  "all_of": [
                    { "test": "has_equipment", "subject": "other", "domain": "hand", "value": "dye:9"},
                    { "test" :  "is_family", "subject" : "other", "value" :  "player"},
                    { "test" :  "has_ability","subject" : "other", "value" :  "instabuild"}
                  ]
              },
              "event": "minecraft:turn_pink"
            },
            "use_item": true
          },
          {
            "on_interact": {
              "filters": {
                  "all_of": [
                    {
                      "any_of": [
                        { "test": "has_equipment", "subject": "other", "domain": "hand", "value": "dye:3"},
                        { "test": "has_equipment", "subject": "other", "domain": "hand", "value": "dye:17"}
                      ]
                    },
                    { "test" :  "is_family", "subject" : "other", "value" :  "player"},
                    { "test" :  "has_ability","subject" : "other", "value" :  "instabuild"}
                  ]
              },
              "event": "minecraft:turn_brown"
            },
            "use_item": true
          },
          {
            "on_interact": {
              "filters": {
                  "all_of": [
                    { "test": "has_equipment", "subject": "other", "domain": "hand", "value": "dye:11"},
                    { "test" :  "is_family", "subject" : "other", "value" :  "player"},
                    { "test" :  "has_ability","subject" : "other", "value" :  "instabuild"}
                  ]
              },
              "event": "minecraft:turn_yellow"
            },
            "use_item": true
          },
          {
            "on_interact": {
              "filters": {
                  "all_of": [
                    { "test": "has_equipment", "subject": "other", "domain": "hand", "value": "dye:10"},
                    { "test" :  "is_family", "subject" : "other", "value" :  "player"},
                    { "test" :  "has_ability","subject" : "other", "value" :  "instabuild"}
                  ]
              },
              "event": "minecraft:turn_lime"
            },
            "use_item": true
          },
          {
            "on_interact": {
              "filters": {
                  "all_of": [
                    { "test": "has_equipment", "subject": "other", "domain": "hand", "value": "dye:2"},
                    { "test" :  "is_family", "subject" : "other", "value" :  "player"},
                    { "test" :  "has_ability","subject" : "other", "value" :  "instabuild"}
                  ]
              },
              "event": "minecraft:turn_green"
            },
            "use_item": true
          },
          {
            "on_interact": {
              "filters": {
                  "all_of": [
                    { "test": "has_equipment", "subject": "other", "domain": "hand", "value": "dye:6"},
                    { "test" :  "is_family", "subject" : "other", "value" :  "player"},
                    { "test" :  "has_ability","subject" : "other", "value" :  "instabuild"}
                  ]
              },
              "event": "minecraft:turn_cyan"
            },
            "use_item": true
          }
        ]
      },
      "minecraft:physics": {
      }
    },

    "events": {
      "minecraft:entity_spawned": {
        "add": {
          "component_groups": [
            "minecraft:shulker_undyed"
          ]
        }
      },
      "minecraft:turn_purple": {
        "add": {
          "component_groups": [
            "minecraft:shulker_purple"
          ]
        }
      },
      "minecraft:turn_black": {
        "add": {
          "component_groups": [
            "minecraft:shulker_black"
          ]
        }
      },
      "minecraft:turn_blue": {
        "add": {
          "component_groups": [
            "minecraft:shulker_blue"
          ]
        }
      },
      "minecraft:turn_brown": {
        "add": {
          "component_groups": [
            "minecraft:shulker_brown"
          ]
        }
      },
      "minecraft:turn_cyan": {
        "add": {
          "component_groups": [
            "minecraft:shulker_cyan"
          ]
        }
      },
      "minecraft:turn_gray": {
        "add": {
          "component_groups": [
            "minecraft:shulker_gray"
          ]
        }
      },
      "minecraft:turn_green": {
        "add": {
          "component_groups": [
            "minecraft:shulker_green"
          ]
        }
      },
      "minecraft:turn_light_blue": {
        "add": {
          "component_groups": [
            "minecraft:shulker_light_blue"
          ]
        }
      },
      "minecraft:turn_lime": {
        "add": {
          "component_groups": [
            "minecraft:shulker_lime"
          ]
        }
      },
      "minecraft:turn_magenta": {
        "add": {
          "component_groups": [
            "minecraft:shulker_magenta"
          ]
        }
      },
      "minecraft:turn_orange": {
        "add": {
          "component_groups": [
            "minecraft:shulker_orange"
          ]
        }
      },
      "minecraft:turn_pink": {
        "add": {
          "component_groups": [
            "minecraft:shulker_pink"
          ]
        }
      },
      "minecraft:turn_red": {
        "add": {
          "component_groups": [
            "minecraft:shulker_red"
          ]
        }
      },
      "minecraft:turn_silver": {
        "add": {
          "component_groups": [
            "minecraft:shulker_silver"
          ]
        }
      },
      "minecraft:turn_white": {
        "add": {
          "component_groups": [
            "minecraft:shulker_white"
          ]
        }
      },
      "minecraft:turn_yellow": {
        "add": {
          "component_groups": [
            "minecraft:shulker_yellow"
          ]
        }
      }
    }
  }
}
