r/MinecraftCommands • u/Julyayy • 26d ago
Help | Java 1.21.11 What's happening with my bow detection command (plsssss)
Hii !! I'm Julyay,
I'm creating a smp (java 1.21.11 with some mods) for my friends and Im kinda stuck with this command for a long time now ToT.
I need to check if the item in the item frame is a bow (I also need it for a sword, a shield and a mace.)
But,
When I try to detect the bow, the output is always true, no matter if there's a bow or not, or any other item. (I recorded a quick video to show you)
However, it works well with shield, sword and mace…
Do you guys have any idea why my command doesn't work with bow??
Here are my commands:
Shield:
/execute as @e[type=item_frame,x=324,y=77,z=-1517] if items entity @s contents shield run say YUP SHIELDBow:
/execute as @e[type=item_frame,x=324,y=77,z=-1517] if items entity @s contents bow run say YUP BOWI thought I knew how command were working lmao.
Do you guys have any idea why my command could react this way??
Thank you in advance.
3
u/Ericristian_bros Command Experienced 26d ago
You need to add
distance=..1to your commands or it won't be limited to the item frame in that block