Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Prompt purchase on part click not working?

Asked by 4 years ago
local id = 13073982
local clickDetector = script.Parent.ClickDetector

clickDetector.MouseClick:Connect(function(Player)
    game:GetService("MarketplaceService"):PromptGamePassPurchase(Player, id)
end)
0
It should be :PromptPurchase() that what i use at least kepiblop 124 — 4y

1 answer

Log in to vote
0
Answered by 4 years ago

When you are putting the script in, make sure that it's located inside of the click part alongside the click detector like this having the click detector and Script inside of the ClickPart. I tested the script on mine and it works fine.

ClickPart -- located as script.Parent in the script

Clickdetector

Script

0
It already is maddiesswrld 30 — 4y
0
Try publishing the game or a test game with the same script and objects and trying to see if the purchase prompt pops up in game instead of studio. Tyserkhan004V2 0 — 4y
Ad

Answer this question