{
  "$id": "blockception.minecraft.behavior.entities.1.8.0.minecraft.damage_sensor",
  "title": "Damage Sensor 1.8.0",
  "additionalProperties": false,
  "description": "Defines what events to call when this entity is damaged by specific entities or items.",
  "type": "object",
  "definitions": {
    "damagespec": {
      "type": "object",
      "description": "A trigger with the events to call when taking specific kinds of damage.",
      "additionalProperties": false,
      "title": "Damage Trigger",
      "properties": {
        "cause": {
          "type": "string",
          "default": "none",
          "description": "Type of damage that triggers the events.",
          "$ref": "../../../../general/entity_damage.json",
          "title": "Cause"
        },
        "deals_damage": {
          "type": "boolean",
          "default": true,
          "description": "If true, the damage dealt to the entity will take away health from it, set to false to make the entity ignore that damage.",
          "title": "Deals Damage"
        },
        "on_damage": {
          "additionalProperties": false,
          "type": "object",
          "description": "Specifies filters for entity definitions and events.",
          "title": "On Damage",
          "$ref": "../types/trigger.json"
        }
      }
    }
  },
  "required": [],
  "oneOf": [
    { "type": "object", "$ref": "#/definitions/damagespec" },
    { "type": "array", "items": { "$ref": "#/definitions/damagespec" } }
  ]
}
