The dev product shows up when I click the TextButton but when I buy it I dont get the item. I have a script in ServerScriptService here it is.
local marketplaceService = game:GetService("MarketplaceService")
local players = game:GetService("Players")
local productId = 1338743761
local Tool = game.ReplicatedStorage.CuddlyCat
local Players = game:GetService("Players")
marketplaceService.ProcessReceipt = function(receipt)
local player = players:GetPlayerByUserId(receipt.PlayerId)
if not player then
return Enum.ProductPurchaseDecision.NotProcessedYet
end
if receipt.ProductId == productId then
Tool:Clone().Parent = Players.LocalPlayer.Backpack
end
return Enum.ProductPurchaseDecision.PurchaseGranted
end
and the localscript in the text button. Here it is.
local marketplaceService = game:GetService("MarketplaceService")
local productId = 1338743761
script.Parent.MouseButton1Click:Connect(function()
marketplaceService:PromptProductPurchase(game.Players.LocalPlayer, productId)
end)

2 comments
In the first script, change line 13 to
Tool:Clone().Parent = player.BackpackbecausePlayers.LocalPlayerdoesn't work on normal scripts.Thank you! :D