I've used it before but I forgot how to do it, and I've checked the wiki (http://wiki.roblox.com/index.php?title=API:Class/MarketplaceService) and found nothing that's useful for it, any help appreciated.
✓ ANSWER ACCEPTED
How to check if a player own's a GamePass?
1 answer
✓ Accepted answer
local passId = 0000000 -- change this to your game pass ID.
function isAuthenticated(player) -- checks to see if the player owns your pass
return game:GetService("MarketplaceService"):PlayerOwnsAsset(player, passId)
end
game.Players.PlayerAdded:connect(function(plr)
if isAuthenticated(plr) then
print(plr.Name .. " has bought the game pass with id " .. passId)
end
end)
This discussion is preserved as it was. New answers, comments, and votes are closed.
