Command for 1 door person Minecraft?

ta
5

I want XY to go through the door but no one else! It should be like this:

XY rises on the pressure plate and the glass door disappears (/ fill) when the person leaves the radius of approx. 3 blocks, the glass door should come back!

How does it work? Can somebody help me?

sl

How big is your door?

ta

3x3 but no pistons but only / fill… If you have time add me to discord: Jonas # 4444

Ar

You can place an impulse command block under the pressure plate, in which it says:

/ execute if entity @e [type = minecraft: player, distance = .3, name = player name] run fill coordinate coordinate minecraft: air

There's a repeat command block below the pulse command block that does not require a redstone

/ execute positioned ~ ~ 1 ~ unless entity @e [type = minecraft: player, distance = .3, name = player name] run fill coordinate coordinate minecraft: glass

Important:

-the coordinate pairs must be the same

- Pay attention to uppercase and lowercase letters in the player name

Hope it works! (with me it has)

ta

Would you like to help me directly on the server? I'm too stupid.

ta

So I tested it but nothing happens…