#look for and modify item in all inventories

1 messages · Page 1 of 1 (latest)

hidden knot
#

So I have an item that when it's no longer in the main hand a funciton is run. I'd like this function to find the item wherever it may be and modify it, for now let's say change it's enchantment_glint_override to false.

What would be the best way to do this? At the moment I guess i'm going to write a command for every inventory slot (along the lines of item modify entity @s hotbar.0 etc).
A list of what all the inventories are would be helpful. I remember seeing one on the wiki but can't find the page anymore 🤦‍♂️

worthy fableBOT
#

<@&1201956957406109788>

Someone will come and help soon!

💬 While you wait, take this time to provide more context and details.

🙇 If nobody has answered you by <t:1729763547:t>, feel free to use the Summon Helpers button to ping our helper team.

✅ Once your question has been resolved (or you no longer need it), please click Resolve Question or run /resolve

#
⚠️ You already have a question open!

Don't forget to close or resolve your old questions once you're done with them. It makes our lives much easier! :D

Open question: #1297172593576644679

deep orbit
#

This is really hard to do accurately, since the player could also have put then item in a chest or dropped it on the ground - if they dropped it it could have instantly gone into a hopper minecart and so on

#

So it’s virtually impossible to check all places where the item could be

hidden knot
#

Hmmmm, and there's not really a good way to prevent the player from dropping a specific item or putting it in a chest ay