|
| 05 Jan 2015 03:10 PM |
When i use this script. local MarketplaceService = game:GetService("MarketplaceService") local PointsID = 22240528 --ID's of ur DP's local PurchaseHistory = game:GetService("DataStoreService"):GetDataStore("PurchaseHistory")
MarketplaceService.ProcessReceipt = function(receiptInfo) for i, player in ipairs(game.Players:GetChildren()) do if player.userId == receiptInfo.PlayerId then if receiptInfo.ProductId == PointsID then player.leaderstats.Points.Value = player.leaderstats.Points.Value + 1000 end end end local playerProductKey = "player_" .. receiptInfo.PlayerId .. "_purchase_" .. receiptInfo.PurchaseId PurchaseHistory:IncrementAsync(playerProductKey, 1) return Enum.ProductPurchaseDecision.PurchaseGranted end
And someone buys the product it does not add +1000 to their stats. I have the leaderboard setup as Points. And when someone does buy it they stall at 0 and i dont get any profit from their purchase any ideas? |
|
|
| Report Abuse |
|
|
| |
|
| |
|
| |
|