/testfor Problem! Minecraft 1.10
//ads -- adsterra.com -- native banner
?>
I am trying to make a door open when a player is holding a nametag named "Key 1224", unfortunately, I may have done something very wrong or Minecraft is simply not working.
This is my command:
/testfor @a[r=10] {SelectedItem:{id:"minecraft:name_tag",tag:{display:{Name:"Key 1224"}}}}
I have set up my comparator system correctly - or at least I think I did - but it isn't working.
Could anyone help?
Pictures about "/testfor Problem! Minecraft 1.10"



Is Testfor still in Minecraft?
You can test for a certain target in the game using the /testfor command in Minecraft. TIP: Starting in Minecraft Java Edition (PC/Mac) 1.13, the /testfor command was removed from the Java Edition version of the game.What replaced the Testfor command in Minecraft?
The /testfor command became obsolete in Minecraft 1.13, and has been replaced by the /execute command*. It will do the same as typing /testfor @e {SelectedItem:{id:"<item>"}} and then putting a comparator to the command block with the command, and then running the command which you wanna run.Testfor Rain - Rain detection system [Tutorial] Minecraft 1.10
Sources: Stack Exchange - This article follows the attribution requirements of Stack Exchange and is licensed under CC BY-SA 3.0.
Images: Pixabay, SHVETS production, Kaboompics .com, Karolina Grabowska


