What I want: When a player joins a game, it will check their rank, then either make them a trainer, or a trainee.
Currently, I have the following inside a GUI. What it does is check if they are the right rank, then remove it if they are not.
nameA = {"TheExtinction"} plr = script.Parent.Parent.Parent
for i = 1, #nameA do if plr:GetRankInGroup(groupid)>=152 or plr.Name == nameA[i] then plr.TeamColor = BrickColor.new("Magenta") else plr.TeamColor = BrickColor.new("Lime green") wait(.01) script.Parent:remove()
end end
note the groupid is identified earlier in the script
What is wrong with this? The removing works but the team changing doesn't.

1 comment
Code block please.......