for some reason none of this is working
source code:
function elimination() --eliminates the players by dying or falling into the lava
for i,v in pairs(players:GetChildren()) do
local hum = v.Character.Humanoid
PlayerItemRemove()
hum.Died:Connect(function()
v.Lobby.Value = true
table.remove(playersInRound,i)
end)
end
end
function roundBegin() --Begins the round
StopMusicZ()
roundZ()
local playerlist = players:GetChildren()
for i,v in pairs(playerlist) do
v.PlayerGui.Main.Shop.Button.Visible = false
local spawns = _G.Map:WaitForChild("Spawns"):GetChildren()
v.Character:MoveTo(spawns[math.random(1,#spawns)].Position)
table.insert(playersInRound, v.Name)
v.Lobby.Value = false
PlayerItem()
end
pianos.Disabled = false
for i = config.Round.Value,1, -1 do
im###########n##rogress")
smess(i)
wait(1)
elimination()
if i = 1 then
MoreThanOneSurvivor()
break
elseif #playersInRound == 1 then
JustOneSurvivor()
break
elseif #playersInRound == 0 then
NoSurvivors()
break
end
end
end |