
# -> Get count
execute store result score @s OverlyRealistic.General.ArbitraryData run \
    data get entity @s item.count

# -> If count is not higher than max then return and modify item
execute unless score @s OverlyRealistic.General.ArbitraryData matches 17.. run \
    return run \
        item modify entity @s contents overly_realistic:item_edit/stack_size_16

# -> Set max stack
item modify entity @s contents overly_realistic:multipurpose/count_set/set_count_16

# -> Set max stack size
item modify entity @s contents overly_realistic:item_edit/stack_size_16
