Ad
Still have questions? Join our Discord server and get real time help.
Log in to vote
0

I am putting a robux purchased item in my game but it won't work?

Asked by 13 days ago

The robux purchased item I put into my game when clicked on says, "This is not for sale" How do I fix this. Is it script, or something else. Thank you in Advance.

Anyways, here's the script I put into server script service as "RobuxPurchaseScript"

local mpService = game:GetService("MarketplaceService")
local moneystatus50 = game:FindFirstChild("<|>ObbyBucks")

mpService.ProcessReceipt = function(purchaseInfo)
    local plr = game:GetService("Players"):GetPlayerByUserId(purchaseInfo.PlayerId)
    if purchaseInfo.ProductId == 465793789 then
        if moneystatus50 then
            moneystatus50.Value = moneystatus50.Value + 50
        end
        return Enum.ProductPurchaseDecision.PurchaseGranted
    end
end

Next is the script I put into the button

local button = script.Parent
local mpService = game:getService("MarketplaceService")

button.MouseButton1Click:connect(function()
    mpService:PromptProductPurchase(game.Players.LocalPlayer, 465793789) 
end)
0
Wym robux purchased item? You mean like an item on the roblox catalog or a developer product? TypicallyPacific 31 — 13d
0
yes sheepposu 22 — 13d
0
A developer product. The one here gives money sheepposu 22 — 13d

Answer this question