Should this work. If you have the game pass then this should work. THis script is inserted in a TextButton.
local passId = 182358984
function isAuthenticated(player)
return game:GetService("GamePassService"):PlayerHasPass(player, passId)
end
game.Players.PlayerAdded:connect(function(plr)
if isAuthenticated(plr) then
print("Loaded gamePass for a Player")
script.Parent.MouseButton1Click:connect(function()
number = 0
number = number + 3
script.Parent.Parent.TextBox.Text = number
else
number = 0
number = number + 1
script.Parent.Parent.TextBox.Text = number
end)
end
end)

3 comments
I got most of this from the ROBLOX wiki.
Um... in Studio there is an error on line #14.
I think that since "else" is in a function it does not work but I don't know any onther way to do this...