I need some help really bad im trying to give my players who have a gamepass a team but its just not working heres my code if you can help me i have used local script and just script
local mps = game:GetService("MarketplaceService")
local gamepass_id = 9600997
local Teams = game:GetService("Teams")
game.Players.PlayerAdded:Connect(function(player)
if mps:UserOwnsGamePassAsync(player.UserId, gamepass_id) then
player.Team = Teams.GoldCustomer
else
player.Team = Teams.Customer
end
end)

1 comment
try to use this video https://www.youtube.com/watch?v=FE6-4FKvBsA