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

I need this script fixed(broken) it is a survival hint script?

Asked by 10 years ago
function survive_ann()
Survivors = {}
players = game.Players:GetPlayers()
for _,v in pairs(players) do
if(v.Character) then
    v.Character:MoveTo(Vector3.new(243,1.5,-225.4))
    wait(15)
   table.insert(Survivors,v.Name)
    Finished = Instance.new("Message")
    Finished.Parent = game.Workspace
    Finished.Text = "The following have survived"..table.concat(Survivors,',')

It does not work. I have no idea why. It is supposed to add players to a table. But it doesn't do that and it doesn't even announce the message :(

Also: Q#2: for players = game.Players:GetPlayers() Would it get the players and keep those names and not add anymore names or would it keep adding names to the variable? That's all I want to know for this question #2.

Answer this question