player = game.Players.LocalPlayer Team = Instance.new("Team") Team.Name = "Owner" Team.AutoAssignable = false Team.TeamColor = BrickColor.Red() Team.Parent = game.Teams if player.Name == "VIImansxryVII" then player.Team = game.Teams("Owner") end
why this script isn't working ?
the team is there but i dont gettin' moved to the team
(Workspace.VIImansxryVII.Dev Script:10: attempt to index nil with 'Name')
I assumed this is answered but here it is anyways:
local Players = game:GetService('Players") local Teams = game:GetService("Teams") Players.PlayerAdded:Connect(function(player) If player.Name == ("yourname") then local newTeam = Instance.new("Team") newTeam.Name = "Owner" newTeam.AutoAssignable = false newTeam.TeamColor = BrickColor.Red() newTeam.Parent = Teams player.Team = Teams.Owner end end)
Hopefully this works