data modify storage inv_update list set value []
data modify storage inv_update list set from entity @s Inventory
data remove storage inv_update list[{tag:{custom:1}}]
execute unless data storage inv_update {list:[]} run function items:stats_calc/slots/any_loop
