How would one detect if a specific item was in an item frame using command blocks? I'm not talking about whether an item is rotated or not, but if there's a specific item in the frame. I'd also like to mention that I don't have much experience with commands, command blocks, or even redstone for that matter; so if you're going to explain something, spare no expense.
This is actually pretty simple. You can just use /execute (with the if argument) and then have your command. The following should work:
/execute if entity @e[x=[x],y=[y],z=[z],dx=0,type=minecraft:item_frame,nbt={Item:{id:minecraft:[item id]}}] run [your command]
You will have to change the [x], [y], [z], etc with your values. So for example, if you wanted to test for a stone block in the item frame and have the command block say "test" you would need to replace [item id] with stone and the [your command] with say test. If this doesn't work it's most likely because the nbt has changed. I'll try to find revisions if that's the case. Hope this helps.
How would one detect if a specific item was in an item frame using command blocks? I'm not talking about whether an item is rotated or not, but if there's a specific item in the frame. I'd also like to mention that I don't have much experience with commands, command blocks, or even redstone for that matter; so if you're going to explain something, spare no expense.
This is actually pretty simple. You can just use /execute (with the if argument) and then have your command. The following should work:
You will have to change the [x], [y], [z], etc with your values. So for example, if you wanted to test for a stone block in the item frame and have the command block say "test" you would need to replace [item id] with stone and the [your command] with say test. If this doesn't work it's most likely because the nbt has changed. I'll try to find revisions if that's the case. Hope this helps.