猫史档案馆


【box3】求助! 输入名称将让人关进监狱的代码!

用户:wyydswyyds查看:172 回复:2 评论:6 创建时间:2022-07-21T17:03:37


求 !   就像关监狱XXX这样


回复

上一页第 1 页 / 共 1 页下一页
yee剑走天下yee剑走天下

world.onChat(({ entity, message }) => {
    if (admin.includes(entity.player.name)) {
        if (message.startsWith('关监狱')) {
            try {
                world.say(`${message.slice(3)}被管喵关监狱了!`)
                world.querySelectorAll('player').find(e => e.player.name == message.slice(3)).position.set(x, y, z)
            } catch (error) {
                world.say(`${message.slice(3)}不在线哦!`)
            }
        }
    }
})

点赞0


评论

✍✍


wyydswyyds

报错也是很

点赞0


评论

???

哦对了,还要加个c喵t admin = ['自己写名字']

刑 谢谢

x,y,z填坐标没错吧

对()