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

Round script isn't running?

Asked by
Irvene 5
9 years ago

The script isn't working I tried to fix it endless times, it just wont run. Help me please, Here's the script(I believe the problem might be in the position?):

while true do
    repeat 
        local m = instance.new("Message",workspace)
        m.Text = "Need 1 more player to start"
        wait(3)
        m:destroy()
        wait(5)
    until #Players >= 2

    for i = 10,1,-1 do
    local m = Instance.new("Message",workspace)
    m.Text = "Countdown[ "..i.." ]"
    plrs = game.Players:GetChildren()
    local hum = game.Workspace.Character.findFirstChild("Humanoid")
    if hum then
      local players = game.Players:GetChildren()
           for i = 1,#players do
              pcall(function()
                   table.insert(players, i, players[i])
                         wait(.1)
                    local Positions = {Vector3.new(-1204.75, -378.47, -2526.39), Vector3.new(-1073.11, -412.23, -2566.14),Vector3.new(-1073.11, -348.64, -2988.701),Vector3.new(-1204.75, -378.47, -2740.15)} -- Add your positions here
                math.randomseed(tick())
           local players = game:GetService("Players"):GetPlayers()
        for i=1,24 do
      if #players then  
 local current = math.random(1,#players)
      local position = Positions[math.random(1,#Positions)]
           if players[current] and players[current].Character then
             players[current].Character:MoveTo(position)
end
end
    wait()
end
0
It just wont create that message.. Irvene 5 — 9y
0
You should tab your code in a sane fashion. BlueTaslem 18071 — 9y
0
I'm a beginner don't really know how to tab code. Irvene 5 — 9y
0
Is this a free model? Prioxis 673 — 9y
0
No, I created this go ahead and stereotype because I failed a script. Won't do you any good. Irvene 5 — 9y

1 answer

Log in to vote
0
Answered by 9 years ago

Put the m = Instance.new("Message", workspace) on the very tip top of the script. and wherever it says m:Destroy replace with m.Parent = nil and when it says m = Instance.new("Message", workspace) replace it with m.Parent = workspace

Ad

Answer this question