{
	"display": {
		"icon": {
			"id": "minecraft:gold_ingot"
		},
		"title": {"translate":"Oh, Shiny!"},
		"description": {"color":"green","translate":"Distract Piglins with gold"},
		"announce_to_chat": true
	},
	"parent": "blazeandcave:nether/what_a_fungi",
	"rewards": {
		"function": "bacap_rewards:nether/oh_shiny"
	},
	"criteria": {
		"distract_piglin": {
			"trigger": "minecraft:thrown_item_picked_up_by_entity",
			"conditions": {
				"player": [
					{
						"condition": "minecraft:inverted",
						"term": {
							"condition": "minecraft:entity_properties",
							"predicate": {
								"equipment": {
									"head": {
										"items": [
										"minecraft:golden_helmet"
									]
									}
								}
							},
							"entity": "this"
						}
					},
					{
						"condition": "minecraft:inverted",
						"term": {
							"condition": "minecraft:entity_properties",
							"predicate": {
								"equipment": {
									"chest": {
										"items": [
										"minecraft:golden_chestplate"
									]
									}
								}
							},
							"entity": "this"
						}
					},
					{
						"condition": "minecraft:inverted",
						"term": {
							"condition": "minecraft:entity_properties",
							"predicate": {
								"equipment": {
									"legs": {
										"items": [
										"minecraft:golden_leggings"
									]
									}
								}
							},
							"entity": "this"
						}
					},
					{
						"condition": "minecraft:inverted",
						"term": {
							"condition": "minecraft:entity_properties",
							"predicate": {
								"equipment": {
									"feet": {
										"items": [
										"minecraft:golden_boots"
									]
									}
								}
							},
							"entity": "this"
						}
					}
				],
				"item": {
					"items": "#minecraft:piglin_loved"
				},
				"entity": [
					{
						"condition": "minecraft:entity_properties",
						"predicate": {
							"entity_type": "minecraft:piglin",
							"flags": {
								"is_baby": false
							}
						},
						"entity": "this"
					}
				]
			}
		},
		"distract_piglin_directly": {
			"trigger": "minecraft:player_interacted_with_entity",
			"conditions": {
				"player": [
					{
						"condition": "minecraft:inverted",
						"term": {
							"condition": "minecraft:entity_properties",
							"predicate": {
								"equipment": {
									"head": {
										"items": [
										"minecraft:golden_helmet"
									]
									}
								}
							},
							"entity": "this"
						}
					},
					{
						"condition": "minecraft:inverted",
						"term": {
							"condition": "minecraft:entity_properties",
							"predicate": {
								"equipment": {
									"chest": {
										"items": [
										"minecraft:golden_chestplate"
									]
									}
								}
							},
							"entity": "this"
						}
					},
					{
						"condition": "minecraft:inverted",
						"term": {
							"condition": "minecraft:entity_properties",
							"predicate": {
								"equipment": {
									"legs": {
										"items": [
										"minecraft:golden_leggings"
									]
									}
								}
							},
							"entity": "this"
						}
					},
					{
						"condition": "minecraft:inverted",
						"term": {
							"condition": "minecraft:entity_properties",
							"predicate": {
								"equipment": {
									"feet": {
										"items": [
										"minecraft:golden_boots"
									]
									}
								}
							},
							"entity": "this"
						}
					}
				],
				"item": {
					"items": "#minecraft:piglin_loved"
				},
				"entity": [
					{
						"condition": "minecraft:entity_properties",
						"predicate": {
							"entity_type": "minecraft:piglin",
							"flags": {
								"is_baby": false
							}
						},
						"entity": "this"
					}
				]
			}
		}
	},
	"requirements": [
		[
			"distract_piglin",
			"distract_piglin_directly"
		]
	]
}
