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

when i buy a dev product i made for my game in studio. i dont get the coins?!

Asked by 3 years ago
Edited 3 years ago

so basically when i bought the dev product i should have gotten the coins. but. i didn't. and i got a message in the output saying data store request.. i tried multiple different scripts... and its the exact same.. if you know how to fix this.. PLEASE tell me! (:

button GUI script:



local id = 1157603502 local mps = game:GetService("MarketplaceService") local plr = game.Players.LocalPlayer script.Parent.MouseButton1Click:Connect(function() mps:PromptProductPurchase(plr, id) end)

Dev Product Handler Script:




local MarketPlace = game:GetService("MarketplaceService") local id1 = 1157603502 id1Reward = 1000 MarketPlace.ProcessReceipt = function(receiptInfo) if receiptInfo.ProductId == id1 then local plr = game.Players:GetPlayerByUserId(receiptInfo.PlayerId) plr.leaderstats.chords.Value = plr.leaderstats.chords.Value + id1Reward return Enum.ProductPurchaseDecision.PurchaseGranted end end
0
A way you could test if it works or not is make the cost to be free at first and go to an alt account and make the alt buy the product and see if it give the alt the money, if it doesn't then something is wrong in the script but if it works then you can revert the price to be how much you want. KixWater 126 — 3y

1 answer

Log in to vote
0
Answered by
Borrahh 265 Moderation Voter
3 years ago

Hey Mate, I believe that because it's a Test / You are in studio, it's not going to charge you.

Ad

Answer this question