{
    "format_version": "1.16.100",
    "minecraft:item": {
        "description": {
            "identifier": "hog_iron_loaded:crossbow",
            "category": "commands"
        },
        "components": {
            "minecraft:icon": {
                "texture": "iron_crossbow_loaded"
            },
            "minecraft:display_name": {
                "value": "Iron Crossbow"
            },
            "minecraft:durability": {
                "max_durability": 600
            },
            "minecraft:max_stack_size": 1,
            "tag:hog:crossbow": {},
            "minecraft:repairable": {
                "repair_items": [
                    "iron_ingot"
                ]
            },
            "minecraft:on_use": {
                "on_use": {
                    "event": "shoot_arrow"
                }
            },
            "minecraft:enchantable": {
                "slot": "crossbow",
                "value": 15
            },
            "minecraft:use_duration": 2
        },
        "events": {
            "shoot_arrow": {
            "shoot": {
                "projectile": "hog:iron_arrow",
                "launch_power": 1,
                "angle_offset": 0
            },
            "run_command": {
                "command": "replaceitem entity @s slot.weapon.mainhand 0 hog_iron_unloaded:crossbow"
            }}
        }
    }
}