I am making a training center for my group and when i load a map i want it to respawn all player but i dont know how could someone help?
This script needs to be in a Regular server-side http://wiki.roblox.com/index.php?title=Script.
Use :LoadCharacter()
to respawn the players. You can also do :LoadCharacter(false)
or :LoadCharacter(true)
. :LoadCharacter(true)
respawns them normally and :LoadCharacter()
and :LoadCharacter(true)
is the same thing. :LoadCharacter(false)
respawns the player but lets say you change their CharacterAppearence
then :LoadCharacter(false)
, the CharacterAppearence
doesn't apply to them.
for _, player in pairs(game.Players:GetPlayers()) do if player.Character then --Checks to see if the player is a legit one. player:LoadCharacter() --Respawns player end end
for _,v in pairs(game.Players:GetPlayers()) do v:LoadCharacter() end
That snippet should do it.