Ive Tried To make This Work But Im Unsure Whats Wrong.
Script for serverscriptservice
local MPS = game:GetService("MarketplaceService")
MPS.ProcessReceipt = function(receiptInfo)
if receiptInfo.ProductId == 985697300 then
local player = game.Players:GetPlayerByUserId(receiptInfo.Playerid)
player.leaderstats.Life.Value = player.leaderstats.Life.Value * 2
return Enum.ProductPurchaseDecision.PurchaseGranted
end
end
Script For StarterGUI
MPS = game:GetService("MarketplaceService")
id = 985697300
local player = game.Players.LocalPlayer
script.Parent.MouseButton1Click:connect(function()
MPS:PromptProductPurchase(player, id)
end)
Thanks For Your Help Whoever Answers me!

2 comments
Im Trying To Make it multiply the users current stats (if he has 20 it should make it 40)
Check this https://developer.roblox.com/en-us/articles/Developer-Products-In-Game-Purchases