Player.Character.Humanoid.Died:connect(function() if(Player:FindFirstChild("PlayerGui"):FindFirstChild("Check")~=nil)then game.Workspace.SpawnLocation.Enabled = false local FakeSpawn = game.Workspace.SpawnLocation:Clone() FakeSpawn.Name = "FakeSpawn"..Player.Name FakeSpawn.Size = Vector3.new(6,1,1) FakeSpawn.Enabled = true FakeSpawn.CanCollide = false FakeSpawn.Anchored = true FakeSpawn.Transparency = 1 FakeSpawn.Parent = game.Workspace FakeSpawn.Position = Player.Character:FindFirstChild("Torso").Position end end)``
i am trying to spawn the player by name lets say player1 died we creat a FakeSpawnPlayer1 but if 2 players died only they BOTH spawn in random spawn between FakeSpawnPlayer1 and FakeSpawnPlayer2 .
how can i spawn each player in his own private spawn ? should i make a team color ? although i dont like it .
I don't understand what you mean by "but if 2 players died only they BOTH spawn in random spawn between FakeSpawnPlayer1 and FakeSpawnPlayer2", but the rest of your problem could be solved by keeping track of the player's last known location and teleporting them thee when they respawn. This would be in a normal script (not LocalScript) that listens for each player's CharacterAdded event. For each time this event fires except the first, teleport the player to the proper location. In all cases, start a loop that records the player's torso's Position until the player dies.