
Lv.1
额
签名:吃粑 巴
在 粒子特效怎么做啊! 中回复
world.onPlayerJoin(({entity})=>{ entity.player.canFly=true Object.assign(entity, { particleLimit:300, particleLifetime: 5, particleRate: 300, particleRateSpread: 500, particleSize:[5,3,5,3,5], particleColor: [ new Box3RGBColor(10,0,0), new Box3RGBColor(0,10,0), new Box3RGBColor(0,0,10), ], particleVelocity: new Box3Vector3(0, 0, 0), }); }) for (let i = 0; i < 128; ++i) { for (let j = 0; j < 128; ++j) { voxels.setVoxel(i, 8, j, 'polar_ice') } }
2022-01-30T13:56:34 点赞:0
在 谁会攻击代码????????????? 中回复
world.onPlayerJoin(({ entity }) => {
entity.enableDamage = true;
entity.player.onPress(({ button, raycast:{ hitEntity, direction } }) => {
if (button !== 'action0' || !hitEntity) {
return;
}
hitEntity.velocity.x += direction.x;
hitEntity.velocity.y += 0.5;
hitEntity.velocity.z += direction.z;
hitEntity.hurt(20 * Math.random() + 5, {
attacker: entity,
});
});
});
world.onDie(({ entity, attacker }) => {
if (attacker) {
world.say(attacker.player.name + ' killed ' + entity.player.name)
}
entity.player.forceRespawn();
});2022-02-07T13:04:42 点赞:0
在 [存档点] 存档点怎么搞 中回复
if (e.id == "起点") { e.collides = true //开启碰撞 e.fixed = true //固定实体不被推移 e.onEntityContact(async({ other }) => { //每当存档点碰到另一个实体 if (other.isPlayer) { //另一个实体是玩家 if (e.position !== other.player.spawnPoint) { // 检测当前存档点是否玩家重生点, 避免反复在同一个存档点做多余的保存 world.say(other.player.name + " 出发啦!") 起点也给你一下
2022-02-09T15:15:21 点赞:0
在 【box3】粒子特效颜色搭配!! 中回复
new Box3RGBColor(0,0 ,0 ), new Box3RGBColor(0, 0,1 ), new Box3RGBColor(8, 8, 8)], 黑暗水滴
2022-08-06T11:23:01 点赞:0
在 【box3】粒子特效颜色搭配!! 中回复
new Box3RGBColor(0,0 ,0 ),
new Box3RGBColor(0, 0,1 ),
new Box3RGBColor(8, 8, 8)],2022-08-06T11:24:10 点赞:0