Hey everyone, so I found some code from here video and their code seems kinda repetitive. Is there a way I can list a group ID > and multiple or a single rank and be able to do this over and over again for different groups and such? I’m trying to make a team rank only auto-assignable script. I know very little about scripting any help would be nice, thanks.
game.Players.PlayerAdded:Connect(function(plr)
if plr:GetRankInGroup(4558154) == 3 then
plr.TeamColor = BrickColor.new("Br. yellowish orange")
elseif plr:GetRankInGroup(4558154) == 4 then
plr.TeamColor = BrickColor.new("Br. yellowish orange")
elseif plr:GetRankInGroup(4558154) == 2 then
plr.TeamColor = BrickColor.new("Bright green")
elseif plr:GetRankInGroup(4558154) == 5 then
plr.TeamColor = BrickColor.new("Br. yellowish orange")
elseif plr:GetRankInGroup(4558154) == 7 then
plr.TeamColor = BrickColor.new("Br. yellowish orange")
elseif plr:GetRankInGroup(4558154) == 7 then
plr.TeamColor = BrickColor.new("Br. yellowish orange")
elseif plr:GetRankInGroup(4558154) == 230 then
plr.TeamColor = BrickColor.new("Br. yellowish orange")
elseif plr:GetRankInGroup(4558154) == 231 then
plr.TeamColor = BrickColor.new("Br. yellowish orange")
elseif plr:GetRankInGroup(4558154) == 233 then
plr.TeamColor = BrickColor.new("Dark stone grey")
elseif plr:GetRankInGroup(4558154) == 237 then
plr.TeamColor = BrickColor.new("Dark stone grey")
elseif plr:GetRankInGroup(4558154) == 241 then
plr.TeamColor = BrickColor.new("Dark stone grey")
elseif plr:GetRankInGroup(4558154) == 242 then
plr.TeamColor = BrickColor.new("Dark stone grey")
elseif plr:GetRankInGroup(4558154) == 244 then
plr.TeamColor = BrickColor.new("Really red")
elseif plr:GetRankInGroup(4558154) == 245 then
plr.TeamColor = BrickColor.new("Really red")
elseif plr:GetRankInGroup(4558154) == 249 then
plr.TeamColor = BrickColor.new("Really red")
elseif plr:GetRankInGroup(4558154) >= 250 then
plr.TeamColor = BrickColor.new("Really red")
end
end)
-- Made by Deadwoodx