{
	"format_version": "1.18.0",
	"minecraft:entity": {
		"description": {
			"identifier": "ldz:dungeon_lever",
			"is_spawnable": false,
			"is_summonable": true,
			"is_experimental": false,
			"animations": {
				"animation_delay": "animation.dungeon_lever.animation_delay",
				"duplication_check": "animation.dungeon_lever.duplication_check",
				"effects_clear_clock": "animation.inanimate_entity.effect_clear_clock",
				"ctrl.interacted": "controller.animation.dungeon_lever.interacted",
				"ctrl.powered_state": "controller.animation.dungeon_lever.powered_state"
			},
			"scripts": {
				"animate": [
					{ "duplication_check": "q.is_tamed" },
					"effects_clear_clock",
					"ctrl.interacted",
					"ctrl.powered_state"
				]
			},
			"properties": {
				"ldz:block_attached": {
					"type": "enum",
					"default": "negative_y",
					"values": [
						"negative_x",
						"negative_y",
						"negative_z",
						"positive_x",
						"positive_y",
						"positive_z"
					],
					"client_sync": true
				},
				"ldz:interacted": {
					"type": "bool",
					"default": false,
					"client_sync": true
				},
				"ldz:invisible": {
					"type": "bool",
					"default": false,
					"client_sync": true
				},
				"ldz:powered": {
					"type": "bool",
					"default": false,
					"client_sync": true
				},
				"ldz:rotation": {
					"type": "int",
					"default": 0,
					"range": [ 0, 359 ],
					"client_sync": true
				},
				"ldz:triggered": {
					"type": "bool",
					"default": false,
					"client_sync": true
				}
			}
		},
		"component_groups": {
			"instant_despawn": {
				"minecraft:instant_despawn": {}
			},
			"duplication_check_toggle": {
				"minecraft:is_tamed": {}
			},
			"portal_room": {
				"minecraft:type_family": {
					"family": [ "ldz", "dungeon_lever", "portal_room_lever" ]
				}
			},
			"beast_hub": {
				"minecraft:type_family": {
					"family": [ "ldz", "dungeon_lever", "beast_lever", "beast_lever_hub" ]
				}
			},
			"beast_dungeon": {
				"minecraft:type_family": {
					"family": [ "ldz", "dungeon_lever", "beast_lever", "beast_lever_dungeon" ]
				}
			},
			"mystic_hub": {
				"minecraft:type_family": {
					"family": [ "ldz", "dungeon_lever", "mystic_lever", "mystic_lever_hub" ]
				}
			},
			"mystic_dungeon": {
				"minecraft:type_family": {
					"family": [ "ldz", "dungeon_lever", "mystic_lever", "mystic_lever_dungeon" ]
				}
			},
			"scourge_hub": {
				"minecraft:type_family": {
					"family": [ "ldz", "dungeon_lever", "scourge_lever", "scourge_lever_hub" ]
				}
			},
			"scourge_dungeon": {
				"minecraft:type_family": {
					"family": [ "ldz", "dungeon_lever", "scourge_lever", "scourge_lever_dungeon" ]
				}
			},
			"wraith_hub": {
				"minecraft:type_family": {
					"family": [ "ldz", "dungeon_lever", "wraith_lever", "wraith_lever_hub" ]
				}
			},
			"wraith_dungeon": {
				"minecraft:type_family": {
					"family": [ "ldz", "dungeon_lever", "wraith_lever", "wraith_lever_dungeon" ]
				}
			},
			"add_bob_arrow": {
				"minecraft:rideable": {
					"controlling_seat": 0,
					"crouching_skip_interact": true,
					"family_types": [
						"bob_arrow"
					],
					"seat_count": 1,
					"seats": [
						{
							"position": [ 0, 1.0, 0.1 ]
						}
					]
				},
				"minecraft:addrider": {
					"entity_type": "ldz:bob_arrow"
				}
			}
		},
		"components": {
			"minecraft:type_family": {
				"family": [ "ldz", "dungeon_lever" ]
			},
			"minecraft:collision_box": {
				"height": 0,
				"width": 0
			},
			"minecraft:knockback_resistance": {
				"value": 100,
				"maximum": 100
			},
			"minecraft:fire_immune": {},
			"minecraft:custom_hit_test": {
				"hitboxes": [
					{
						"width": 1,
						"height": 1,
						"pivot": [ 0, 0.5, 0 ]
					}
				]
			},
			"minecraft:interact": {
				"interactions": [
					{
						"interact_text": "action.interact.dungeon_lever",
						"on_interact": {
							"filters": [
								{
									"all_of": [
										{ "test": "bool_property", "domain": "ldz:invisible", "value": false },
										{ "test": "bool_property", "domain": "ldz:interacted", "value": false },
										{ "test": "bool_property", "domain": "ldz:triggered", "value": false },
										{ "test": "distance_to_nearest_player", "operator": "<", "value": 5 }
									]
								}
							],
							"event": "set_interacted_to_true"
						}
					}
				]
			},
			"minecraft:damage_sensor": {
				"triggers": [
					{
						"on_damage": {
							"filters": {
								"test": "has_damage",
								"value": "void"
							},
							"event": "despawn"
						},
						"deals_damage": false
					},
					{
						"cause": "all",
						"deals_damage": false
					}
				]
			},
			"minecraft:physics": {
				"has_collision": false,
				"has_gravity": false
			},
			"minecraft:pushable": {
				"is_pushable": false,
				"is_pushable_by_piston": false
			}
		},
		"events": {
			"portal_room": {
				"add": {
					"component_groups": [
						"duplication_check_toggle",
						"portal_room"
					]
				},
				"set_property": {
					"ldz:invisible": true,
					"ldz:block_attached": "negative_z",
					"ldz:rotation": 180
				}
			},
			"beast_hub": {
				"add": {
					"component_groups": [
						"duplication_check_toggle",
						"beast_hub"
					]
				},
				"set_property": {
					"ldz:block_attached": "positive_z"
				}
			},
			"beast_dungeon": {
				"add": {
					"component_groups": [
						"duplication_check_toggle",
						"beast_dungeon"
					]
				}
			},
			"mystic_hub": {
				"add": {
					"component_groups": [
						"duplication_check_toggle",
						"mystic_hub"
					]
				},
				"set_property": {
					"ldz:block_attached": "positive_x",
					"ldz:rotation": 270
				}
			},
			"mystic_dungeon": {
				"add": {
					"component_groups": [
						"duplication_check_toggle",
						"mystic_dungeon"
					]
				},
				"set_property": {
					"ldz:rotation": 225
				}
			},
			"scourge_hub": {
				"add": {
					"component_groups": [
						"duplication_check_toggle",
						"scourge_hub"
					]
				},
				"set_property": {
					"ldz:block_attached": "negative_z",
					"ldz:rotation": 180
				}
			},
			"scourge_dungeon": {
				"add": {
					"component_groups": [
						"duplication_check_toggle",
						"scourge_dungeon"
					]
				},
				"set_property": {
					"ldz:rotation": 180
				}
			},
			"wraith_hub": {
				"add": {
					"component_groups": [
						"duplication_check_toggle",
						"wraith_hub"
					]
				},
				"set_property": {
					"ldz:block_attached": "negative_x",
					"ldz:rotation": 90
				}
			},
			"wraith_dungeon": {
				"add": {
					"component_groups": [
						"duplication_check_toggle",
						"wraith_dungeon"
					]
				},
				"set_property": {
					"ldz:rotation": 90
				}
			},
			"add_bob_arrow": {
				"add": {
					"component_groups": [
						"add_bob_arrow"
					]
				}
			},
			"remove_duplication_check_toggle": {
				"remove": {
					"component_groups": [
						"duplication_check_toggle"
					]
				}
			},
			"set_invisible_to_true": {
				"set_property": {
					"ldz:invisible": true
				}
			},
			"set_invisible_to_false": {
				"set_property": {
					"ldz:invisible": false
				}
			},
			"set_interacted_to_true": {
				"set_property": {
					"ldz:interacted": true
				}
			},
			"set_interacted_to_false": {
				"set_property": {
					"ldz:interacted": false
				}
			},
			"set_triggered_to_true": {
				"set_property": {
					"ldz:triggered": true
				}
			},
			"set_triggered_to_false": {
				"set_property": {
					"ldz:triggered": false
				}
			},
			"set_powered_to_true": {
				"set_property": {
					"ldz:powered": true
				}
			},
			"set_powered_to_false": {
				"set_property": {
					"ldz:powered": false
				}
			},
			"set_rotation_to_0": {
				"set_property": {
					"ldz:rotation": 0
				}
			},
			"set_rotation_to_45": {
				"set_property": {
					"ldz:rotation": 45
				}
			},
			"set_rotation_to_90": {
				"set_property": {
					"ldz:rotation": 90
				}
			},
			"set_rotation_to_135": {
				"set_property": {
					"ldz:rotation": 135
				}
			},
			"set_rotation_to_180": {
				"set_property": {
					"ldz:rotation": 180
				}
			},
			"set_rotation_to_225": {
				"set_property": {
					"ldz:rotation": 225
				}
			},
			"set_rotation_to_270": {
				"set_property": {
					"ldz:rotation": 270
				}
			},
			"set_rotation_to_315": {
				"set_property": {
					"ldz:rotation": 315
				}
			},
			"set_block_attached_to_negative_x": {
				"set_property": {
					"ldz:block_attached": "negative_x"
				}
			},
			"set_block_attached_to_negative_y": {
				"set_property": {
					"ldz:block_attached": "negative_y"
				}
			},
			"set_block_attached_to_negative_z": {
				"set_property": {
					"ldz:block_attached": "negative_z"
				}
			},
			"set_block_attached_to_positive_x": {
				"set_property": {
					"ldz:block_attached": "positive_x"
				}
			},
			"set_block_attached_to_positive_y": {
				"set_property": {
					"ldz:block_attached": "positive_y"
				}
			},
			"set_block_attached_to_positive_z": {
				"set_property": {
					"ldz:block_attached": "positive_z"
				}
			},
			"despawn": {
				"add": {
					"component_groups": [
						"instant_despawn"
					]
				}
			}
		}
	}
}