猫史档案馆


坦率的血翼蝠5801

坦率的血翼蝠5801

Lv.1

!!!!!

获赞:21收藏:1浏览:195作品收藏:2
回复帖子评论
上一页11 页 / 共 11下一页

问吉吉猫一个问题 中回复

world.onPlayerJoin(async({entity}) => {
    entity.player.onPress(({ entity, button }) => {
        if (button == 'action1'){
            const bag = await entity.player.dialog({
                type: Box3DialogType.SELECT,
                title: `背包`,
                content: `请问你喵还是剑?`,
                options: ['喵', '剑']
            })
            if (!bag || bag == null) return;
            switch (bag.index){
                case 0:
                    entity.wuqi = '喵'
                    entity.gjl = 80
                    break;
                case 1:
                    entity.wuqi = '剑'
                    entity.gjl = 20
                    break;
                default:
            }
        }
    })
})

2022-05-05T18:41:48 点赞:0

【box3】玩家查询系统代码分享! 中回复

dddddddddddddddddddddd

2022-05-05T18:48:47 点赞:0

发射一个模型【简陋教程】 中回复

console.clear()
const Quat = new Box3Quaternion(0,0,0,1)
world.onRelease(async ({entity, button, raycast:{direction}}) => { 
//每当有按钮被按下
     if (button == Box3ButtonType.ACTION0) {
         const 喵 = world.createEntity({
             mesh:'发射模型',
             position:entity.position,
             meshScale:new Box3Vector3(0.1, 0.1, 0.1),
             collides:false
         })
         喵.gravity = false
         const 喵_orientation = Quat.rotateY(Math.atan2(direction.z, direction.x)).rotateY(-Math.PI / 2).rotateY(-Math.PI / 2)
         喵.meshOrientation.copy(喵_orientation)
         for(i = 0; i <= 4; i++){
             喵.position.x += direction.x
             喵.position.z += direction.z
             await sleep(200)
         }
         await sleep(1000)
         喵.destroy()
     }
 })
world.onPlayerJoin(({ entity }) => {
    entity.player.addWearable({
        bodyPart: Box3BodyPart.RIGHT_HAND,
        mesh: '装饰',
        orientation: new Box3Quaternion(0, 180, 60, -160).rotateY(Math.PI / 2.5),
        scale: new Box3Vector3(1, 1, 1), offset: new Box3Vector3(0, 0.2, 0.6), 
    })
})

2022-05-05T18:54:58 点赞:0

【box3】古风小亭子速建代码 中回复

👍

2022-05-05T20:45:38 点赞:0

谁知道怎么初始化地图???(二创急需) 中回复

while(1){}

2022-05-06T22:55:20 点赞:0

【岛三】面朝大海,春暖花开,送给热爱那个橙喵案创作按钮的人 中回复

ddddddddddddddddddddddddddddd!顺带一个沙发

2022-05-06T23:00:17 点赞:0

【岛3创作节】听说这里有全岛第一个会发亮的年兽皮肤! 中回复

👍

2022-05-07T20:29:09 点赞:0

嗯~凑字,东西看下面 中回复

申请代码

2022-05-07T20:29:56 点赞:0

【神岛】岛3第一个跑酷地图是哪张?() 中回复

一起跑酷

2022-05-07T20:31:12 点赞:0

求助!急急急!怎么建地图啊,我想做个跑酷 中回复

额,你发个链接,我可以试试帮你

2022-05-07T20:33:50 点赞:0

求助!急急急!怎么建地图啊,我想做个跑酷 中回复

首先:你要有编辑器权限,不然都是白搭

2022-05-07T20:34:10 点赞:0

有大神能解答吗 中回复

我要写一遍吗?

2022-05-07T20:35:50 点赞:0

有大神能解答吗 中回复

// 先在场景中放置一个名称为 NPC 的实体。
const npc = world.querySelector('#NPC');
npc.enableInteract = true; // 允许进行互动
npc.interactRadius = 16;   // 实体的互动范围
npc.interactHint = npc.id; // 互动提示框显示实体的名称

// 玩家与实体进行交互时触发
npc.onInteract(async({entity}) => {
    await entity.player.dialog({
        type: Box3DialogType.TEXT,   // 对话框的类型,TEXT是文本框。
        title: npc.id,               // 对话框标题为NPC名字,表示正在说话的是NPC
        content: `你好,${entity.player.name},很高兴认识你。`,
    });
});

2022-05-07T20:37:05 点赞:0

【box3】古风速建代码出售! 中回复

👍

2022-05-08T13:03:12 点赞:0

台式机和笔记本你更倾向哪个? 中回复

2022-05-08T20:30:44 点赞:0

你们的冲刺是怎样操作的,求回复,谢谢 中回复

你可以编辑

2022-05-08T22:05:06 点赞:0

让玩家飞行 中回复

player.canFly = true

2022-05-09T18:47:35 点赞:0