local function playerOwnsGamePass(player)
local success, hasGamePass = pcall(function()
return player:HasGamePassAsync(gamePassID)
end)
if not success then
return false
end
return hasGamePass
end
Rainbow.MouseButton1Click:Connect(function()
local player = Players.LocalPlayer
if playerOwnsGamePass(player) then
startRainbowEffect()
else
MarketplaceService:PromptGamePassPurchase(player, gamePassID)
end
end)
this checks to see if they own a gamepass. if they do, it does NOT prompt to buy the gamepass. If they DON’T own the gamepass, it prompts them to buy it. How is the prompt that says I already own the gamepass happening when it’s not even supposed to prompt me?