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

Why can't I add players in a list?

Asked by 3 years ago
local alive = {}

local plrs = game:GetService("Players"):GetChildren()

for i,k in pairs(plrs) do
    table.insert(alive, k.Name)
    print(k.Name .. "added")
end

It's meant to add all players in a list and print a message when a player it's added, but it doesn't print anything.

Is it because of the HTTP 409 error I get when I open the console?

0
So, I tried another script that works for others, but it still doesn't for me. I didn't change anything at the game service. Also it prints things that are outside the for TheChi_1705 22 — 3y
0
I tried to open another game and put the script in SSS. It still didn't work. What do i do wrong? TheChi_1705 22 — 3y

Answer this question