
如何做到在1.12.2物品栏上方实时刷新以上文字的数值?
本帖最后由 阿仟 于 2022-6-22 18:07 编辑
execute @s ~ ~ ~ title @s actionbar [{"text":"死亡数:"},{"score":{"objective":"death","name":"@s"},"bold":true,"color":"white"}]
death 即你的死亡计分板名
execute @s ~ ~ ~ title @s actionbar [{"text":"死亡数:"},{"score":{"objective":"death","name":"@s"},"bold":true,"color":"white"}]
death 即你的死亡计分板名
您好,此工具完全可以做到您的提问所求 https://www.mcmod.cn/tools/cbcreator/#/title/
- title @a actionbar [{"text":"死亡数:","color":"blue"},{"score":{"objective":"death","name":"*"},"color":"white"},{"text":" 游玩时间:","color":"blue"},{"score":{"objective":"playingTime","name":"*"},"color":"white"},{"text":" 经验值:","color":"blue"},{"score":{"objective":"exp","name":"*"},"color":"white"}]
如果上述变量已经引用计分板数据的话只需将title命令放在命令方块(循环,保持开启)上并且通过游戏指令/gamerule commandBlockOutput false 来隐藏命令方块的日志输出(不会影响say,tellraw等命令的结果输出)即可。如果没有引用计分板,则按照其他楼的指引引用即可,不做赘述。
execute @a ~ ~ ~ title @s actionbar 你想要的内容(格式请使用2楼的mcmod网址)
这并不需要实时刷新,本质上你激活这个命令开始就是刷新的
这并不需要实时刷新,本质上你激活这个命令开始就是刷新的
谢谢你我也被这个问题困扰