Minecraft Commands – Troubleshooting Repeating Command Block Range Issues

minecraft-commandsminecraft-java-edition

I have this code:

tell @a[name=mpboom,r=2] hey

In a command block with this properties:

Repeat - Unconditional - Always Active

My name is mpboom. But if I come close, within the 2-block radius, it will do nothing.

Is my computer bugged, is the game bugged, or is my code wrong?

I am playing on Vanilla Minecraft 1.10.2 on Windows. It is in Singleplayer.

For anyone who does not understand yet, I want to make this command block say 'hey' ONLY to me (mpboom) if I am in a radius of two blocks.

Thank you!

Best Answer

The problem was that I was approaching the command block from beneath. You have to be above the command block or it would not detect you with the r=2 selector. I think this might have something to do with that I was standing with my feet on the ground and the r=2 looks at where your feet are.