Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

I'm having trouble assigning teams myself. Any help?

By this I don't mean to change. I mean to assign certain players, like myself, or admins, to teams. I only want to do this so I know who's who.

1 comment

0

You should include some code showing what you've attempted (even if it doesn't work at all).

1 answer

permission = {"","ur friend","other admins","other admins","","",""} 

function checkOkToLetIn(name) 
	for i = 1,#permission do 
		if (string.upper(name) == string.upper(permission[i])) then return true end 
	end 
	return false 
end 


admin = game.Teams:findFirstChild("WhateverYouWantToNameThem")

function onEntered(player)
	if checkOkToLetIn(player.Name) then
		player.TeamColor = admin.TeamColor
	end
end


game.Players.PlayerAdded:connect(onEntered)

This discussion is preserved as it was. New answers, comments, and votes are closed.