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

How can one change something for all player characters?

Asked by 6 years ago

I would like to know how to change properties of all player characters in a game. For instance, how to delete all torsos from all characters. I know how to do :GetAllPlayers, but with that you can't change any properties.

1 answer

Log in to vote
1
Answered by 6 years ago

I have made a post on your previous question on how to GetAllParts, this is no different.

Also please read the previous post so you will get this one

for _, player in pairs(game.Players:GetPlayers()) do
    if player.Character:FindFirstChild('Torso') then
        player.Character.Torso:Destroy()
    end
end

Note this will only work for R6, for R15, you would have to change Torso to a part that R15 has, note that this many kill the player.

Please read the previous posts answer and you will understand more.

Ad

Answer this question