猫史档案馆


【box3即兴】3 阔恶的门呐

用户:1232RvE1232RvE查看:32 回复:6 评论:21 创建时间:2020-06-15T20:17:23


你们知道box3中的门怎么做么?

【大片群众】恩,我知道

额,看来我不用教了……

【大片群众】你快教!

额好吧

上代码

world.querySelectorAll('.门').forEach((e)=>{
    e.onEntityContact(async({entity})=>{

设置标签:门   为实体化,并编写代码

以上代码检测碰撞事件

entity.position.x+=1;
        entity.position.x+=1;
        entity.position.x+=1;
        entity.position.x+=1;
        entity.position.x+=1;
//懒得循环

额,懒得循环

我们给它蹦过去

嗯哼,蹦回来

await sleep(2000);
        entity.position.x-=1;
        entity.position.x-=1;
        entity.position.x-=1;
        entity.position.x-=1;
        entity.position.x-=1;

喵的循环呀!

再加上结尾

world.say('1232RvE:有人把门拉开了……');})})

ok

毕竟是即兴,没有多么详细

捧个场呗

 

 

 

 

 

 

 

 

 

自古沙发归楼主

你们得从板凳开始……


回复

上一页第 1 页 / 共 1 页下一页
1232RvE1232RvE

喵d

点赞0


评论

ddd

滴滴滴

滴滴滴

滴滴滴

滴滴滴

点点滴滴

滴滴滴

的点点滴滴

滴滴滴


1232RvE1232RvE

滴滴滴

点赞0


评论

滴滴滴

滴滴滴

滴滴滴

滴滴滴

滴滴滴

滴滴滴

滴滴滴

滴滴滴

滴滴滴

滴滴滴

滴滴滴


1232RvE1232RvE

滴滴滴

点赞0


评论


1232RvE1232RvE

滴滴滴

点赞0


评论


影无风_在沉默中灭亡影无风_在沉默中灭亡

ohhhhc

点赞0


评论


1232RvE1232RvE

ddd

点赞0


评论

dd