|
| 09 Nov 2017 06:03 PM |
It works, if I buy 100 coins, it gives 100 coins, if I buy it again, it adds another 100 and goes up to 200.
But if I buy 100 coins, and then 1000 coins, it gives 100, but doesnt add the 1000.
How do I fix this?
I couldn't give script because it's tagged. RIP |
|
|
| Report Abuse |
|
|
|
| 09 Nov 2017 06:05 PM |
| Does it give you an error? |
|
|
| Report Abuse |
|
|
|
| 09 Nov 2017 06:07 PM |
No, it's not really an error though.
It doesn't want to add 1000 coins after adding 100 coins
The 100 coins and 1000 coins are different dev products btw |
|
|
| Report Abuse |
|
|
|
| 09 Nov 2017 06:12 PM |
Does it work if you do 1000 and then 1000 again?
Does it work if you do 1000 and then 100, instead of the other way around? |
|
|
| Report Abuse |
|
|
|
| 09 Nov 2017 06:14 PM |
1000, and then 1000 works
1000 and then 100 doesn't work
I'm sure it has something to do with them being different dev products. |
|
|
| Report Abuse |
|
|
|
| 09 Nov 2017 06:15 PM |
| I also just noticed, testing it again, it's not even working now, it works sometimes and doesn't work other times. |
|
|
| Report Abuse |
|
|
|
| 09 Nov 2017 06:17 PM |
If they both work individually there's probably something in your code unintentionally preventing you from using a different DevProduct after getting a certain one already. This could be an if statement or some other thing. We can only speculate since we can't see your code Can you upload your script somewhere else that we can read it and then link it to us, since it will be censored here? |
|
|
| Report Abuse |
|
|
|
| 09 Nov 2017 06:20 PM |
There are different scripts in ServerScriptService, one for 1000, one for 100.
And then there are different textbuttons with localscripts in them, one for 1000, one for 100.
I was told that they need to be in seperate scripts though. |
|
|
| Report Abuse |
|
|
|
| 09 Nov 2017 06:22 PM |
local MarketplaceService = game:GetService("MarketplaceService") local devproductid = 113778864
|
|
|
| Report Abuse |
|
|
|
| 09 Nov 2017 06:23 PM |
MarketplaceService.ProcessReceipt = function(receiptInfo) for i, player in ipairs(game.Players:GetChildren()) do if player.userId == receiptInfo.PlayerId then if receiptInfo.ProductId == devproductid then |
|
|
| Report Abuse |
|
|
|
| 09 Nov 2017 06:27 PM |
player dot leaderstats dot Coins dot Value = player dot leaderstats dot Coins dot Value + 1000
dot = .
|
|
|
| Report Abuse |
|
|
|
| 09 Nov 2017 06:28 PM |
end end end return Enum.ProductPurchaseDecision.PurchaseGranted end |
|
|
| Report Abuse |
|
|
|
| 09 Nov 2017 06:32 PM |
| Thats the script in ServerScriptService. ^^^^^^^ |
|
|
| Report Abuse |
|
|