{
  "format_version": "1.21.0",
  "minecraft:entity": {
    "description": {
      "identifier": "structure:starter",
      "is_spawnable": true,
      "is_summonable": true,
      "is_experimental": false
    },
    "component_groups": {
      "despawn": {
        "minecraft:instant_despawn": {}
      }
    },
    "components": {
      "minecraft:timer": {
        "time": 0.1,
        "time_down_event": {
          "event": "despawn",
          "target": "self"
        }
      },
      "minecraft:physics": {},
      "minecraft:type_family": {
        "family": [
          "inanimate"
        ]
      },
      "minecraft:damage_sensor": {
        "triggers": [
          {
            "on_damage": {
              "filters": {
                "all_of": [
                  {
                    "test": "is_family",
                    "subject": "other",
                    "operator": "!=",
                    "value": "kyoto"
                  }
                  ]
              }
            },
          "deals_damage": false,
          "damage_multiplier": 0.0
          }
          ]
        },
      "minecraft:health": {
        "value": 10000,
        "max": 10000,
        "min": 10000
      },
      "minecraft:on_death":  {
        "event":  "despawn",
        "target":  "self"
      },
      "minecraft:collision_box": {
        "width": 0.05,
        "height": 0.05
      },
      "minecraft:pushable": {
        "is_pushable": false,
        "is_pushable_by_piston": false
      },
      "minecraft:knockback_resistance": {
        "value": 100.0
      }
    },
    "events": {
      "minecraft:entity_spawned": {
        "sequence": [
          {
            "queue_command": {
              "command": [
                "spreadplayers ~ ~ 2 3 @p",
                "scoreboard objectives add structure dummy",
                "scoreboard players add Starter structure 0",
                "scoreboard players add @p structure 0"
                ]
            }
          },
          {
            "queue_command": {
              "command": [
                "scoreboard players operation @p structure = Starter structure"
                ]
            }
          },
          {
            "queue_command": {
              "command": [
                "execute as @p[scores={structure=0}] run function structures/starter"
                ]
            }
          },
          {
            "queue_command": {
              "command": [
                "scoreboard players set Starter structure 1"
                ]
            }
          }
          ]
      },
      "despawn": {
        "add": {
          "component_groups": [
            "despawn"
          ]
        }
      }
    }
  }
}