In 2018 Roblox switched coding platforms i believe, most scripts have survived, but I have actually failed to find a working team changer because that myself this year that changes your team once clicked escape if you space in certian groups or not. Mine scripter claims that it functions in studio, but an error pops up in video game that states "TeamColor is not a valid member the PlayerGuiStack BeginScript "Players.Benyal.PlayerGui.Starter GUI.TeamGui.Frame.Research and also Development.LocalScript", line 8 ridge End"My scipter tried plenty of different ways but it just wont work! any seggustions?

You are watching: How to make teams on roblox studio 2018

boost this concern
request Sep 17 "18 in ~ 20:37

111 bronze argorial
add a comment |

1 answer 1

active earliest Votes

See more: Can I Take Delsym And Sudafed Pe Children'S, Can You Take Sudafed With Delsym

This solution provides two script (one LocalScript and also one Script), monitor the steps listed below to do a team an altering GUI!

local teams = game:GetService("Teams")local settings = <"GUIHeight"> = 30, --put in a number end 20, or 100 if you desire it to to fill the display <"GUIWidth"> = 40, --put in a number over 20, or 100 if you desire it to to fill the display <"GUIColor"> = Color3.fromRGB(240,240,240), --color of the team changer gui <"TitleText"> = "Team Changer", --title text in the gui <"TitleFont"> = "ArialBold", --font of titlerepeat wait() until game.Players.LocalPlayer and also game.Players.LocalPlayer.PlayerGuilocal plr = game.Players.LocalPlayerlocal teamGUI ="ScreenGui",plr.PlayerGui)local framework ="Frame",teamGUI)frame.AnchorPoint,frame.Size,frame.Position,frame.BackgroundColor3 =,0.5),,0,settings.GUIHeight/100,0),,0,0.5,0),settings.GUIColorlocal location ="TextLabel",frame)title.Text,title.Font,title.Size,title.TextScaled,title.BackgroundTransparency = settings.TitleText,settings.TitleFont,,0,0.15,0),true,0.5local closebutton ="TextButton",title)closebutton.Size,closebutton.Position,closebutton.BackgroundColor3,closebutton.Text =,0,1,0),,0,0,0),Color3.fromRGB(255,155,155),"Close"local list ="ScrollingFrame",frame)list.Size,list.Position,list.BackgroundTransparency =,0,0.85,0),,0,0.15,0),1local UILayout ="UIListLayout",list)local serverTeamHandler = game.ReplicatedStorage:WaitForChild("teamChanger")local getTeams = teams:GetChildren() --this part checks if you have teams in your game (you require to have actually put the groups in your video game already)for i,v in pairs(getTeams) carry out print(": " .. V:GetFullName()) neighborhood teamButton ="TextButton",list) teamButton.BackgroundColor3 = v.TeamColor.Color teamButton.Size =,0,0,40) teamButton.Text,teamButton.TextColor3,teamButton.TextStrokeTransparency,teamButton.TextScaled = v.Name,Color3.fromRGB(255,255,255),0.7,true teamButton.MouseButton1Down:connect(function() print("You readjusted teams. Friend are currently in: " .. V.Name) serverTeamHandler:InvokeServer(v) end)endclosebutton.MouseButton1Click:connect(function() frame:TweenPosition(,0,2,0),"Out","Quad",0.5) regional returnButton ="TextButton",teamGUI) returnButton.Size,returnButton.Position,returnButton.Text,returnButton.TextScaled =,200,0,50),,-100,1,-50),"Open Team Changer",true returnButton.MouseButton1Down:connect(function() returnButton:Destroy() frame:TweenPosition(,0,0.5,0),"Out","Elastic",1,true) end)end)Step 1 Insert a LocalScript into StarterGui

Step 2 Copy the stuff over and paste it right into this LocalScript

Step 3 Insert a Script into either Workspace or ServerScriptService (your choice)

Step 4 Copy the stuff below and also paste it right into the Script

local teamChanger ="RemoteFunction",game.ReplicatedStorage)teamChanger.Name = "teamChanger"local duty changeTeam(client,team) print(client.Name .. "changed teams: now in" .. Team.Name) client.Team = teamendteamChanger.OnServerInvoke = changeTeamIf you complied with these actions correctly, you must now have a working team transforming GUI in your game! It works as lengthy as girlfriend have currently inserted groups in her game. The first couple of lines in the LocalScript can also be customized together well!