How do I testfor if a player is standing on a certain block on a certain coordinates

How do I testfor if a player is standing on a certain block on a certain coordinates - Person Holding Black and Green Tennis Racket

So I'm pretty new to testfor still and I would like to know how to create a commandblock system that would detect when they are standing on a yellow wool block on the coordinates 400 4 600 (for example) does anyone know how to setup this redstone suystem, and also be specific about how I set the redstone system up, so for example show me a picture on how the setup of it would look like.



Best Answer

You can try a command like this:

execute @a[x=400,y=4,z=600] ~ ~ ~ detect ~ ~-1 ~ minecraft:wool 4 [Command]

For [Command], you can do something like scoreboard players set @p dummyobjective 1

Then execute @a[score_dummyobjective_min=1] ~ ~ ~ [command]

But those last two lines are usually only needed if you want to run multiple commands, or to keep track of multiple players.




Pictures about "How do I testfor if a player is standing on a certain block on a certain coordinates"

How do I testfor if a player is standing on a certain block on a certain coordinates - A Man Holding a Golf Club
How do I testfor if a player is standing on a certain block on a certain coordinates - Young Man Standing by Volleyball Net with Ball in Hands
How do I testfor if a player is standing on a certain block on a certain coordinates - A Man Standing on the Grass



How do you test a player in Minecraft in a certain area?

2. Type the Command
  • Test if Players are within 10 blocks. In this example, we will test to see if there are any players within a 10 block radius with the following command: /testfor @a[r=10] ...
  • Test if Mooshrooms are within 50 blocks. ...
  • Test if Nearest Player is at Level 20 experience.




  • (Bedrock) How To detect a player standing on custom coordinates (Minecraft)




    Sources: Stack Exchange - This article follows the attribution requirements of Stack Exchange and is licensed under CC BY-SA 3.0.

    Images: Oliver Sjöström, cottonbro, RODNAE Productions, cottonbro