Hey, trying to make a dev product for my game but it just doesn't work. No errors, no prints, nothing.
Here's the code -
ShekelsGiven = script.Parent.AmountGiven
ProductID = 31831485
game:GetService("MarketplaceService").ProcessReceipt = function(receiptInfo)
for i, player in ipairs(game.Players:GetChildren()) do
print'1'
if player.userId == receiptInfo.PlayerId then
print'2'
if receiptInfo.ProductId == ProductID then
print'3'
if receiptInfo.CurrencyType == Enum.CurrencyType.Robux then
print'4'
player.ShopValues.Shekels.Value = player.ShopValues.Shekels.Value + ShekelsGiven.Value
print'5'
end
end
end
end
print'6'
return Enum.ProductPurchaseDecision.PurchaseGranted
end
Thanks for reading

2 comments
Are you prompting a purchase?
I don't know much on this topic. Can you elaborate?