{
	"display": {
		"icon": {
			"id": "minecraft:black_wool"
		},
		"title": {"translate":"Blind as a Bat"},
		"description": {"color":"dark_purple","translate":"Kill a Bat while under the blindness or darkness effect"},
		"announce_to_chat": true,
		"frame": "challenge"
	},
	"parent": "blazeandcave:mining/nananananananana",
	"rewards": {
		"function": "bacap_rewards:mining/blind_as_a_bat"
	},		
	"criteria": {
		"blind_as_a_bat": {
			"trigger": "minecraft:player_killed_entity",
			"conditions": {
				"entity": {
					"entity_type": "bat"
				},
				"player": [
					{
						"condition": "minecraft:any_of",
						"terms": [
							{
								"condition": "minecraft:entity_properties",
								"entity": "this",
								"predicate": {
									"effects": {
										"minecraft:blindness": {
											"amplifier": {
												"min": 0
											}
										}
									}
								}
							},
							{
								"condition": "minecraft:entity_properties",
								"entity": "this",
								"predicate": {
									"effects": {
										"minecraft:darkness": {
											"amplifier": {
												"min": 0
											}
										}
									}
								}
							}
						]
					}
				]
			}
		}
	}
}
