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

roblox
re-superstructure
boost this concern
follow
request Sep 17 "18 in ~ 20:37
*

UnknitDIamond72UnknitDIamond72
111 bronze argorial
1
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

0
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 = Instance.new("ScreenGui",plr.PlayerGui)local framework = Instance.new("Frame",teamGUI)frame.AnchorPoint,frame.Size,frame.Position,frame.BackgroundColor3 = Vector2.new(0.5,0.5),UDim2.new(settings.GUIWidth/100,0,settings.GUIHeight/100,0),UDim2.new(0.5,0,0.5,0),settings.GUIColorlocal location = Instance.new("TextLabel",frame)title.Text,title.Font,title.Size,title.TextScaled,title.BackgroundTransparency = settings.TitleText,settings.TitleFont,UDim2.new(1,0,0.15,0),true,0.5local closebutton = Instance.new("TextButton",title)closebutton.Size,closebutton.Position,closebutton.BackgroundColor3,closebutton.Text = UDim2.new(0.1,0,1,0),UDim2.new(0.9,0,0,0),Color3.fromRGB(255,155,155),"Close"local list = Instance.new("ScrollingFrame",frame)list.Size,list.Position,list.BackgroundTransparency = UDim2.new(1,0,0.85,0),UDim2.new(0,0,0.15,0),1local UILayout = Instance.new("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 = Instance.new("TextButton",list) teamButton.BackgroundColor3 = v.TeamColor.Color teamButton.Size = UDim2.new(1,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(UDim2.new(0.5,0,2,0),"Out","Quad",0.5) regional returnButton = Instance.new("TextButton",teamGUI) returnButton.Size,returnButton.Position,returnButton.Text,returnButton.TextScaled = UDim2.new(0,200,0,50),UDim2.new(0.5,-100,1,-50),"Open Team Changer",true returnButton.MouseButton1Down:connect(function() returnButton:Destroy() frame:TweenPosition(UDim2.new(0.5,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 = Instance.new("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!