enchanted_apple.mcfunction 521 B

123456789
  1. # 去除进度
  2. advancement revoke @s only item:special/consume_enchanted_apple
  3. # 计算生命值
  4. execute if score $state mem matches 1.. if score @s mini_heart matches 1.. run scoreboard players operation @s mini_heart += @s mini_heart
  5. execute if score $state mem matches 1.. if score @s mini_heart matches 1.. run function mini:/player_max_health
  6. # 去除buff
  7. execute if score $state mem matches 1.. if score @s mini_heart matches 1.. run tag @s add consume_apple
  8. schedule function item:special/clear_effect 1t replace