## command /function ui/shopui/upgrade_iron_set_score
# set in ui

scoreboard objectives add Iron dummy Iron 
scoreboard objectives add Diamond dummy Diamond 
scoreboard objectives add Emerald dummy Emerald 

## DIAMOND
scoreboard players set @s[hasitem={item=diamond,quantity=..1}] Diamond 0
scoreboard players set @s[hasitem={item=diamond,quantity=2..}] Diamond 1

## Emerald
scoreboard players set @s[hasitem={item=emerald,quantity=..1}] Emerald 0
scoreboard players set @s[hasitem={item=emerald,quantity=2..}] Emerald 1
