用户:
发飙的蜗牛a查看:1 回复:2 评论:1 创建时间:2021-08-16T16:10:55
受不了,喵
上代码啊
world.onPress(({ button, entity }) => {
if(button === 'action1'){
entity.player.dialog({
type: Box3DialogType.SELECT,
title: '武器',
content: `你好,${entity.player.name},这里可以切换手持的武器`,
options:['长喵'],
if (selection){
const wuqi=wuqilist[selection.index]
if (wuqi='长喵'){
entity.player.addWearable({
bodyPart: Box3BodyPart.RIGHT_HAND,
mesh: 'mesh/长喵 加强版.vb',
orientation: new Box3Quaternion(0,1,0,0).rotateY(Math.PI),
offset: new Box3Vector3(-0.05,-0.1,0.5),
scale: Box3Vector3 = new Box3Vector3(0.5, 0.5, 0.5),
});
}
}
});
}
})
小熊与雪world.onPress(({ button, entity }) => {
if(button === 'action1'){
let selection=entity.player.dialog({
type: Box3DialogType.SELECT,
title: '武器',
content: `你好,${entity.player.name},这里可以切换手持的武器`,
opti喵:['长枪']
})
if (selection){
c喵t wuqi=wuqilist[selection.index]
if (wuqi='长枪'){
entity.player.addWearable({
bodyPart: Box3BodyPart.RIGHT_HAND,
mesh: 'mesh/长枪 加强版.vb',
orientation: new Box3Quaternion(0,1,0,0).rotateY(Math.PI),
offset: new Box3Vector3(-0.05,-0.1,0.5),
scale: Box3Vector3 = new Box3Vector3(0.5, 0.5, 0.5)
})
}
}
}
})点赞0
评论