import { ItemStack, Player } from "@minecraft/server";
import { guideMainView } from "../../../views/items/guideViews/guideMainView";

/**
 * Evento onUse del componente guideComponent
 * Addon: Electrical Creativity BP
 * @param {{itemStack: ItemStack, source: Player}} event 
 */
export const guideOnUseEvent = ({itemStack, source}) => {
    try {
        source.runCommand(`playsound digital.spawn @s`)
        guideMainView(source);
    } catch { }
}