{
	"format_version": "1.21.0",
	"minecraft:entity": {
		"description": {
			"identifier": "v360:mole",
			"is_spawnable": true,
			"is_summonable": true,
			"is_experimental": false
		},
		"component_groups": {
			"mole_on_ground": {
				"minecraft:timer": {
					"looping": false,
					"time": [
						30,
						60
					],
					"time_down_event": {
						"event": "dig",
						"target": "self"
					}
				},
				"minecraft:collision_box": {
					"width": 0.6,
					"height": 0.3
				},
				"minecraft:interact": {
					"interactions": [
						{
							"on_interact": {
								"filters": {
									"all_of": [
										{
											"any_of": [
												{
													"test": "has_equipment",
													"subject": "other",
													"domain": "hand",
													"value": "bucket:0"
												}
											]
										}
									]
								},
								"event": "despawn"
							},
							"use_item": true,
							"transform_to_item": "v360:bucket_of_mole",
							"interact_text": "action.interact.catch",
							"swing": true,
							"play_sounds": "bucket.fill.fish"
						}
					]
				}
			},
			"mole_in_ground": {
				"minecraft:behavior.random_stroll": {
					"priority": 6,
					"speed_multiplier": 1
				},
				"minecraft:is_sheared": {}
			},
			"look_out": {
				"minecraft:behavior.timer_flag_1": {
					"cooldown_range": [
						10,
						10
					],
					"duration_range": [
						1.1667,
						1.1667
					],
					"priority": 0,
					"on_start": {
						"event": "looking_out",
						"target": "self"
					}
				},
				"minecraft:collision_box": {
					"width": 0.6,
					"height": 0.3
				},
				"minecraft:interact": {
					"interactions": [
						{
							"on_interact": {
								"filters": {
									"all_of": [
										{
											"any_of": [
												{
													"test": "has_equipment",
													"subject": "other",
													"domain": "hand",
													"value": "bucket:0"
												}
											]
										}
									]
								},
								"event": "despawn"
							},
							"use_item": true,
							"transform_to_item": "v360:bucket_of_mole",
							"interact_text": "action.interact.catch",
							"swing": true,
							"play_sounds": "bucket.fill.fish"
						}
					]
				}
			},
			"dig": {
				"minecraft:behavior.timer_flag_2": {
					"priority": 0,
					"cooldown_range": [
						0,
						0
					],
					"duration_range": [
						1.3333,
						1.3333
					],
					"on_end": {
						"event": "digging",
						"target": "self"
					}
				}
			},
			"despawn": {
				"minecraft:instant_despawn": {}
			}
		},
		"components": {
			"minecraft:type_family": {
				"family": [
					"mole",
					"mob"
				]
			},
			"minecraft:breathable": {
				"total_supply": 15,
				"suffocate_time": 0
			},
			"minecraft:nameable": {},
			"minecraft:health": {
				"value": 4,
				"max": 4
			},
			"minecraft:hurt_on_condition": {
				"damage_conditions": [
					{
						"filters": {
							"test": "in_lava",
							"subject": "self",
							"operator": "==",
							"value": true
						},
						"cause": "lava",
						"damage_per_tick": 4
					}
				]
			},
			"minecraft:movement": {
				"value": 0.25
			},
			"minecraft:damage_sensor": {
				"triggers": {
					"cause": "fall",
					"deals_damage": false
				}
			},
			"minecraft:leashable": {
				"soft_distance": 4,
				"hard_distance": 6,
				"max_distance": 10
			},
			"minecraft:balloonable": {
				"mass": 0.6
			},
			"minecraft:navigation.walk": {
				"can_path_over_water": false,
				"avoid_damage_blocks": true
			},
			"minecraft:movement.basic": {},
			"minecraft:jump.static": {},
			"minecraft:can_climb": {},
			"minecraft:behavior.float": {
				"priority": 0
			},
			"minecraft:behavior.mount_pathing": {
				"priority": 2,
				"speed_multiplier": 1.5,
				"target_dist": 0,
				"track_target": true
			},
			"minecraft:behavior.look_at_player": {
				"priority": 7,
				"look_distance": 6,
				"probability": 0.02
			},
			"minecraft:behavior.random_look_around": {
				"priority": 8
			},
			"minecraft:physics": {},
			"minecraft:pushable": {
				"is_pushable": true,
				"is_pushable_by_piston": true
			}
		},
		"events": {
			"minecraft:entity_spawned": {
				"add": {
					"component_groups": [
						"mole_on_ground"
					]
				}
			},
			"dig": {
				"add": {
					"component_groups": [
						"dig"
					]
				},
				"remove": {
					"component_groups": [
						"mole_on_ground"
					]
				}
			},
			"digging": {
				"remove": {
					"component_groups": [
						"dig"
					]
				},
				"add": {
					"component_groups": [
						"mole_in_ground",
						"look_out"
					]
				}
			},
			"despawn": {
				"add": {
					"component_groups": [
						"despawn"
					]
				}
			},
			"looking_out": {
				"queue_command": {
					"command": "playanimation @s animation.mole.looking_out",
					"target": "self"
				}
			}
		}
	}
}