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

How do I call all Workspace Players?

Asked by 4 years ago

I cannot work out how to find the Players in Workspace

1
Why not just do game.Players:GetPlayers()? Unless you're doing something specific with the players? DeceptiveCaster 3761 — 4y
0
how would that work if i want to change their humanoid properties karesiku 72 — 4y
1
player.Character DeceptiveCaster 3761 — 4y
0
sorry for never accepting an answer, came back just a while ago and noticed this and answered it karesiku 72 — 4y

3 answers

Log in to vote
3
Answered by 4 years ago
local Players = game.Players:GetPlayers()
for i,v in pairs(Players) do
v.Charcater -- do stuff with character
v -- do stuff with player
end
0
charcater ihatecars100 502 — 4y
Ad
Log in to vote
0
Answered by
EDLLT 146
4 years ago
Edited 4 years ago

There you go bud

for _,character in pairs(game.Players:GetPlayers()) do
    character:WaitForChild("Humanoid").WalkSpeed=100 -- Block of code here.
end
Log in to vote
0
Answered by
le145 20
4 years ago

Imma post what i would do in this case

for i,players in pairs(game.Players:GetChildren())do
    local myPlayerWork = workspace:FindFirstChild(players.Name)
    if myPlayerWork then
        --This to do with the character
    end
end

Answer this question