We've split up the commands, scripting and mods, and add ons category! Please be sure you get your thread in the right place.

15

New "hasitem = {noi = (name of item)" Command For Named Items

2 Comments

Please sign in to leave a comment.

Sorted by oldest
  • 0
    Registered User commented
    Comment actions Permalink

    You can check for a specific item by adding an nbt-constraint to the selector:

    effect give @a[nbt={Inventory:[{Slot:100b, id:"minecraft:leather_boots", Count:1b, tag:{display:{Name:'{"text":"Grass Boots"}', color:<COLOR>}}}]}] 1 0 true

    After the tag: you just copy the NBT-data of your boots.

  • 0
    Registered User commented
    Comment actions Permalink

    When putting this command in on Bedrock Edition, it just says gives an Error rather than doing anything

    effect give @a[nbt={Inventory:[{Slot:100b, id:"minecraft:leather_boots", Count:1b, tag:{display:{Name:'{"text":"Grass Boots"}', color:<COLOR>}}}]}] 1 0 true

    Which means that this command doesn't work for Bedrock Edition, there is no NBT thing on bedrock or anything like these parameters.

    So I agree that the [hasitem = {noi = {name}}] thing would be useful as this would help bedrock players a lot.