
export function heldItem(source, item) {
    const equipment = source.getComponent("minecraft:equippable");
    const heldItem = equipment.getEquipment("Mainhand");
    return heldItem?.typeId === `${item}`;
}