I have The Walls Minigame on my server and I can't figure out how to make a Spawn Point for the Game when you die. For Example: I die and I get Teleported to a Big Sphere above the Minigame. What can I do to make this possible in my game?
This might be helpful– John the GreenMar 14, 2015 at 3:28
If the minigame takes up the entire server, simply reset their spawn with command blocks.
/spawnpoint @a [x] [y] [z]
Note: you can use player IGNs or other
@ selectors in place of
However, if there are other minigames on your server, you will only want to reset the spawn for the people on this minigame.
Create a command block at the center of the minigame on a clock and enter this command:
/spawnpoint @a[r=n] [x] [y] [z] and replace
n with the radius of the minigame. Whenever a person enters the minigame, their spawn will be set to the desired location.
To put their spawn back to normal, simply create another setup like this at the exit(s) of the minigame, with the server spawn co-ords, but use a small enough radius that it only covers the exit and does not interfere with the other command block.
This approach can be replicated with any other minigame on the server.
I hope this helps, if you do not understand something, let me know and I will put it in simpler terms.
Use a death-counter scoreboard objective. type the command:
/scoreboard objectives add spwn deathCount.
After you have done that, make a comparator clock (or any fast clock of your choice) that powers a command block. That command block should contain the following command:
/spawnpoint @a[score_spwn_min=1] <x> <y> <z>
and have a comparator coming out of that block, into another command block that contains the command:
/scoreboard players set @a[score_spwn_min=1] spwn 0.
That resets the death-counter so that they can do the parkour multiple times.