1

How to kill any player that steps on white concrete using command blocks?

BestBrainGamer5/16/25 7:27 pm
5/27/2025 2:17 am
BestBrainGamer
I'm making a parkour world and need to make it that when a player step on white concrete, they die.

Nothing seems to work, so I need help.
Posted by
BestBrainGamer
Level 1 : New Miner
0

Create an account or sign in to comment.

12

Escapazition
05/17/2025 1:46 am
Level 31 : Artisan Blueberry Scribe
Going off of Budderman18's response, the "run" function is used to execute a command within a command. You can swap out "kill @p" with any other command to make stepping on any kind of block do any kind of thing.

Here's a tutorial on the whole concept.
2
Budderman18
05/16/2025 8:50 pm
Level 24 : Expert Sus Network
history
execute at @p if block ~ ~-1 ~ white_concrete run kill @p



make sure its a repeating command block
2
BestBrainGamer
05/17/2025 4:12 am
Level 1 : New Miner
i put '/execute at @p if block ~ ~-1 ~ white_concrete run kill @p' but the previous output says "Execute subcommand if block test failed".
The command block is repeating, unconditional and always active. Are you sure it works on edu edition?
1
Budderman18
05/17/2025 3:14 pm
Level 24 : Expert Sus Network
bedrock doesn't allow /kill on creative players for whatever reason. Make sure to test in survival or adventure.
1
BestBrainGamer
05/17/2025 6:44 pm
Level 1 : New Miner
already have. and edu and bedrock are the same kind of edition but off by bit right?
1
CreeperSlaye01
05/20/2025 9:10 am
He/Him • Level 14 : Journeyman Dragonborn Server owner
Not just by a bit. Edu hasn’t even gotten last year’s fall drop. And need I add that since you’re on Edu, you could just do something with Code Builder?
1
BestBrainGamer
05/27/2025 2:17 am
Level 1 : New Miner
damn since that long? and yeah code builder is a thing but i dont use it
1
HoboMaggot
05/17/2025 7:27 am
Level 54 : Grandmaster Blob
This is detecting if the block underneath the command block is white concrete (you have not updated the selector context).

The command should actually be:
execute as @a at @s if block ~ ~-1 ~ white_concrete run kill @s
Because bedrock still uses ids for block variants, the command could be this instead:
execute as @a at @s if block ~ ~-1 ~ concrete 0 run kill @s
(0 is the blockstate id for white concrete)
1
BestBrainGamer
05/17/2025 6:48 pm
Level 1 : New Miner
it still comes up with "Execute subcommand if block test failed" in the previous output box no matter if its conditional or not.
1
HoboMaggot
05/17/2025 11:54 pm
Level 54 : Grandmaster Blob
history
Conditional means it relies on the command block behind it to be able to run successfully first
This mc bedrock video explaining the execute command supports the command I gave.

Try replacing the kill command with something like a /say command as Budderman mentioned that kill does not work for creative players
1
Budderman18
05/17/2025 3:16 pm
Level 24 : Expert Sus Network
at means a desired entity's position. as is what entity runs the command. If you do it this way it will not work if the player isn't opped.
1
HoboMaggot
05/18/2025 12:04 am
Level 54 : Grandmaster Blob
The as selector should be able to work on unopped players otherwise maps and commands relating to entities/mobs (as @e etc) would fall apart. The official wiki page also has no mention that the player has to be opped

You are indeed correct that the context was updated to the entity's position and that is my error.
1

Welcome