
# -> Add to value
scoreboard players add @s OverlyRealistic.General.ArbitraryData 1

# -> Particle
particle block{block_state:"brown_stained_glass"} ~ ~ ~ 0.1 0.1 0.1 0.001 1 normal @a

# -> If value < 10 then return
execute unless score @s OverlyRealistic.General.ArbitraryData matches 10.. run \
    return fail

# --> Else, turn to leather

# -> Tag as filled with leather
tag @s add OverlyRealistic.Block.WoodenRack_Status_Filled_Item_Leather
tag @s remove OverlyRealistic.Block.WoodenRack_Status_Filled_Item_DousedHide

# -> Change item display to leather
execute on passengers run \
    data modify entity @s[tag=OverlyRealistic.Block.WoodenRack_Item] item set value {id:"minecraft:leather", components:{}, count: 1}

# -> Reset value
scoreboard players set @s OverlyRealistic.General.ArbitraryData 0
