-- Timer
-- The error is in the checks of checking if the player left and if there is no one on the killers team. I already have a variable set up for killer.Name.
Let me know if you can point something out, thanks.
local teams = game:GetService("Teams"):GetTeams()
for _, team in pairs(teams) do
local players = team:GetPlayers()
local nom = #players
for i = 200,0,-1 do
status.Value = i
wait(1)
game.Players.PlayerRemoving:connect(function(plr)
if plr.Name == killer.Name then
print("killer left")
if team.Name == "Victims" and nom == 0 then
print("Victims = none")
end
end
end)
end
|