{SOLVED}How can i make a script which makes when members of a specific group join a server , their team auto change to a specific team , i tried this script :
When.Humanoid.Join If.local GroupMember = true local GroupId = 0 -- i wrote a working Id but it didnt work local GroupRank = 252 then Humanoid.Team = Citizens -- the team name end
I am a beginner scripter , so of course my script has a lot of mistakes , please tell me what did i do wrong?{SOLVED}
game.Players.PlayerAdded:connect(function(Player) if Player:IsInGroup(0) then -- Change the group ID to your group Player.TeamColor = BrickColor.new("Bright Red") -- Or whatever the color of team is. end
So The logic behind this is that it checks whether your in the group or not, if your in the group then it will Place your Team Color into what ever team color you want.
Player:IsInGroup()
Is method which checks whether or not if your in the group and can find
whether or not your in the group
Also Teamcolor is a property of the player which can be changed by changing there Team Color Hopes this explains, i'm bad it.
I think this method will help alot, http://wiki.roblox.com/index.php/IsInGroup_(Method)
so according to your script a person at that group with a rank of 252 teams in to civilians