I have a Shop GUI, and a "Diamonds" tab. Straight forward. You click on the purchase button, you get the proper Dev Product ID, buy it, and get the diamonds. I made this script, but It doesn't work. I checked output, and it says nothing. Can anyone help with me?
local plr = script.Parent.Parent.Parent.Parent.Parent local link = game:GetService("MarketplaceService") debounce = false devproductid = 84484960 script.Parent.MouseButton1Click:connect(function() local marketId = devproductid link:PromptProductPurchase(plr,marketId) link.ProcessReceipt = function(receiptInfo) if Enum.ProductPurchaseDecision.PurchaseGranted and receiptInfo.PlayerId == plr.userId then if debounce == false then debounce = true plr.leaderstats.Diamonds.Value = plr.leaderstats.Diamonds.Value + 200 wait(1) debounce = false end end end end)