Minecraft 兴趣开发 | 指令笔记

运行之后会自动创建一个名字为namespace的存储空间,存入:a:1b

 /data merge storage minecraft:namespace {a:1b}   

创建挖掘榜计分板,id是dig,显示名称是'ABC挖掘榜'

 /scoreboard objectives add dig minecraft.used:minecraft.netherite_pickaxe "ABC挖掘榜" 

将计分板显示在屏幕右侧

 /scoreboard objectives setdisplay sidebar dig 

获取玩家实体nbt数据

 /data get entity 玩家ID 

检测玩家揹包是否存在指定物品

 /execute if entity @a[nbt={Inventory:[{id:"minecraft:netherite_ingot"}]}] if entity 玩家id 

移除玩家揹包指定物品

 /clear GreatMingCtu minecraft:netherite_ingot 

给玩家计分板加分

 /scoreboard players add GreatMingCtu death 1 

 

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章