Okay so team (Bright Red)players attaches its camera to "Campart1"
team (Bright blue)players does not attach to its destination which is "Campart2" it just stays at where the spawn is at.
Help me have (Bright blue) players go to its destination "Campart2"
for i,v in pairs(game.Players:GetChildren())do if v.TeamColor == BrickColor.new("Bright red") then local cam = game.Workspace.CurrentCamera cam.CameraType = Enum.CameraType.Scriptable cam.CameraSubject = game.Workspace:WaitForChild('CamPart1') cam.CFrame = CFrame.new(game.Workspace:WaitForChild('CamPart1').Position + Vector3.new(0,0,0)) elseif i.TeamColor == BrickColor.new("Bright blue") then local cam = game.Workspace.CurrentCamera cam.CameraType = Enum.CameraType.Scriptable cam.CameraSubject = game.Workspace:WaitForChild('CamPart2') cam.CFrame = CFrame.new(game.Workspace:WaitForChild('CamPart2').Position + Vector3.new(0,0,0)) end end
You just used "i" instead of "v" in your elseif
for i,v in pairs(game.Players:GetChildren()) do if v.TeamColor == BrickColor.new("Bright red") then local cam = game.Workspace.CurrentCamera cam.CameraType = Enum.CameraType.Scriptable cam.CameraSubject = game.Workspace:WaitForChild('CamPart1') cam.CFrame = CFrame.new(game.Workspace:WaitForChild('CamPart1').Position + Vector3.new(0,0,0)) elseif v.TeamColor == BrickColor.new("Bright blue") then local cam = game.Workspace.CurrentCamera cam.CameraType = Enum.CameraType.Scriptable cam.CameraSubject = game.Workspace:WaitForChild('CamPart2') cam.CFrame = CFrame.new(game.Workspace:WaitForChild('CamPart2').Position + Vector3.new(0,0,0)) end end