Hello amazing peoples, so i am making a script so that when the round start every player will get a team they will be solo but the problem is that i am confused on how to make it here is my script so far:
local players = game:GetService("Players")
local timer = 25
local teams = game:GetService("Teams")
local value = game.ReplicatedStorage.Status
local inRound = game.ReplicatedStorage.InRound
repeat wait() until #players:GetPlayers() >= 4
inRound.Changed:connect(function()
if inRound.Value == true then
for _, players in pairs(game.Players:GetChildren()) do
local char = players.Character
for i = #teams:GetChildren(), 8, 1 do
if players.Team == teams["Lobby"] then ----kinda confuse on how to put player one in a team and the other one in a diffrent team
players.Team = teams[i]
end
end
end
end
end)
local function roundTimer()
for i = timer,1,-1 do
value.Value = "Intermission "..i.." Seconds left"
wait(1)
end
value.Value = "Game Started"
inRound.Value = true
end
spawn(roundTimer)
what i want if you too is confused is that, Players will get different team they must be solo in their team i dont want it so that there is two or more player in a team i want all team to have only one person
there is a maximum of 8 teams any help is appreciated