fill ~3 180 ~3 ~-3 180 ~-3 minecraft:damaged_anvil replace air
schedule function pctf:logic/items/lucky_block/outcomes/negative/solo/anvils/speed 10t replace

execute store result score #random2 temp run random value 1..6
execute if score #random2 temp matches 1 run summon item ~ ~ ~ {Age:5900,PickupDelay:200,Motion:[0.0,0.6,0.0],Tags:["lucky_block_item","new"],Item:{id:"minecraft:golden_apple",count:1}}
execute if score #random2 temp matches 2 run summon item ~ ~ ~ {Age:5900,PickupDelay:200,Motion:[0.0,0.6,0.0],Tags:["lucky_block_item","new"],Item:{id:"minecraft:skeleton_skull",count:1}}
execute if score #random2 temp matches 3 run summon item ~ ~ ~ {Age:5900,PickupDelay:200,Motion:[0.0,0.6,0.0],Tags:["lucky_block_item","new"],Item:{id:"minecraft:bread",count:4}}
execute if score #random2 temp matches 4 run summon item ~ ~ ~ {Age:5900,PickupDelay:200,Motion:[0.0,0.6,0.0],Tags:["lucky_block_item","new"],Item:{id:"minecraft:pufferfish",count:1}}
execute if score #random2 temp matches 5 run summon item ~ ~ ~ {Age:5900,PickupDelay:200,Motion:[0.0,0.6,0.0],Tags:["lucky_block_item","new"],Item:{id:"minecraft:netherite_axe",count:1,components:{"minecraft:enchantment_glint_override":true,"minecraft:attribute_modifiers":[{id:"attack_damage",type:"attack_damage",amount:-10,operation:"add_value",slot:"mainhand"}]}}}
execute if score #random2 temp matches 6 run summon item ~ ~ ~ {Age:5900,PickupDelay:200,Motion:[0.0,0.6,0.0],Tags:["lucky_block_item","new"],Item:{id:"minecraft:diamond_sword",count:1,components:{"minecraft:enchantment_glint_override":true,"minecraft:attribute_modifiers":[{id:"attack_damage",type:"attack_damage",amount:-10,operation:"add_value",slot:"mainhand"}],"minecraft:lore":[{"color":"red","italic":false,"text":"Curse of Metal"}]}}}