I am completely blank on how to do this if it’s possible, tried researching it, going through the developer hub and can’t find anything. Is it possible to collect a list of players that are on a certain team?
Yes, you could use #GetPlayers() to get the amount of players in your team, and sort a list from that.
Example:
local team = game:GetService("Teams").Red
local Players = team:GetPlayers()
for _,Plr in pairs(Players) do
--do stuff
end
--If your table isnt empty, this line will print all your items in your table with a separating ","
print(table.concat(Players,",")
1 Like