{
  "criteria": {
    "requirement": {
      "trigger": "minecraft:tick",
      "conditions": {
        "player": [
          {
            "condition": "minecraft:all_of",
            "terms": [
              {
                "condition": "minecraft:inverted",
                "term": {
                  "condition": "minecraft:entity_properties",
                  "entity": "this",
                  "predicate": {
                    "nbt": "{Health:0f}"
                  }
                }
              },
              {
                "condition": "minecraft:any_of",
                "terms": [
                  {
                    "condition": "minecraft:entity_properties",
                    "entity": "this",
                    "predicate": {
                      "nbt": "{Tags:[keepitem]}"
                    }
                  },
                  {
                    "condition": "minecraft:entity_properties",
                    "entity": "this",
                    "predicate": {
                      "nbt": "{Tags:[cursehelm]}"
                    }
                  },
                  {
                    "condition": "minecraft:entity_properties",
                    "entity": "this",
                    "predicate": {
                      "nbt": "{Tags:[corpserun]}"
                    }
                  }
                ]
              }
            ]
          }
        ]
      }
    }
  },
  "rewards": {
    "function": "survivalplus:tools/keepitem"
  }
}