Minecraft – In minecraft, How do i set a spawnpoint using command blocks

minecraft-bedrock-editionminecraft-commands

I'm trying to make a parkour course and I want to have the player respawn at every new checkpoint they reach when they die

Best Answer

Easy, get a command block where you can step on (suggesting pressure plate), and type the following command:

spawnpoint @p x y z

Fill x y z to your desired coordinates.

But there's a better way, though I don't suggest using it. Try:

execute @a[x=#,z=#,dx=0,dz=0] ~ ~ ~ spawnpoint @s ~ ~ ~

Replace the # with your desired coordinates.

This has to be done via an Always Active Repeating Command Block, and you don't need to make some redstone for this to work. Let the command block do it's job and it will be automatic for everyone.

Just remember that you must make the coordinates exact (as suggested by @Penguin).