猫史档案馆


跳跃加成的代码是什么???

用户:整活的网友整活的网友查看:6 回复:5 评论:6 创建时间:2023-01-17T10:43:21


Forest.onInteract(async({entity}) => {
    const result = await entity.player.dialog({
        type: Box3DialogType.TEXT,   
        title: Forest.id,               
        lookEye: entity,             
        lookTarget: Forest,             
        content: `你好,${entity.player.name},我这里也没什么,就送你跳跃加成吧`,
    });
});


回复

上一页1 页 / 共 1下一页
整活的网友整活的网友

entity.player.jumpPower = 2;//加上为什么会报错

 

点赞0


评论


整活的网友整活的网友

总之删掉就正常了

点赞0


评论


整活的网友整活的网友

unexpected token'.'

点赞0


评论


整活的网友整活的网友

Forest.onInteract(async({entity}) => {
    const result = await entity.player.dialog({
        type: Box3DialogType.TEXT,   // 对话框的类型,TEXT是文本框。
        title: Forest.id,               // 对话框标题为NPC名字,表示正在说话的是NPC
        lookEye: entity,             // 将相机放在玩家位置
        lookTarget: Forest,             // 相机镜头对准NPC
        content: `你好,${entity.player.name},我这里也没什么,就送你跳跃加成吧`,
        entity.player.jumpPower = 2;
    });
});

点赞0


评论


清瞑月风GUI清瞑月风GUI

Forest.onInteract(async({entity}) => {
    const result = await entity.player.dialog({
        type: Box3DialogType.TEXT,   // 对话框的类型,TEXT是文本框。
        title: Forest.id,               // 对话框标题为NPC名字,表示正在说话的是NPC
        lookEye: entity,             // 将相机放在玩家位置
        lookTarget: Forest,             // 相机镜头对准NPC
        content: `你好,${entity.player.name},我这里也没什么,就送你跳跃加成吧`,
    });
    entity.player.jumpPower = 2;//试试这个
});

点赞0


评论