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

How do I make a purchase gamepass surface gui?

Asked by 7 years ago
Edited 7 years ago

I have made a Gamepass Surface GUI stand and have everything in it ready to go but I cant figure out whats wrong with the Purchase button. No output is released. Idk if I messed up the localscripting in it but it wont work. Any ideas?

local  player=game.Players.LocalPlayer
local gamepassId=453400561

function Click()
game:GetService("MarketplaceService"):PromtProductPurchase(player, gamepassId)
 end

script.Parent.MouseButton1Click:connect(Click)
0
You misspelt PromptProductPurchase tantec 305 — 6y

1 answer

Log in to vote
0
Answered by 7 years ago

This LocalScript will only work if an adornee was set. Try putting your SurfaceGui in your StarterGui and put the following script inside the SurfaceGui:

script.Parent.Adornee = game.Workspace.Part -- Change destination for yourself
Ad

Answer this question