Hey guys, Im working on a arena like Skript. Players click on a sign named Blue and Red. If they choose Blue, they will go into team blue. I also have a countdown system like this:
But what now happens is that if you are with 2 people in the game, First one player gets the countdown and get teleported, and after that another one. But what i want is that everyone is teleported at the same time, everyone from the blue team and everyone from the red team. Can you guys help me out?
code_language.skript:
command /startsandbox:
trigger:
if {sandbox.countdown} is false:
set {sandbox.countdown} to true
loop all players:
loop-player has permission "sandbox.chat":
if {%loop-player-1%.team} = 1: #team blue
send "&bEnough people are ready!" to loop-player
wait 1 second
send "&b5.." to loop-player
wait 1 second
send "&b4.." to loop-player
wait 1 second
send "&b3.." to loop-player
wait 1 second
send "&b2.." to loop-player
wait 1 second
send "&b1.." to loop-player
wait 1 second
make loop-player-1 execute command "/warp bsand"
set {sandbox.game.started} to 1
else if {%loop-player-1%.team} = 2: #team red
send "&bEnough people are ready!" to loop-player
wait 1 second
send "&b5.." to loop-player
wait 1 second
send "&b4.." to loop-player
wait 1 second
send "&b3.." to loop-player
wait 1 second
send "&b2.." to loop-player
wait 1 second
send "&b1.." to loop-player
wait 1 second
make loop-player-1 execute command "/warp rsand"
set {sandbox.game.started} to 1
But what now happens is that if you are with 2 people in the game, First one player gets the countdown and get teleported, and after that another one. But what i want is that everyone is teleported at the same time, everyone from the blue team and everyone from the red team. Can you guys help me out?