Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How do i clone players in a cloning script?

Asked by 4 years ago

In roblox what is the process of cloning a player?

1 answer

Log in to vote
0
Answered by
Mr_Unlucky 1085 Moderation Voter
4 years ago
Edited 4 years ago

If you mean cloning characters, you can. However if you mean cloning a player you cannot unfortunately. According to the developer wiki, the Player instance cannot be created, this includes Instance.new() and Clone()

You could clone characters technically because its a model and models can be created using both Instance.new() and Clone().

game:GetService("Players").PlayerAdded:Connect(function(Player)
    Player.CharacterAdded:Connect(function(Character)
        Character.Archivable = true
        Character:Clone().Parent = workspace
    end)
end)

In the code above we have two events, one for when the player joins and another for when the character is created. When the CharacterAdded event is fired we immediately clone the Character and parent it into the workspace. That's about it really.

0
You forgot to set character.Archivable = true User#24403 69 — 4y
0
Oh yeah thanks for catching that Mr_Unlucky 1085 — 4y
0
How would I make this for a specific player? AllsSweetPool -3 — 4y
0
Oh, create a conditional in which it checks if the Player that joined has the same userId as the specified player's UserId, and then if that statement is true then the code above will execute. Mr_Unlucky 1085 — 4y
Ad

Answer this question