用户:
Henry_嘟查看:1 回复:1 评论:1 创建时间:2022-10-25T16:42:44
const npc = world.querySelector('#NPC');
npc.enableInteract = true;
npc.interactRadius = 16;
npc.interactHint = npc.id;
npc.interactColor = new Box3RGBColor(1,0,1);
// 玩家与实体进行交互时触发
npc.onInteract(async({entity}) => {
// <------------------------在这加
});