tick5.mcfunction 652 B

12345678910
  1. # 更新铁锭数量
  2. execute as @a[team=playing] store result score @s iron_count run clear @s iron_ingot 0
  3. execute as @a[team=playing] run scoreboard players operation @s iron_disp = @s iron_count
  4. execute if score $countdown mem matches ..90 run effect give @a[team=playing,tag=!invisible] glowing 1000000 0 true
  5. execute if score $countdown mem matches ..90 run effect clear @a[team=playing,tag=invisible] glowing
  6. # 铁锭发光
  7. execute as @e[type=item,nbt={Item:{id:"minecraft:iron_ingot"}}] run data modify entity @s Glowing set value 1b
  8. execute as @e[type=item,nbt={Item:{id:"minecraft:raw_iron"}}] run data modify entity @s Glowing set value 1b