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

Item is not currently for sale?

Asked by 2 years ago

I am making developer products for my game but the prompt keeps saying "Item is not currently for sale." I may be missing something obvious or maybe I typed something wrong? Do I need to add the item to the store in roblox as well? I'm new to dev products, any help is appreciated!

local MarketplaceService = game:GetService("MarketplaceService")
local Button = script.Parent
local Players = game:GetService("Players")
local id = XXXXX

Button.MouseButton1Click:Connect(function()
    local player = Players.LocalPlayer
    MarketplaceService:PromptPurchase(player, id)
    end)

This gets the prompt to pop up, but again, the prompt just says the item isn't currently for sale.

1
Try using PromptGamePassPurchase instead of using PromptPurchase: I think the reason it didn't work is because it is because promptpurchase is just used to prompt the purchase not the actual gamepass itself JesseSong 3916 — 2y
0
also change the id to your gamepass id. lmk if it works JesseSong 3916 — 2y

1 answer

Log in to vote
0
Answered by
JesseSong 3916 Moderation Voter Community Moderator
2 years ago

Like I said in the comment use PromptGamePassPurchase. Read more about it here:

MarketplaceService:PromptGamePassPurchase

0
I found what the issue was, you had the right idea. I just had to change PromptPurchase to PromptProductPurchase. Thanks! DaGlizzzzzzyyyy 34 — 2y
0
Please accept the answer if it helped you! JesseSong 3916 — 2y
Ad

Answer this question