give_trident.mcfunction 426 B

12345678
  1. clear @s trident{game_item:1b}
  2. # 返还格子上的物品
  3. execute if data entity @s Inventory[{Slot:8b}] run scoreboard players set @s item_slot 8
  4. execute if data entity @s Inventory[{Slot:8b}] at @s run function item:pop_slot/return_item
  5. item replace entity @s hotbar.8 with trident{game_item:1b,Unbreakable:1b,HideFlags:63,display:{Name:'{"text":"三叉戟","italic":false}'}} 1
  6. scoreboard players set @s countdown_fast -1