on entity damages entity:
- if <context.damager.item_in_hand.lore.get[1]> == <yellow>Category<&sp><&co><&sp><gray>Weapon {
- define 1 <context.damager.item_in_hand.lore.get[4].after[<red>Attack<&sp><&co><&sp><gray>].before[-]>
- define 2 <context.damager.item_in_hand.lore.get[4].after[-]>
- - adjust <player.item_in_hand> durability:0 save:myitem
- - take iteminhand
- - give <entry[myitem].result.full>
- determine <util.random.int[%1%].to[%2%]>
+ - wait 1t
+ - adjust <context.damager.item_in_hand> durability:0 save:myitem
+ - take iteminhand from:<context.damager.inventory>
+ - give <entry[myitem].result.full> to:<context.damager.inventory>
}