axty
本帖最后由 axty 于 2020-5-8 19:57 编辑

如题,怎样分别作出180、30、10、5秒的计时器?版本:20w19a(其他消耗资源小的方法也行)

strings
游戏版本?

Changesite_Y

人家说了19a

Changesite_Y
红石多多少少也是要有一些的

可以考虑用漏斗以及红石中继器计时
https://jingyan.baidu.com/article/3aed632e0dacfc7010809196.html

浅海星未眠
https://www.bilibili.com/video/BV1cx411U7AB

axty
PTSD∝龌龊闵 发表于 2020-5-8 19:58
红石多多少少也是要有一些的

可以考虑用漏斗以及红石中继器计时

有没有消耗服务器资源较少的

strings
/scoreboard objectives add time dummy

然后高频
/scoreboard players add # time 1
/execute if score # time matches 100.. run say 五秒了

浅海星未眠
axty 发表于 2020-5-8 20:02
有没有消耗服务器资源较少的

对服务器影响基本=0
https://www.bilibili.com/video/BV1cx411U7AB

浅海星未眠
就几个活塞而已啊xd

晴路卡
药水云有一个记录其存留时间的NBT
比如说输入
  1. /summon area_effect_cloud ~ ~ ~ {Duration:100,Tags:["timer"]}
复制代码
会生成一个只能存在5秒的带一个名称为“timer”的tag的药水云
然后只要用循环型命令方块高频执行
  1. /execute unless entity @e[tag=timer] run say 5秒过去了
复制代码
就能检测是否经过了五秒
(Duration后填的是你所需要计的时长x20)


strings
/execute if score # time matches 3600 run say 五秒了

第一页 上一页 下一页 最后一页